mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2025-01-24 18:11:10 +00:00
5e5217e549
This crash was found by DanielGibson, he even guessed the right fix without having a usable coredump. ;) In boss1.bsp Macron is waiting for the player, despawning as soon as the player moves to him. After that the player needs to press 2 buttons, each button triggers 3 flyers. If the player is fast enough, the first bunch of flyers may spawn before macron is despawned. Now there's a small chance that a flyer decides to attack macron... If Macron despwans at the the next frame, self->enemy is set to NULL (Macron is gone) but nevertheless flyer_fire() is called. The correct fix would be to call flyer_fire() before Macron despawns, but that's hard to impossible. So take the easy route and check if self->enemy is not NULL. |
||
---|---|---|
.. | ||
backends | ||
client | ||
common | ||
game | ||
server |