Can I stop rotation?

I have a objects that rotation with physics… can I make a way to fix my object in only one direction? [import]uid: 23063 topic_id: 11568 reply_id: 311568[/import]

Two ways to do it…

First, if you never want the object to rotate, use “yourObject.isFixedRotation = true”

If you want the object to stop rotating at a specific moment, use “yourObject.angularVelocity = 0”

Without more details, that’s about all I can offer. Hope it helps! [import]uid: 18951 topic_id: 11568 reply_id: 42022[/import]

What i want is a way to my object dont tilt when he go through grounds for him not to turn
something like that [import]uid: 23063 topic_id: 11568 reply_id: 42023[/import]

Hmm, I’m sorry, but I’m not sure what exactly you are asking. Unfortunately, there seems to be a language issue. Could you ask in your native language? I’m fluent in several languages (no guarantee, obviously).

Jeff [import]uid: 18951 topic_id: 11568 reply_id: 42025[/import]

speak portugues, Brazil? @_@ [import]uid: 23063 topic_id: 11568 reply_id: 42026[/import]

German? Spanish? Japanese? English? Sorry, no Portugues! Type it anyway, and I’ll see what Google translate says :slight_smile: [import]uid: 18951 topic_id: 11568 reply_id: 42027[/import]

this is the thing… I have a turtle that is a movieclip… and this turtle have linear Velocity apllied to throw the turtle forward… but in my scenario i have some unevenness that make the turtle tilt and sometimes (flip/turn down) leaving to backs down

how can I set a variable to check that if the turtle are with the backs down and change to normal again?

I tried in english :X [import]uid: 23063 topic_id: 11568 reply_id: 42028[/import]

in enterframe event handler you can check if turtle.rotation = 90 and if so make it 0… [import]uid: 48521 topic_id: 11568 reply_id: 42031[/import]

it’s not a rotation problem i guess… because when a object tilt and falls from top, this isnt a rotation, this “tilt”
i guess @_@
dont know [import]uid: 23063 topic_id: 11568 reply_id: 42033[/import]

In .lua, tilt and rotation are the same thing. If the goal is to keep the turtle off its back, i’d use chinmay’s solution, perhaps limiting the rotation to 30 or somethimg like that. Another idea is to build the turtle like a car, with the body connected to invisible “wheels”, so that it rolls along the ground, but stays upright. You will have to look into ‘joints’ to do this. [import]uid: 18951 topic_id: 11568 reply_id: 42069[/import]

Sorry, double post. [import]uid: 18951 topic_id: 11568 reply_id: 42070[/import]

i have follow your advice:

http://developer.anscamobile.com/forum/2011/06/27/problem-rotation-i-guess-or-gravity

if you can take a look and help me again :X

thanks [import]uid: 23063 topic_id: 11568 reply_id: 43041[/import]

Também não entendi o que vc quer fazer…tente em português …

Toni [import]uid: 18904 topic_id: 11568 reply_id: 43832[/import]