Skip to content

fix: Gonome should use ApplyImpuseVelocity to apply force to hit targets - #376

Merged
1upD merged 3 commits into
entropy-zero:ez2/mapbasefrom
1upD:ez2/feature/fix-gonome-velocity
Nov 9, 2026
Merged

1upD merged 3 commits into
entropy-zero:ez2/mapbasefrom
1upD:ez2/feature/fix-gonome-velocity

Conversation

@1upD

@1upD 1upD commented Oct 20, 2026

Copy link
Copy Markdown

One of the most persistent and frustrating bugs we have observed in EZ2 is that sometimes Wilson will fling the player upon contact.

After some testing on Sunday, Blixibon was able to demonstrate that this condition happens when gonomes hit Wilson. This happens because they apply velocity to their target using oldschool physics. I believe that calling ApplyImpulseVelocity instead of SetAbsVelocity will correctly apply physics without breaking the physics system.

I cannot guarantee this is the only case that caused Wilson to become energized. This needs further testing.


Does this PR close any issues?

  • Surprisingly, there is no open GitHub issue to track this problem.

PR Checklist

  • My PR follows all guidelines in the CONTRIBUTING.md file
  • My PR targets a develop branch OR targets another branch with a specific goal in mind

@1upD
1upD requested review from Blixibon and Sarethen October 20, 2026 04:56
@1upD

1upD commented Oct 20, 2026

Copy link
Copy Markdown
Author

DO NOT MERGE! Pending some more testing

@1upD
1upD marked this pull request as ready for review October 20, 2026 05:17
@1upD

1upD commented Oct 20, 2026

Copy link
Copy Markdown
Author

Should be ready to merge now!


pHurt->SetAbsVelocity( pHurt->GetAbsVelocity() + (right * 200) );
pHurt->SetAbsVelocity( pHurt->GetAbsVelocity() + (up * 100) );
pHurt->ApplyAbsVelocityImpulse(100 * (up - 2 * forward));

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why have was right changed to forward? Also, could right now trigger an unused variable warning, since it isn't passed into AngleVectors above?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right, right should be removed.

This was really confusing to me but if you turn on buddha or godmode and let the Gonome hit you with it's secondary melee attack, it actually pushes you to your right. I tested this out ingame with the current code. I believe this has always been a mistake because it doesn't really line up with the animation or make sense for the target to be pushed like that.

@1upD 1upD removed the DO NOT MERGE label Nov 5, 2026
@1upD
1upD force-pushed the ez2/feature/fix-gonome-velocity branch from ecf3d2e to 33d685f Compare November 9, 2026 06:25
@1upD
1upD merged commit 4c4fea9 into entropy-zero:ez2/mapbase Nov 9, 2026
5 checks passed
@1upD
1upD deleted the ez2/feature/fix-gonome-velocity branch November 9, 2026 06:26
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

Successfully merging this pull request may close these issues.

2 participants