Game Development Community

Is there a way to spin or rotate a shape in script?

by Bob Dietz · in Technical Issues · 09/16/2006 (4:37 pm) · 3 replies

I just started looking at torque. I want to spin or rotate a simple shape in script. I've seen an angVelocity and other suggestive variables and setTransform but haven't been able to get them to work fro rotation. I've tried setting them in OnCollision and it goes through the code but generally has no effect. I'm trying to avoid rigidbody stuff because I couldn't stop the shapes from going into the terraine and ODE physics is probably overkill.

Anyway, is there an easy way to spin a shape in script?

About the author

Recent Threads


#1
09/16/2006 (5:34 pm)
"Anyway, is there an easy way to spin a shape in script?"

No.
#2
09/16/2006 (7:43 pm)
It's not easy to get objects to move smoothly thru script commands. as stupid as it sounds... that's not a feature available to static object.

You might be better off with an animation setup.
#3
09/17/2006 (8:21 am)
If the object is a scripted item, there is a simple step to making it spin. Look in item.cs and you'll see how it's done.