reset flag when it hits a death-tile; ticket #513

This commit is contained in:
Dominik Geyer 2008-10-18 20:37:41 +00:00
parent 9d1c56e2fd
commit 3cdb90c10c
2 changed files with 8 additions and 0 deletions

View file

@ -601,6 +601,7 @@ void CHARACTER::tick()
core.input = input;
core.tick(true);
// handle death-tiles
if(col_get((int)pos.x, (int)pos.y)&COLFLAG_DEATH)
die(player->client_id, -1);

View file

@ -73,6 +73,13 @@ void GAMECONTROLLER_CTF::tick()
if(!f)
continue;
// flag hits death-tile, reset it
if(col_get((int)f->pos.x, (int)f->pos.y)&COLFLAG_DEATH)
{
f->reset();
continue;
}
//
if(f->carrying_character)
{