I need help with making the actor/character stay on screen. When I tilt my device to either right or left. It disapears.
How do I solve this problem?.
I’ve been thinking about using walls. What would the code be for making walls on each side, using landscape mode. 320 x 480.
The accelerometer did only work in “potrait” but now when im using landscape it doesnt work…
-----Accelerometer
local motionx = 0
local function onAccelerate( event )
motionx = 20 * event.xGravity
end
Runtime:addEventListener (“accelerometer”, onAccelerate)
local function movecharacter (event)
character.x = character.x + motionx
end
Runtime:addEventListener(“enterFrame”, movecharacter)
Anyone have any ideas why it doesnt work in landscape mode?
Thanks. [import]uid: 134147 topic_id: 24181 reply_id: 324181[/import]