Trail Rotates In Wrong Direction
by David Taylor · in Torque Game Builder · 10/18/2007 (8:37 pm) · 2 replies
I've already posted this in the Behaviours subforum, but thought it belonged here, too.
I'm just starting out looking at behaviours. I've got a simple tank sprite which I have given tank controls. I have mounted a very basic trail effect - the image is simply two vertical yellow lines.
When I drive the tank forward, the yellow tracks follow behind and fade away. But as soon as I turn the tank, the tracks seem to rotate in the opposite direction.
I've linked an image that contains portions of three screen captures that demonstrate what's going on here. Does anyone have any idea as to how I can get the tracks to follow where the tank's tracks have actually gone?
http://img.photobucket.com/albums/v649/jesbass/TankMovement001.jpg
I'm just starting out looking at behaviours. I've got a simple tank sprite which I have given tank controls. I have mounted a very basic trail effect - the image is simply two vertical yellow lines.
When I drive the tank forward, the yellow tracks follow behind and fade away. But as soon as I turn the tank, the tracks seem to rotate in the opposite direction.
I've linked an image that contains portions of three screen captures that demonstrate what's going on here. Does anyone have any idea as to how I can get the tracks to follow where the tank's tracks have actually gone?
http://img.photobucket.com/albums/v649/jesbass/TankMovement001.jpg
About the author
#2
10/23/2007 (11:16 pm)
Mount your object in script then you can set the attachrotation mode to true. Look at the documentation for the t2dSceneObject mount() function in the TGB reference for details.
Torque Owner David Taylor