[FIX] Sistema de navegació entre pantalles (flow)

- Optimitzat el logo. Ara necessita menys memòria aprofitant les funcions de paleta
This commit is contained in:
2026-04-03 15:29:44 +02:00
parent 2564c54b3e
commit ca0393046e
8 changed files with 147 additions and 95 deletions

View File

@@ -164,9 +164,8 @@ function start_scene(scene,offset)
if offset then scenes.offset=offset end
-- old_update=game_update
-- game_update=update_scene
-- flow:add("save", game_update)
flow:add("scene",update_scene)
flow:call("scene")
flow:executar("scene", true); -- guardar l'estat anterior i executar
end
function playtext(snd)
@@ -284,7 +283,8 @@ function update_scene()
-- fade.fadeoutin()
-- else
-- game_update=old_update
flow:restore()
-- flow:restore()
flow:next()
-- end
else
scenes.dnum=scenes.dnum+1
@@ -305,8 +305,9 @@ function update_scene()
if (key.press(key.ESCAPE) or pad.press(btnPause)) and (scenes.current_scene~=scenes.final) then
if scenes.current_scene[scenes.dnum].die then
-- game_init(true)
flow:next()
-- flow:next()
-- game_update = menu_init
flow:executar("title")
else
pause()
end
@@ -322,7 +323,7 @@ function update_scene()
-- fade.fadeoutin()
-- else
-- game_update=old_update
flow:restore()
flow:next()
-- end
else
scenes.dnum=scenes.dnum+1
@@ -333,3 +334,9 @@ function update_scene()
scenes.step=8
end
end
function end_scene()
flow:finish()
end
flow:registrar("scene",{update_scene})