Forums

Pages: [1] 2 3 4
Author Topic: The Science of Jump  (Read 7243 times)
Maggot
*

Posts: 34
I got bored so here's a bunch of information about how certain jump tricks work. It's possible there may be giant stupid mistakes...I'm tired....

First off is the ctap. The way a ctap works is when you crouch your collision box is made shorter and when you jump at the exact same moment when it changes it pushes your jump down closer to the ground than just normally pressing space. specifically it makes you jump 11 units shorter than a normal jump (without any rockets). As your rocket hits the ground you are closer to the explosion but still have the upward speed of a jump and the collision box of crouching. The reason crouching is important is because the collision box is smaller and therefore the explosion penetrates closer to the center of the player giving more thrust.

Here is a table of data showing a perfect ctap which achieves a height of 691 units(really really really hard for a human to pull off)

Code: [Select]
Tick  ducking   ducked      jumping    vertvel    fallvel        height      viewoffset
83    false        false         false         0             0               64            68
84    true         false         false         0             0               64            68
85    true         false         false         0             0               64            67.6
90    true         false         false         0             0               64            58.2   Rocket Fired
92    true         false         true          277         0               68.27       58.2
93    false        true          true          1045.25  -276.97     72.34       45      Rocket Explodes (Health 200->148)
94    false        true          true          1033.25  -1045.2     87.93       45
95    false        false         true          1021.25  -1033.2     83.33       68
96    false        false         true          1009.25  -1021.2     98.56       68
97    false        false         true          997.25    -1009.2     113.6       68



Another trick I looked at was the bounce. A bounce simply abuses the differences that can arise between client calculations and server calculations. The server calculates your movement at a certain rate and the client calculates the movement as well so that the movement on your screen is smooth and not jerking with every server info update sent to you. The idea is similar to lag abuse but the "lag" happens in the span of 1 tick(strange server rates may affect it) so it can be done no matter what your ping or fps is. To achieve this difference in velocity calculations it requires you to be falling fairly fast but the difficulty comes in getting your rocket to hit the ground at the exact same time as you. So if you fall too short you'll be going too slow to perform the glitch and if you fall from very high it makes the timing for firing your rocket very hard to predict.

Here is a table of data showing the bonus #1 bounce on jump_soar_a4 (I start off by jumping off the platform in case that part looks confusing)
AbsZ=     The height of my feet
FallVel=   Client side velocity calculations
AbsVelZ= Server side velocity calculations

Code: [Select]
Tick       AbsZ        FallVel      AbsVelZ
304       6880       0              0                 Standing before jump
308       6884       0              0                 Press jump
309       6888       -270.97    271             Jump starts
310       6911       -258.97    247
331       6950       -6             -5                Peak of jump
359       6877       328.97     -328.99       Jump drops below starting platform
369       6817       448.97     -448.99
389       6642       668.97     -688.99
399       6528       808.97     -808.99       Rocket fired
409       6396       928.97     -928.99
410       6382       940.97     -940.99
411       6368       952.97     -952.99
412       6353       0              -964.99       Hit ground and rocket (Health 200->83)
413       6362       -614         614
414       6371       -602         602

starting platform:            6880
max height from jump:    6950
teleport ground height:   6352
drop distance:                 598

Also these are the prediction errors that happen at tick 412(where the bounce happens)

001 CPlayerLocalData::m_vecPunchAngle - vec[] differs (1st diff) (net -2.000000 0.000000 12.531250 - pred 0.000000 0.000000 12.544999) delta(2.000000 0.000000 0.013749)
002 C_BasePlayer::m_iHealth - int differs (net 83 pred 200) diff(117)
004 C_BaseEntity::m_vecVelocity - vec[] differs (1st diff) (net 414.817719 -125.080040 614.008118 - pred 267.526886 -31.989576 0.000000) delta(-147.290833 93.090464 -614.008118)


It's all a bit complicated but hopefully you will be able to understand some of it.
« Last Edit: December 09, 2012, 08:07:14 PM by Jamien The Choco »
   
Offline  Hadokk
Rocketeer
****

Bball Server Filler Upper
Posts: 313
Okay
Cool and nerdy.
   
Offline  Klanana
Rocketman
*

iT! Servers Owner
Posts: 671
Team Spec Extraordinaire
This is awesome but i just cant even

Stop making me feel dumb


---------------------------

Jump iT - 64.74.97.15:27015 | JuJump iT - 74.91.113.66:27015 | Surf iT - 216.52.143.76:27015
Bball iT - 74.91.113.9:27015 | MGE iT - 74.91.122.39:27015
   
Soldier
***

Posts: 108
Good read, i always felt bounces were very timing based.

   
Rocketman
*****

Posts: 518
No tears now; only dreams
Good read, i always felt bounces were very timing based.

As opposed to not being timing based? Also, some bounces are easier standing up rather than crouched. It seems that the smaller the falling height, the more suitable it is for a standing up bounce. A great example is that down pogo level on jump_mouser. That level can be consistently done with a standing up bounce.

And if you get really lucky you can pull off some crazy bounces like this:
sync-bounce-ish?


btw Jamien I'm sure you can achieve a ctap higher than 691... Have you tried using the original? You ctap higher with it when aiming straight down. Or walking to the right with the normal rocket launcher. People are able to do that 685 ctap on squared with this technique fairly consistently.

Also, shouldn't fallvel during the ctap just be the opposite of vertvel at every tick?


---------------------------
   
Soldier
***

Posts: 108

As opposed to not being timing based?


People always told me it was based on pure luck.

I always thought it was timing based, especially when my friend barrel showed me you can bounce on a multitude of jumps.
   
Offline  deep
Maggot
*

Posts: 26
Can someone post a quick comparison picture showing exactly how high 691 HU is?
   
Offline  Hadokk
Rocketeer
****

Bball Server Filler Upper
Posts: 313
Okay
http://imgur.com/qoTW6

Should give you some idea how high it is. Player height is 72 units (I think).
   
Rocketman
*****

Posts: 630


This is a 685 unit high wall, so it's even higher than this. 
   
Offline  Diddy
Rocketeer
****

Posts: 297
I would assume speedshots would work in a similar manner to bounces as well?  Don't quote me on that, obviously, but logically it makes sense since the objective for both is to shoot a rocket the moment you hit the ground.


---------------------------
some people just shouldnt be aloud to have internet accesss
   
Maggot
*

Posts: 34
btw Jamien I'm sure you can achieve a ctap higher than 691... Have you tried using the original? You ctap higher with it when aiming straight down. Or walking to the right with the normal rocket launcher. People are able to do that 685 ctap on squared with this technique fairly consistently.

Also, shouldn't fallvel during the ctap just be the opposite of vertvel at every tick?

The 691 is done walking right with normal rocket launcher. 685 is relatively easy but the last few units its possible to gain with a ctap are very hard to squeeze out. A 692 jump should be possible but I haven't tested it enough to confirm. With the ctap glitch you either get it or don't get it so once you pull it off the height you gain from the ctap is all based on the timing of your rocket. The "perfect" ctap is perfect because the rocket hits you on the first tick that the player is in the air and crouching thus having the most upward speed and still being closest to the ground.

the reason the fallvel and vertvel are different is actually the inverse affect of the client/server variable glitch. It doesn't really mean anything in this situation I was just keeping track of all interesting changes.

I would assume speedshots would work in a similar manner to bounces as well?  Don't quote me on that, obviously, but logically it makes sense since the objective for both is to shoot a rocket the moment you hit the ground.
The specifics vary but it would seem a bounce, a speedshot, and the edgebug are all the result of the exact same glitch: resetting client fallvelocity to 0(because fallvelocity only affects vertical speed) but the server velocity variable including horizontal speed maintains all other movement. A speedshot is basically a speedpogo but since you are touching the ground when the rocket explodes it gives you a lot more boost.

I'm not sure why valve made fall velocity its own dedicated variable but theoretically if they removed it and replaced it with a full XYZ velocity variable then speedshots and edgebugs would be broken(because they rely on keeping horizontal speed) but bounces would still work.
« Last Edit: December 09, 2012, 08:05:22 PM by Jamien The Choco »
   
Offline  CrancK
Rocketeer
*

ehh... what?
Posts: 397
dude...
seperate fallspeed and horizontal speed is prolly a leftover from quake, since at least in quake3 in the movement code fallvel also gets split from total vel(or rather horizontal gets split off) (although hl comes from q2, i assume the code is similar)


q3 code:
// project moves down to flat plane
   pml.forward[2] = 0;
   pml.right[2] = 0;
   VectorNormalize (pml.forward);
   VectorNormalize (pml.right);

   for ( i = 0 ; i < 2 ; i++ ) {
      wishvel = pml.forward*fmove + pml.right*smove;
   }
   wishvel[2] = 0;

the reason why.. (i think/assume) is so airstrafing doesnt increase/decrease/affect vertical speed
« Last Edit: December 10, 2012, 02:19:36 AM by CrancK »


---------------------------
   
Fly
**

Posts: 74
seperate fallspeed and horizontal speed is prolly a leftover from quake, since at least in quake3 in the movement code fallvel also gets split from total vel(or rather horizontal gets split off) (although hl comes from q2, i assume the code is similar)


q3 code:
// project moves down to flat plane
   pml.forward[2] = 0;
   pml.right[2] = 0;
   VectorNormalize (pml.forward);
   VectorNormalize (pml.right);

   for ( i = 0 ; i < 2 ; i++ ) {
      wishvel = pml.forward*fmove + pml.right*smove;
   }
   wishvel[2] = 0;

the reason why.. (i think/assume) is so airstrafing doesnt increase/decrease/affect vertical speed

Is fmove and smove the variable that is tracking current player movement?
   
Offline  CrancK
Rocketeer
*

ehh... what?
Posts: 397
dude...
(just woke up, so any mistakes i make/say... meh)

ehm, yes and no, q3 has some redundancy built in, yes they track the player movement as seen by the code before the little bit i pasted, which is:

Code: [Select]
fmove = pm->cmd.forwardmove;
smove = pm->cmd.rightmove;

cmd = pm->cmd;
scale = PM_CmdScale( &cmd );

// set the movementDir so clients can rotate the legs for strafing
PM_SetMovementDir();

// project moves down to flat plane
pml.forward[2] = 0;
pml.right[2] = 0;
VectorNormalize (pml.forward);
VectorNormalize (pml.right);

for ( i = 0 ; i < 2 ; i++ ) {
wishvel[i] = pml.forward[i]*fmove + pml.right[i]*smove;
}
wishvel[2] = 0;


so, basically they are temporary copies of the vectors which track it, then the code nullifies the up/down movement of the original tracking variables and then does some other stuff with all these.

(also damn, uploads not working, wanted to add the file from q3, but meh i guess, if anyone really wants it they can download q3 source anyway, or the q2 source, or the q1 source ^^)


---------------------------
   
Fly
**

Posts: 74
How does the water jump work??  I've always wondered why you get extra boost out of water.
   
0 Members and 1 Guest are viewing this topic.
Pages: [1] 2 3 4
« previous next »


spirit Powered by SMF 2.0 RC5 | SMF © 2006–2011, Simple Machines LLC