Game Development Community

Replace Orc in Demo

by Will Harrison · in General Discussion · 08/14/2004 (12:44 pm) · 4 replies

I'm new with Torque still, and I would like to know...

How would you replace the orc player in the torque demo with a static shape?

I would like to have it animated, but for simplicity's sake, how would you just get a static shape moving around as the player?

I tried replacing the dts file for the player, but there are so many extra things there and references in the scripts that it crashes every time.

Where do I start?

#1
08/14/2004 (1:26 pm)
In order for your shape to work as a player in the torque demo, you need to have it setup as one, with the extras like bounding box and mount points or it will just crash.

Check the documentation in the torque technology resources and that will help you get started. i would start here: http://www.alexswanson.com/torque/dts/

and choose the exporter for the package you're using and check its documentation available on that page.
#2
08/14/2004 (1:43 pm)
You should be able to do it if the shape you are using has at least one animation. There may be other issues, but if the shape has an animation, it should be able to be used as a player without crashing the game.
#3
08/14/2004 (6:54 pm)
Thanks for the link...

Well, before I start reading through the docs, can you guys tell me, what do you do when you're starting a new game/project and you want to start by putting your character into the engine and make it interactive. Let's say all you have is the textured model for the character and it has some basic animations... like this:

myPlayer.cs
myPlayer.dts
myPlayerIdle.dsq
myPlayerRun.dsq

I don't know what you would normally do, but lets suppose that's the result... so, how do you go from there to getting it into the engine as a player? What's your process?
#4
08/14/2004 (7:08 pm)
I just make a directory for the new player.. and then I point the server/script player.cs to the riht driectory and change all the appropriate paths in that file to point to the new directory. I usually comment out the old path and put in a new one (instead of doing a search/replace) so that if there are any problems, it is easy to go back to the default player setup to clear up any script issues.

Note that the player.cs is server scripts is usually responsible for exec'ing the player.cs that resides in the directory with the player shape. That player.cs simply combines the DTS and tht DSQs into one model in memory. This path with also need to be changed.

I usually throw in the model with one animation (the run) and just start tweaking.