Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

why did bunny hopping exist?

as far as I remember, it was to do with jumping sideways being a lot faster than other movement, but I can't imagine why you'd program that in?



The player can jump both forward and sideways with a maximum speed. If you do that both at once the end result is you exceed to maximum speed diagonally. Now if the player is on the ground he brakes to the maximum speed. So by keeping contact with the ground as brief as possible you maintain more speed.


The classic way to get this accidentally:

- if "forward" key held down, add unit motion vector to position

- if "left" key held down, rotate motion vector to left and add it to the position

In that case, you've added two copies of the vector at 90 degrees to each other, and the player moves by sqrt(2) times the normal speed.


I think it was more about making it difficult to be hit. Both because of the irregular movement, but also because rockets exploding on the ground causes damage, and being off the ground saves you (hence good players always aiming the RPG at the ground under the opponent).




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: