Yes.
Corona Simulator – Version 2013.1076 (2013.4.3)
This is the config.lua file complete
system.getInfo("model") if ( string.sub( system.getInfo("model"), 1, 4 ) == "iPad" ) then application = { content = { width = 360, height = 480, scale = "letterBox", xAlign = "center", yAlign = "center", imageSuffix = { ["@2x"] = 1.5, ["@4x"] = 3.0, }, }, } elseif ( string.sub( system.getInfo("model"), 1, 2 ) == "iP" and display.pixelHeight \> 960 ) then application = { content = { width = 320, height = 568, scale = "letterBox", xAlign = "center", yAlign = "center", imageSuffix = { ["@2x"] = 1.5, ["@4x"] = 3.0, }, }, } elseif ( string.sub( system.getInfo("model"), 1, 2 ) == "iP" ) then application = { content = { width = 320, height = 480, scale = "letterBox", xAlign = "center", yAlign = "center", imageSuffix = { ["@2x"] = 1.5, ["@4x"] = 3.0, }, }, } elseif ( display.pixelHeight / display.pixelWidth \> 1.72 ) then application = { content = { width = 320, height = 570, scale = "letterBox", xAlign = "center", yAlign = "center", imageSuffix = { ["@2x"] = 1.5, ["@4x"] = 3.0, }, }, } else application = { content = { width = 320, height = 512, scale = "letterBox", xAlign = "center", yAlign = "center", imageSuffix = { ["@2x"] = 1.5, ["@4x"] = 3.0, }, }, } end
This is the home.lua file – the first scene I have in a storyboard.
-- --==\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*++-- -- local storyboard = require( "storyboard" ) local scene = storyboard.newScene() ------------------------------------------------------------------------------------------ function scene:createScene( event ) local group = self.view local bg = display.newImageRect ("bg.jpg", 1035, 785) bg.x = display.contentWidth - 200 bg.y = display.contentHeight - 150 local myRectangle = display.newRect(200, 100, 40, 50) myRectangle.strokeWidth = 3 myRectangle:setFillColor(140, 140, 140) myRectangle:setStrokeColor(180, 180, 180) local myCircle = display.newCircle( display.contentWidth -250, display.contentHeight, 30 ) myCircle:setFillColor(128,128,128) end ------------------------------------------------------------------------------------------ function scene:enterScene( event ) local group = self.view end ------------------------------------------------------------------------------------------ function scene:exitScene() end ------------------------------------------------------------------------------------------ function scene:destroyScene( event ) local group = self.view end ---------------------------------------------------------------------------------- scene:addEventListener( "createScene", scene ) scene:addEventListener( "enterScene", scene ) scene:addEventListener( "exitScene", scene ) scene:addEventListener( "destroyScene", scene ) return scene
It’s as simple as I can, just to make sure it works in all the devices.
The way it is right now all I can see it’s the center of the background (bg)
the background image it’s 1035x785
Let me know…
Thank you Rob