Page 1 of 1

Breaking the speed limit

PostPosted: Sat Dec 14, 2013 8:20 pm
by TechieUK
My friend is working with an SDK Template mod, and we have a very fast team.
This is the code in the class script:
Code: Select all
   // Movement
   "RunSpeed"      "400"
   "SprintSpeed"      "400"
   "ProneSpeed"      "350"

Any RunSpeed faster than 400 will be clipped to 400 automatically. How do I remove this limit?
Can someone tell me where the code is located so I can fiddle with it?

Re: Breaking the speed limit

PostPosted: Sat Dec 14, 2013 9:13 pm
by Mehis
cl_forwardspeed
cl_sidespeed
cl_backspeed

Re: Breaking the speed limit

PostPosted: Sat Dec 14, 2013 9:15 pm
by TechieUK
Is that the limit for speed, or does it change your speed to that?

Re: Breaking the speed limit

PostPosted: Sun Dec 15, 2013 11:41 am
by Sandern
TechieUK wrote:Is that the limit for speed, or does it change your speed to that?

There's a number of places where the speed might be limited/clamped. You kind of need to check CGameMovement::ProcessMovement and search on maxspeed.

cl_forwardspeed, cl_sidespeed and cl_backspeed control the max wish speed send by the client. On the server it is clamped to CBasePlayer::MaxSpeed (per player max speed) and sv_maxspeed (global max speed).

Re: Breaking the speed limit

PostPosted: Sun Dec 15, 2013 12:14 pm
by TechieUK
Thank you very much for the information!
I'll take a look around where you said, and if nothing happens I'm just going to keep digging until I find something that works I guess. I did set cl_forward/side/backspeed to 1000 in the code to see what happens and it does clip to 400 still.

Re: Breaking the speed limit

PostPosted: Thu Dec 19, 2013 12:54 pm
by SM Sith Lord
I'm sure you've already considered this, but moving that fast will be hell on the net code.