Forum

Removing strafe jumping and bunny hopping

Discuss programming in the QuakeC language.

Moderator: InsideQC Admins

Removing strafe jumping and bunny hopping

Postby Nahuel » Sun Apr 02, 2017 5:38 am

hello forum, i did search about the title above in the forum, but i just find unuseful stuff like "I LOVE STRAFE JUMPING! DO NOT REMOVE IT", or strange suggestions :P
My goal is to get a player movement similar to duke 3d, or any old school movement done in build engine.
My question is simple, i wanna a movement like quake but without strafe jumping and bunny hopping, i am using darkplaces engine.

what is the way to do this??

Any help is apreciated!!

Thanks in advance!!
hi, I am nahuel, I love quake and qc.
User avatar
Nahuel
 
Posts: 483
Joined: Wed Jan 12, 2011 8:42 pm
Location: mar del plata

Re: Removing strafe jumping and bunny hopping

Postby Dr. Shadowborg » Mon Apr 03, 2017 2:51 am

*Sees Bunnyhopping and Strafe Jumping mentioned and curls into a ball while swearing about Painkiller's snowy bridge and sobbing about how "people can't fly" and also that hell is constantly reloading savegames after falling to his doom* :shock:

Jokes about personal trauma aside, maybe check for (self.flags & FL_ONGROUND) with vlen(self.velocity) > (whatever max player speed you want) and if so, cap it to max player speed in PlayerPostThink? You might have to add some flag code in your damage functions too.
User avatar
Dr. Shadowborg
InsideQC Staff
 
Posts: 1080
Joined: Sat Oct 16, 2004 3:34 pm

Re: Removing strafe jumping and bunny hopping

Postby Spike » Mon Apr 03, 2017 6:27 am

there's some 'sv_user.qc' file which lh ripped from the engine's code that you can throw into your mod to override how certain parts of movetype_walk work.
doing so will of course fuck over player prediction, so don't expect it to be favoured in multiplayer. DP does not provide an easy way to fix this that I'm aware of, lasy I checked even xonotic was still depending on the client's prediction logic matching whatever was going on serverside.

ultimately, the only way to actually kill bunnyhopping, is to start a timer once you land and not allow jumping until after that timer has expired. This can be predicted properly, but does require quite precise timing in order to do so. That said, arbitrary cooldowns suck.
strafe jumping can most easily be killed by removing air control. sv_aircontrol 0.
stopping ramp jumping requires you to clamp velocities just after jumping, there's no real way around that.
don't forget NQ's wall-running bug either.
Spike
 
Posts: 2874
Joined: Fri Nov 05, 2004 3:12 am
Location: UK


Return to QuakeC Programming

Who is online

Users browsing this forum: No registered users and 1 guest