I have a ball that I want to roll down the slope of a triangle, but it just gets stuck wherever it touches the triangle. Can anyone help fix this so that the ball simply rolls down? Here’s how i made my triangle:
local triangle = display.newImage(“obstacles/triangle.png”)
triangleShape = { 30,-30, -30,30, 30,30 }
physics.addBody(triangle, “static”, { density = 0, friction = 0, bounce = 0.1, shape = triangleShape} )
** and here is how I made the ball
local ball = display.newImage(“balls/ball.png”)
physics.addBody( ball, “dynamic”, { density = 0.9, friction = 0, bounce = 0.1, radius = 14 } )
** I have also tried leaving off the dynamic body type and that didn’t do anything.
And none of my bodies are sleeping because I did this:
physics.start( true )
Thanks [import]uid: 42126 topic_id: 9217 reply_id: 309217[/import]