local left = display.newImage ("leftx.png")
left.x = 30
left.y = 450
localGroup:insert(left)
local right = display.newImage ("rightx.png")
right.x = 290
right.y = 450
localGroup:insert(right)
-- Puts in all four movement arrow images and positions them
----------------------------------------------------------------------
-- MOVE BALLOON --
----------------------------------------------------------------------
function left:tap(event)
balloon.isFixedRotation = true
balloon.linearDamping = 1
balloon.angularVelocity = 0.1
balloon:setLinearVelocity( 0.1, 0.1 )
balloon:applyLinearImpulse( -0.2, -0.2, event.x, event.y )
end
left:addEventListener("tap",left)
function right:tap(event)
balloon.isFixedRotation = true
balloon.linearDamping = 1
balloon.angularVelocity = 0.1
balloon:setLinearVelocity( 0.1, 0.1 )
balloon:applyLinearImpulse( 0.2, -0.2, event.x, event.y )
end
right:addEventListener("tap",right)
this code works perfectly on the simulator (windows) but nothing happens when trying to tap on device (T-mobile G1, Froyo 2.2) [import]uid: 24981 topic_id: 6854 reply_id: 306854[/import]