Scale a DTS character
by Takuan Daikon · in Torque X 2D · 10/06/2008 (7:57 pm) · 5 replies
I'm trying to figure out how all of this stuff works, and I've added player.dts from the TGE demo to my scene, which for the most part is working just fine. However, once I added a RigidComponent to the scene file, I've discovered that my player's Scale value is being set to <1,1,1> somewhere by the TX engine, making the model look incredibly small. If I remove the RigidComponent definition, the scale is fine.
Anyone have any tips on how to deal with DTS models that you wish to scale?
Anyone have any tips on how to deal with DTS models that you wish to scale?
#2
11/01/2008 (1:15 am)
float scale = 5f; your3Dshape.ShapeScale = new Microsoft.Xna.Framework.Vector3(scale);
#3
The ShapeScale property only exists on the T2DShape3D class, and I am not using that class. I am working strictly in a 3D project based on the 'Starter Game 3D (Pro)' project type.
The closest thing I could find was the Scale property of the T3DSceneComponent class, which exhibits the behavior I described above, where the scale is not retained once I add a RigidComponent to the scene file.
If I try to 'force' the scale by setting it in the game's update method, then things get *really* out of whack, and the character shape just starts listing to the side and jerking repeatedly.
11/01/2008 (5:56 am)
Zilla, thank you very much for responding, I appreciate that! Unfortunately, I was not clear enough about the problem I am having, and your answer does not work.The ShapeScale property only exists on the T2DShape3D class, and I am not using that class. I am working strictly in a 3D project based on the 'Starter Game 3D (Pro)' project type.
The closest thing I could find was the Scale property of the T3DSceneComponent class, which exhibits the behavior I described above, where the scale is not retained once I add a RigidComponent to the scene file.
If I try to 'force' the scale by setting it in the game's update method, then things get *really* out of whack, and the character shape just starts listing to the side and jerking repeatedly.
#4
Maybe it's a bug or it's not possible to scale such a rigged and animated character...
I think that I read something about that in the Torque Game Engine forums but I cannot find it...
11/01/2008 (6:26 am)
Quote:The ShapeScale property only exists on the T2DShape3D classOf course, you are correct.
Quote:where the scale is not retained once I add a RigidComponent to the scene fileI tested it with the same results and could not find a solution :(
Maybe it's a bug or it's not possible to scale such a rigged and animated character...
I think that I read something about that in the Torque Game Engine forums but I cannot find it...
#5
11/01/2008 (6:46 am)
Thank you Zilla for double-checking. At least I know it's not just me with the problem :)
Torque Owner Takuan Daikon
I find it hard to believe that I'm the first person in the (admittedly short) history of TX to try and scale a DTS character...
I know the workaround is to do the resize in Max and re-export, but that's a bit of a pain in the rear end when you actually *want* some size variation in your game and would rather not have to have individual models for each variation.