DSQ code vs Animated DTS code
by Demolishun · in Torque Game Engine · 06/09/2006 (9:08 am) · 5 replies
Okay you have the player object that can play DSQs attached at runtime to a DTS in the engine. The player can also use animations that are actually in the DTS file to begin. What in the player code allows the player to play the DSQ animations attached to the object?
I am using the referred to here:
www.garagegames.com/mg/forums/result.thread.php?qt=37627
But for the life of me I cannot tell what the difference is between his code and the player code is as far as animations. The preload function in the animatedvehicle class fails to see the animations attached to the DTS. Is the DSQ connection happening outside of the class?
Thanks,
Frank Carney
I am using the referred to here:
www.garagegames.com/mg/forums/result.thread.php?qt=37627
But for the life of me I cannot tell what the difference is between his code and the player code is as far as animations. The preload function in the animatedvehicle class fails to see the animations attached to the DTS. Is the DSQ connection happening outside of the class?
Thanks,
Frank Carney
About the author
I love programming, I love programming things that go click, whirr, boom. For organized T3D Links visit: http://demolishun.com/?page_id=67
#2
06/10/2006 (1:43 pm)
Eh... what're you looking for other than this?datablock TSShapeConstructor(PlayerDts)
{
baseShape = "./player.dts";
sequence0 = "./player_root.dsq root";
sequence1 = "./player_forward.dsq run";
sequence2 = "./player_back.dsq back";
sequence3 = "./player_side.dsq side";
sequence4 = "./player_lookde.dsq look";
sequence5 = "./player_head.dsq head";
sequence6 = "./player_fall.dsq fall";
sequence7 = "./player_land.dsq land";
sequence8 = "./player_jump.dsq jump";
sequence9 = "./player_diehead.dsq death1";
sequence10 = "./player_diechest.dsq death2";
sequence11 = "./player_dieback.dsq death3";
sequence12 = "./player_diesidelf.dsq death4";
sequence13 = "./player_diesidert.dsq death5";
sequence14 = "./player_dieleglf.dsq death6";
sequence15 = "./player_dielegrt.dsq death7";
sequence16 = "./player_dieslump.dsq death8";
sequence17 = "./player_dieknees.dsq death9";
sequence18 = "./player_dieforward.dsq death10";
sequence19 = "./player_diespin.dsq death11";
sequence20 = "./player_looksn.dsq looksn";
sequence21 = "./player_lookms.dsq lookms";
sequence22 = "./player_scoutroot.dsq scoutroot";
sequence23 = "./player_headside.dsq headside";
sequence24 = "./player_recoilde.dsq light_recoil";
sequence25 = "./player_sitting.dsq sitting";
sequence26 = "./player_celsalute.dsq celsalute";
sequence27 = "./player_celwave.dsq celwave";
sequence28 = "./player_standjump.dsq standjump";
sequence29 = "./player_looknw.dsq looknw";
};It loads all the sequences and assigns names to them with the text after the filename. It doesn't work with vehicles or something?
#3
I just tried using DSQs with a staticshape object and it worked fine. Now I have another object to compare code to the animatedvehicle class. Tim is going to be working on a resource for his code, but it is not out yet. He has not added DSQ support either.
06/10/2006 (1:48 pm)
No, vehicles are a bit different. But Tim Hutcheson has pioneered some C++ code to add that capability. However, the code he handed me does not yet work with DSQs. I have compared the code he pulled out of the player.cc file and for the life of me I cannot tell the difference. I was hoping someone else has traveled this path. I just tried using DSQs with a staticshape object and it worked fine. Now I have another object to compare code to the animatedvehicle class. Tim is going to be working on a resource for his code, but it is not out yet. He has not added DSQ support either.
#4
06/10/2006 (1:58 pm)
That's odd, if it's in StaticShape then it's probably something implemented in ShapeBase and the vehicle class does something to break it instead of add it. Since StaticShape is a super minimal derivation of ShapeBase, and I don't see any code in it relevant to animation.
#5
06/10/2006 (5:31 pm)
Yah, that really confused me. I will have to go through the vehicle code to see what happened.
Torque Owner Demolishun
DemolishunConsulting Rocks!