beyond-all-reason / beyond-all-reason/RecoilEngine
Slopes speed modifier miscalculation
- Dominant language
- C++
- Stars
- 679
- Forks
- 290
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 40
Description
MoveMath uses average slopes for the speed modifier, but individual triangles' normals to check for downward/upward.
This means that on a steep upward slope a unit could get a movespeed increases if a single triangle is downward
https://github.com/beyond-all-reason/spring/blob/d69fb498bed99f075f37df480ea970ceb3c7c686/rts/Sim/MoveTypes/MoveMath/MoveMath.cpp#L82
https://github.com/beyond-all-reason/spring/blob/d69fb498bed99f075f37df480ea970ceb3c7c686/rts/Sim/MoveTypes/MoveMath/MoveMath.cpp#L86
Contributor guide
Research direction
Start in rts/Sim/MoveTypes/MoveMath/MoveMath.cpp at the linked lines 82 and 86. Trace how average slopes and individual triangle normals determine the speed modifier, then verify the behavior on a steep upward slope. Done means the modifier no longer increases because of a single downward-facing triangle.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- game-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100