Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Strange gravity physics after climbing out of fluids #92

Open
HangTimeQW opened this issue Mar 13, 2022 · 2 comments
Open

Strange gravity physics after climbing out of fluids #92

HangTimeQW opened this issue Mar 13, 2022 · 2 comments

Comments

@HangTimeQW
Copy link

If you are hit by a rocket explosion when climbing out of fluids, the knockback behaves strangely. Your vertical velocity does not get halted by a ceiling so you can 'levitate' against a ceiling rather than falling to the ground.

To reproduce, do a quad rocketjump when climbing out of lava onto a ledge on dm2. Compare with a quad rocketjump from lava when NOT climbing out onto a ledge (this behaves normally).

Demo example attached (first quad rj is 'normal', subsequent quad rjs have the bug):
gravbug.zip

@tcsabina
Copy link
Collaborator

Hi HT!

I saw the discussion on this on Discord...
So the current idea about the bug is this: the server gives the extra damage (which gives an X amount of seconds in the air) to the player, but because the player cannot be pushed up in the air due to the obstacle, the player just 'levitates' till that X amount of seconds the server calculated, expire?
Is this something like this?

Toma

@HangTimeQW
Copy link
Author

My hypothesis is that the 'climbing out of fluid' code does something strange whereby it prevents vertical (possibly other axes too) velocity from being set to zero when you hit an obstacle. So say you hit the ceiling with a vertical speed of 1000u/sec. Instead of being set to zero, and then going negative due to gravity, I suspect it is just decaying from 1000 based on the gravity acceleration. So it takes some time for it to drop below zero and hence you stay glued to the ceiling.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants