fix occasional crash when flood fill deleting
This commit is contained in:
parent
bd0b779bd0
commit
4746474127
@ -1432,8 +1432,13 @@ int Simulation::FloodParts(int x, int y, int fullc, int cm, int flags)
|
||||
cm = pmap[y][x]&0xFF;
|
||||
if (!cm)
|
||||
cm = photons[y][x]&0xFF;
|
||||
if (!cm && bmap[y/CELL][x/CELL])
|
||||
FloodWalls(x, y, WL_ERASE, -1);
|
||||
if (!cm)
|
||||
{
|
||||
if (bmap[y/CELL][x/CELL])
|
||||
return FloodWalls(x, y, WL_ERASE, -1);
|
||||
else
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
else
|
||||
cm = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user