Physics to odd formed objects?

Hello,

The title didn’t probably make much sense, but I am trying to make a racing game where you go from left to right. I would like to make hills and knolls, but I can only make the basic circles, rectangles, etc. Basically, am I able to, for example make an image with drawn hills and leave the rest transparent, so that only the “hills” could have the physics.body?

Hopefully somebody understood what I meant, couldn’t find a solution to this problem from the forums and internet.

Hi @roniback,

Yes, you can create custom polygon bodies, and multiple body parts on any one object, to create nearly any physics body shape you need. The first step is to read through the guide on physics bodies, esp. the section “Polygonal Bodies”:

http://docs.coronalabs.com/guide/physics/physicsBodies/index.html

Best regards,

Brent

Thanks, I will have a look! I guess I didn’t know the words to search with.

Hi @roniback,

Yes, you can create custom polygon bodies, and multiple body parts on any one object, to create nearly any physics body shape you need. The first step is to read through the guide on physics bodies, esp. the section “Polygonal Bodies”:

http://docs.coronalabs.com/guide/physics/physicsBodies/index.html

Best regards,

Brent

Thanks, I will have a look! I guess I didn’t know the words to search with.