Hello my friends.
I do not speak english, then this topic will use the divine help of google translator. Hope you understand. Really.
Even searching I have not found a detailed tutorial on using the accelerometer.
I would like to make a game “Get the ball to the hole,” using the aceleremetro to guide the ball.
Are there any detailed tutorial for beginners that?
I’m sorry for bad English.
But only one problem.
Look at the code:
function movimento(event)
balao.x = (balao.x + event.xGravity * 20)
balao.y = (balao.y + event.yGravity * 20)
balao1.x = (balao1.x + event.xGravity * 20)
balao1.y = (balao1.y + event.yGravity * 20)
end
“balao” and “balao1” are the “balls” I want to move.
But in the Y axis they move, but the X axis gives an error.
What is the error?
Are the balls physics objects or normal display objects?
But only one problem.
Look at the code:
function movimento(event)
balao.x = (balao.x + event.xGravity * 20)
balao.y = (balao.y + event.yGravity * 20)
balao1.x = (balao1.x + event.xGravity * 20)
balao1.y = (balao1.y + event.yGravity * 20)
end
“balao” and “balao1” are the “balls” I want to move.
But in the Y axis they move, but the X axis gives an error.
What is the error?
Are the balls physics objects or normal display objects?