guys,
I am using the openPopUp to open another scene when a pause button is clicked… works great… but on this scene I have a button that should restart the level when it is clicked…
i tried using…
director:closePopUp()
director:changeScene( “level1” )
this restarted the level but started saying that it did not know abt contentHeights and contentWidths… odd errors…
so just to check my code… i added the following to the pause button event (rather than calling the "openPopUp ")
clean() – I created a function to clean objects
director:changeScene( “level1” )
it works fine…
my question is a two parter…
- is there a way to call the clean() function in a particular scene?
- is there a way to pass the button press back to the level so I can clean() then call the change…
or is there a better way? [import]uid: 67619 topic_id: 14281 reply_id: 314281[/import]