I'm having issues with the "Corona SDK: Make a game in 8 minutes"

Hi, 

I’m having issues with the Make a game in 8 minutes tutorial. I have followed it using images I have, and cannot get the ball to move relative to the touch input rather than the balls x, y position. Here is my code, can any one see where I am going wrong?

Thanks.

[lua]_W = display.contentWidth
_H = display.contentHeight

– Add Physics Engine and Start
local physics = require(“physics”)
physics.start()

display.setStatusBar(display.HiddenStatusBar)

– Import Images

local background = display.newImage(“background.png”)
local floor = display.newImage(“floor.png”)
floor.y = _H-20
physics.addBody(floor,“static”,{friction = 10, bounce = 0})
local ball = display.newImage(“ball.png”)
ball.x = _W/2
physics.addBody(ball,{bounce = 0.2, radius = 40})

function moveBall(event)
local ball = event.target
ball:applyLinearImpulse(0,-0.1,event.x,event.y)
end

ball:addEventListener(“touch”,moveBall)[/lua]

It seems to be working for me, sort of.  I had to create my own floor and ball since I don’t have your art work.  It doesn’t move very much.  I had to change the 2nd parameter to the addLinearImpulse to like -0.3.

Are you getting any errors in your console log?  If you don’t know how to see the console log please read and bookmark this blog post for future reference:

http://www.coronalabs.com/blog/2013/07/09/tutorial-basic-debugging/

It seems to be working for me, sort of.  I had to create my own floor and ball since I don’t have your art work.  It doesn’t move very much.  I had to change the 2nd parameter to the addLinearImpulse to like -0.3.

Are you getting any errors in your console log?  If you don’t know how to see the console log please read and bookmark this blog post for future reference:

http://www.coronalabs.com/blog/2013/07/09/tutorial-basic-debugging/