Thread: [TEC] Modding SH3
View Single Post
Old 05-24-2016, 11:37 AM   #46
Sonar Guy
Join Date: Oct 2009
Location: Sofia, Bg
Posts: 382
Downloads: 264
Uploads: 1

Default How to adjust axis direction to your needs.

I'm here just for day, but this is enough for sharing the three quick tricks.

First one:
How to adjust axis direction to your needs.

One easy example is with UZO. The new modded boats and turms have this feature, but I don't have computer that will handle all these new models stuff, so I want to make this for stock turms.

You will work with the turm .dat file, in this example: "Turm7c_1_hd.dat".
First, if you give a dial controller (SolBearing) to the UZO node, it will rotate the X axis. So let's look, what will happen when the dial controller rotate the X axis.
This will not be good:

If you rotate the Z axis with -90, this will put the X axis in the needed direction,
but because the 3d model is in this node, it is again not good:

So, you first create a new node, name it something recognizable, in this case "Turm7c_1_UzoRot".
For Translation X, Y and Z you give the same coordinates that are in the original UZO node (Turm7c_1_uzo_High).
Then rotate the Z axis with -90 (half a Pi):

Now, for the original node, you make it child of the new node. Change Parent id with the Id of the new node (UzoRot).
Give 0,0 for Translation X, Y and Z, and rotate the Z axis with +90:

A small adjustment on Y and Z, to catch up some asymmetry between the UZO and its base when is rotated:

Now for test, you rotate manually the X axis of UzoRot, and you see that the rotation is correct.
Bring it back to 0,0 and save the file:

Next, you open the turm .sim file and create a new dial controller. Make it Type = SolBearing.
Make DispVal and RealVal = 0 - 360. And for Parent id: give it the Id of the UzoRot node from the .dat file.
Save the file:

Now in the game, the model of the UZO will rotate according to the bearing that is pointed:
If you ride like lightning, you're gonna crash like thunder.

Last edited by Tycho; 05-30-2016 at 06:25 AM.
Tycho is offline   Reply With Quote