I’m having some problems trying get level changes to work.
I have a listener checking for when the player’s score reaches 5.
At which point, I want to load a new level.
But it still displays the current level, and the player is no longer controllable.
Also, how do you preview/play-test different level files (level1.lua, level2.lua) if the simulator will only run “main.lua”?
-- Beat Level1
local function beatLevel1()
if score == 5 then
storyboard.gotoScene( "scene2", "fade", 400 )
end
end
Runtime:addEventListener("enterFrame", beatLevel1)
Much Thanks! [import]uid: 27117 topic_id: 18762 reply_id: 318762[/import]