1
0
Fork 0
mirror of https://github.com/TerryCavanagh/VVVVVV.git synced 2024-12-22 17:49:43 +01:00

Only spawn activity zone if the script exists

This commit is contained in:
AllyTally 2023-08-22 22:23:08 -03:00 committed by Misa Elizabeth Kai
parent 02ace10df9
commit c3b0a60aa4

View file

@ -1918,9 +1918,14 @@ void mapclass::loadlevel(int rx, int ry)
}
obj.createentity(ex, usethisy + 8, 20 + SDL_clamp(ent.p2, 0, 1), usethistile);
if (obj.customscript != "")
for (size_t i = 0; i < script.customscripts.size(); i++)
{
obj.createblock(ACTIVITY, ex - 8, usethisy + 8, 20, 16, 35);
if (script.customscripts[i].name == obj.customscript)
{
obj.createblock(ACTIVITY, ex - 8, usethisy + 8, 20, 16, 35);
break;
}
}
break;
}