Pivity

Get rotation speed

Last read Never
#1

I'm a newbie to scripting in gmod, and wanted to make an addon that prevents the player from turning too fast.

The idea is to have a "balance meter" that depletes slowly, and rises more the faster you turn. If you feel your balance meter, you ragdoll. This is not meant to be realistic or anything, its just a wacky test to make controls annoying.

I was looking through the documentation, and the GM:PlayerTick looked like a good place to start. The thing is that the GetOldAngles function from CMoveData is only available in the client, and not in the server. I could use this client side, but the GM:PlayerTick function says the following:

This hook is predicted. This means that in singleplayer, it will not be called in the Client realm.

This means that my addon wouldn't work in single player, so I must use the server side anyway, which doesn't have the old angles info.

Do you guys have any suggestion about how to handle this?

Users viewing this thread
Nobody