How to stop rotating when collide happens.

I’m having obj1. I need to fix his “rotate position” (how to say it right by the way?) when it collides with other objects.

If you googled this question first, you’d have already found the answer. It’s not motivating to answer questions that I know would be answered by typing a simple query to google. Search for “corona fix rotation”, “corona fixed rotation”, etc. and you’ll find the answer.

Ugh, cant find anything. Please share the link.

P.S Ok, I made it by myself

Set this in the ‘begin’ phase of your collision listener:


local obj = display.newCircle( 10, 10, 10 ) function obj.collision( self, event ) if( event.phase == "begin" ) then self.isFixedRotation = true end return false end obj:addEventListener( "collision" )

Tip - Keep this link handy:

I personally use it every time I work on Corona games and apps, in fact I keep it on my bookmark bar:


Did you seriously write either to google? Typing ”corona fix rotation” or ”corona fixed rotation” bring the first result to the page that was linked.

pixec, YES I did write to google…