Remove player on finish level
parent
d3ea551024
commit
e00e1ff8d2
|
@ -144,6 +144,9 @@ static unsigned int player_finish_transition_func(Entity_t* ent)
|
||||||
if (p_spr->current_frame == p_spr->sprites[p_spr->current_idx].sprite->frame_count - 1)
|
if (p_spr->current_frame == p_spr->sprites[p_spr->current_idx].sprite->frame_count - 1)
|
||||||
{
|
{
|
||||||
p_spr->pause = true;
|
p_spr->pause = true;
|
||||||
|
// This entity has no special init, so it's fine to remove
|
||||||
|
// at end of animation
|
||||||
|
remove_entity(ent->manager, ent->m_id);
|
||||||
}
|
}
|
||||||
return p_spr->current_idx;
|
return p_spr->current_idx;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue