mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-23 10:09:43 +01:00
Fix regression from 2.3 with destroy(platforms)
2.3 introduced a regression with destroy(platforms). The problem was that isplatform wasn't being set to false when the entity got disabled, so if the platform was moving, it would keep moving until it hit a wall, instead of stopping immediately.
This commit is contained in:
parent
b677e7e39f
commit
1297b09c47
1 changed files with 3 additions and 1 deletions
|
@ -1106,6 +1106,7 @@ bool entityclass::disableentity(int t)
|
||||||
entities[t].size = -1;
|
entities[t].size = -1;
|
||||||
entities[t].type = -1;
|
entities[t].type = -1;
|
||||||
entities[t].rule = -1;
|
entities[t].rule = -1;
|
||||||
|
entities[t].isplatform = false;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -1223,7 +1224,8 @@ void entityclass::createentity(int xp, int yp, int t, int meta1, int meta2, int
|
||||||
if (entities[i].invis
|
if (entities[i].invis
|
||||||
&& entities[i].size == -1
|
&& entities[i].size == -1
|
||||||
&& entities[i].type == -1
|
&& entities[i].type == -1
|
||||||
&& entities[i].rule == -1)
|
&& entities[i].rule == -1
|
||||||
|
&& !entities[i].isplatform)
|
||||||
{
|
{
|
||||||
reuse = true;
|
reuse = true;
|
||||||
entptr = &entities[i];
|
entptr = &entities[i];
|
||||||
|
|
Loading…
Reference in a new issue