This fixes lightsnaking through a finish line on sprint
maps not giving you a lap.
- On circuit maps, lightsnake stops at the finish line
waypoint (there's only one finish line)
- On sprint maps, there are multiple finish lines but you
can't have multiple finish line waypoints, therefore
lightsnake goes right through
- So we have to make sure the player can cross a finish
line while in lightsnake to account for this
- Because lightsnake sends you back to the respawn
waypoint in a straight line, it may inadvertently cross
a finish line and remove a lap
- So here's the change: the player should no-clip through
the finish line ONLY while traveling back to the first
waypoint
- Because after that, lightsnake follows the map's
waypoints and is intentionally crossing sprint maps'
finish lines
- Freeze finish line distance (instead of recalculating it
from old nextwaypoint)
- Reset auto respawn timer right before it runs out
(instead of AS SOON as finish line distance returns to
normal)
- Do not ever update respawn waypoint while auto respawn
timer is ticking
- Do not interact with finish line while auto respawn
timer is ticking
- Do not increment lap during lightsnake
- Symmetrical with decrement behavior
- Let lap be restored to higher safelap
- Prevent headaches if lap is erroneously decremented
- Previous order:
- K_HandleLapIncrement
- K_UpdateAllPlayerPositions
- Sets player->position
- !! Relies on player->exiting
- Set lap points
- !! Based on player->position
- Set latestlap
- P_DoPlayerExit
- Set player->exiting
- K_UpdateAllPlayerPositions
- Sets player->position
- Relies on player->exiting
- Overwrites latestlap if not set
- K_InitPlayerTally
- Based on lap points
- New order:
- K_HandleLapIncrement
- Set latestlap
- If ending last lap, P_DoPlayerExit
- Set player->exiting
- K_UpdateAllPlayerPositions
- Sets player->position
- Relies on player->exiting
- Overwrites latestlap if not set
- [NO LONGER INITS TALLY]
- OTHERWISE, K_UpdateAllPlayerPositions
- Sets player->position
- Relies on player->exiting
- Set lap points
- Based on player->position
- P_PlayerAfterThink
- If player is exiting and no tally, K_InitPlayerTally
Hopefully you can see the magnitude of the gordian knot I had to untangle to fix this
Before
- Each time / once only activates when the mobj's sector
changes
- The activation may depend on the mobj touching the floor
- If the mobj is in the air when the sector changes, the
action will never be activated
After
- Each time / once actions that require floor touching
also activate every time the mobj lands on the ground
from the air (regardless of whether the sector changed)
Notable deletions:
- Metal Sonic Race
- Includes all the specialised recording/playback apparatus which made g_demo.c harder to read
- A bunch of hyperspecialised code inside several A_ actions
- EXCEPTION: intentfully left in the spriteless SMK stuff for Sal's add-on down the line.
- Only play when your latestlap increases, since the thumbs up/down is what affects your Grade
- If knocked back over the line, stay on your latest lap value instead of going back down
- Moved destination tag off of linedef tag and into args.
- Bot controller values can be changed mid-level with ACS. (Linedefs using type 2004 will still be activated on level load.)
- Add flag to make bots fastfall
- Avoid iterating displayplayers to find view number and
prefer R_GetViewNumber.
- Iterate over all matching displayplayers if necessary,
instead of stopping at the first match.