- FIX: Ordenar correctament als actors en Z al començar un nivell

This commit is contained in:
2023-02-02 15:41:54 +01:00
parent 545dc96545
commit 1f4274f278
2 changed files with 6 additions and 3 deletions

View File

@@ -132,11 +132,13 @@ actors={
v.dy=v.dy+1 v.dy=v.dy+1
end end
end end
if needs_sorting then if needs_sorting then actors.sort() end
table.sort(actors.list, compare_actors)
end
actors.updating=false actors.updating=false
end,
sort=function()
table.sort(actors.list, compare_actors)
end end
} }

View File

@@ -51,6 +51,7 @@ game={
else else
update=game.update update=game.update
end end
actors.sort()
fade.fadein() fade.fadein()
end, end,