Set sprite frame to 0 when dead.

This commit is contained in:
Steve 2018-02-09 22:34:01 +00:00
parent 31d55d6954
commit 972c3c4aa9
2 changed files with 2 additions and 0 deletions

View File

@ -152,6 +152,7 @@ static void activate(int active)
static void die(void) static void die(void)
{ {
self->spriteFrame = 0;
self->alive = ALIVE_DEAD; self->alive = ALIVE_DEAD;
} }

View File

@ -201,6 +201,7 @@ void doEntities(void)
if (self->health <= 0) if (self->health <= 0)
{ {
self->alive = ALIVE_DYING; self->alive = ALIVE_DYING;
self->spriteFrame = 0;
self->die(); self->die();
} }