game image sizes for ipad help.

[lua] local drawBackground = function()

background = display.newImageRect( “bg1.png”, 853, 640 )
background.x 853; background.y = 640

gameGroup:insert( background )

ground = display.newImageRect( “collision.png”, 960, 150 )
ground.x = 960; ground.y = 150

ground.myName = “ground”

local groundShape = { -285,-18, 285,-18, 285,18, -285,18 }
physics.addBody( ground, “static”, { density=1.0, bounce=0, friction=0.5, shape=groundShape } )

gameGroup:insert( ground )
end
[/lua]

Doesn’t seem to work because I still get a blank screen in simulator. And then theirs the objects in the game. The object falling during gameplay is 100x 100 pixels, while the bag( which the player controls) 215 x 215.

[lua]l
ocal lyDensity = 1.0
local lyShape = { -12, 13, 12,-13, 12,13, -12,13 }
local bagShape = { 15, -13, 65,-13, 65,13, 15,13 }[/lua]
[import]uid: 128294 topic_id: 29717 reply_id: 329717[/import]

Hi there,

When you say you get a blank screen in the simulator, do you mean your images don’t appear at all? Are you sure the images loaded properly? (Check the console/terminal output to make sure there are no errors loading the images.) Also, the coordinates for your images are quite high – depending on your width and height settings in config.lua, it’s possible that you’re accidentally placing the images off screen.

  • Andrew [import]uid: 109711 topic_id: 29717 reply_id: 119308[/import]

If I recall, before I started from scratch again, I think I had the screen size 1028 x 768. [import]uid: 128294 topic_id: 29717 reply_id: 119322[/import]

I think I see the problem. Is that code copied and pasted directly from your app/game? If it is, you can see on the 4th line you’ve done this: [lua]background.x 853[/lua] instead of [lua]background.x = 853[/lua]. And I’m expecting that that second part was not copied and pasted, as you have that ‘local’ on two separate lines.

quinc [import]uid: 147322 topic_id: 29717 reply_id: 119338[/import]

@quinc

With equals? For the second part, forum wont let me edit post, that’s why lowercase L is on top. before I erased maingame.lua file, it wasn’t like that. Isn’t their a way to modify configurations to do two screensizes for ipad 2 and ipod/iphone screens? Thought a couple of months ago I saw a example game that requires a “@X2” command. [import]uid: 128294 topic_id: 29717 reply_id: 119368[/import]