1
0
Fork 0
mirror of https://github.com/ninjamuffin99/Funkin.git synced 2024-12-03 20:23:46 +00:00

dont infinitely add new props, replace the old ones

This commit is contained in:
Cameron Taylor 2024-02-17 04:21:03 -05:00
parent 41cb3d93b2
commit 2baac0e983

View file

@ -632,10 +632,10 @@ class StoryMenuState extends MusicBeatState
function updateProps():Void
{
for (prop in currentLevel.buildProps(levelProps.members))
for (ind => prop in currentLevel.buildProps(levelProps.members))
{
prop.zIndex = 1000;
levelProps.add(prop);
if (levelProps.members[ind] != prop) levelProps.replace(levelProps.members[ind], prop) ?? levelProps.add(prop);
}
refresh();