(12-23-2015, 02:20 PM)Wili Wrote: I tried SetPlayerMoveSpeedMul(0.0); and SetPlayerRunSpeedMul(0); for disabling player controls but if the player keeps pressing Left Shift "SetPlayerCrouching(true);" won't work and the player will clip anyway.
Right because your just changing the speed of sprinting, your not stopping the player from sprinting.
There is any other way for disabling player controls?
SetPlayerActive(false); seems to work, it feels a bit odd because the player stops responding and the player can't look around anymore, but if there is no other way I could make it using that command.
Thanks a lot for the help Neelke!!!
Only a way to completely
take away control,
void SetPlayerActive(bool abActive);
Looking through the code there sin't a way to straight up stop the player from sprinting, minus possibly taking away all control, then forcing them into a crouch, but my assumption is that that wouldn't stop them from being able to uncrouch. Maybe putting the crouch inside a looping timer that constantly forces them down into crouching? hmmm... I'd have to test it all on my end before knowing if that would 100% work, and you'd have to make sure to end that loop after they exited that area (or died) but thats a possibility.
I can't test it on my end but you could give that a go.