My question is why isn’t scene:show getting affected by the scene change effect?
Heres the main.lua.
local composer = require( "composer" ) composer.gotoScene( "menu", { time = 1000, effect = "crossFade" } )
And here is menu.lua.
local composer = require( "composer" ) local scene = composer.newScene() ------------------------------------------------------------------------------------------ centerX = display.contentCenterX centerY = display.contentCenterY actualH = display.actualContentHeight actualW = display.actualContentWidth ------------------------------------------------------------------------------------------ function scene:create( event ) local sceneGroup = self.view end function scene:show( event ) local sceneGroup = self.view local phase = event.phase if ( phase == "did" ) then local BG = display.newRect( 0, 0, actualW, 120 ) BG.x = centerX BG.y = centerY - actualH/2 + 120/2 sceneGroup:insert(BG) end end scene:addEventListener( "create", scene ) scene:addEventListener( "show", scene ) return scene
If i put the BG image in the scene:create then it cross fades like normal but if its in the show then it doesnt show up until the transition is complete.
–SonicX278