0 votes

In a lot of ways it seems that its far easier to add an animation node and just loop the movement/rotation of nonplayer objects like platforms, etc. Is their any drawback to doing this instead of scripting the objects to have this behavior?

Like for instance I cant set an object to rotate by creating AnimationPlayer node, making new animation in table, setting rot 0 to 0 in table than setting rot 360 to 1 in the table. How would you be able to control the angle or speed of the rotation with animations?

Or is something like that only possible with a combination of script and animation?

in Engine by (58 points)
edited by

2 Answers

+1 vote
Best answer

Animations are not relative, rotation 0 is always rotation 0. That's their main drawback, though you can often get around that by using nested nodes. Making an object constantly rotate sounds like a good use for animations though. You can control the speed of the animation through script or even another animation.

by (543 points)
selected by
+1 vote

0 is on top.
A rotation is 2*Pi (Pi=3.141592653589793238...).
If you're using a positive value, the rotation goes anticlockwise.
If you're using a negative value, the rotation goes clockwise.
You can use Pi by typing "PI".

by (16 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.