- Duke: Do not let the max kill counter underflow.

The entire thing looks broken anyway but this at least prevents the broken values from showing up in the statistics.
This commit is contained in:
Christoph Oelckers 2020-03-01 08:35:05 +01:00
parent 70f684d137
commit cd5ff69c98

View file

@ -4639,7 +4639,7 @@ ACTOR_STATIC void G_MoveActors(void)
// JBF 20041129: a slimer eating another enemy really ought
// to decrease the maximum kill count by one.
if (sprite[pData[5]].extra > 0)
if (sprite[pData[5]].extra > 0 && g_player[myconnectindex].ps->max_actors_killed > 0)
g_player[myconnectindex].ps->max_actors_killed--;
}
}