Design 2, Design 4 (Computer and Video Games)
Unit 20 - 29th March 2003

Importing a Custom Character Model with UT2003 Animations

There is more than one way to get your model for a player pawn into Unreal. The method described underneath is based on a strategy developed by Wormslayer. Another way is demonstrated in a video tutorial which you can download here. (This is a 5.4 MegaBytes download which unzippes as an .avi file which you can play if you have DivX 5 installed.)

All right: back to Wormslayer's method, which proved to be reliable and fast.


This is a basic step by step instruction on how to import a custom character model using UT2003 default animations. The tutorial has originally been written by Wormslayer and has been updated and slightly modified for the most recent version of UT2003. I added another model, together with the .upl, .utx and .ukx files for you to experiment with. (Look at the last lines of this tutorial.)

The tutorial is based on a model called "Hitman", the first ever character model imported to UT2003.

You will need the ActorX plugins, for StudioMax.
StudioMax R4 requires
ActorX (vers. 4) (68.7 kB).
StudioMax R5 requires
ActorX (vers. 5)
(68.8 kB).


You can get the Hitman model by Wormslayer for UT2003 here.


Use 3dsmax to model, unwrap, texture and bone your model. (In 3dsmax select any biped, hit the motion tab and switch to figure mode. This will put the character you are working on into a nice position which makes it easy to adjust the biped.) If you are planning to make use of the ready-made character animation that comes with Unreal Tournament 2003, its important that your model fits the skeleton they used for their models - You can get away with a little difference in size by adjusting the character studio biped to fit your character but if your model's proportions are too different it will be weirdly distorted when the game engine stuffs the skeleton into it at run-time.

Use the ActorX plugin to export your model to a .PSK file, you would also export your animations here if you were going to replace or add to the default ones. If your planning on using one of the default skeletons, make sure you tick the Cull dummy objects option in the exporter, or you will end up with too many bones in your character and it wont link with the UT animations. 

Import your model into unreal editor and link it to an existing skeletal animation and karma rag-doll: Open the animation browser.
Load up the character set that you want to use the skeleton from (in my case for Hitman, I used HumanMaleA.ukx) 

Use the mesh import command on the file menu to bring your model into the package, at this time you can use a little time saving trick and force the editor to link your model with a karma actor (rag doll) - all you have to do is append the name of a .ka that's already in the game data to your mesh name. For my HitmanMesh model, I wanted to use the Male karma actor, so I imported the mesh into the package as "HitmanMesh_Male". 

You should now see your model in the mesh viewer with the default texture. You can apply your models skin by opening the texture editor and importing the bitmap, then in the mesh viewers Mesh properties tab (right hand side) using the new texture as the skin for your model.


The next stage is to socket your model. Sockets allow the engine to identify parts of your model. One socket you will need to set up is the weapon bone that tells the engine where to attach your guns, or the shoulder bones so it knows where to hang the little lights for team play, sockets are even used for decapitation and amputation. Setting them up manually is a pain in the ass, so luckily we can swap over to one of the UT2003 character models (I used one of the male mercenaries for Hitman) and hit the Copy mesh properties command on the Mesh menu, then swap back to your model and paste the mesh properties. Your model should suddenly become the right size and inherit a full set of working sockets. 

Now hit the Linkup anim and mesh command on the Edit menu, and your model should inherit all the animation sequences - try playing a few of them and take a look at your character in motion, see if there are any problems. 

Hopefully your model looks sweet, and all that's left to do now is to separate your model into its own ukx and utx packages - From the Mesh menu, select Rename Mesh, and change the package name to something unique then save the new file off to disk, also save off the skin as a utx from the texture browser (you might want to DXT1 compress the skin with texture browser before you save it.

Finally, all that's left is to write up a .upl file and add some bio info to the xplayers.int file and you should be fragging away with your model.

The file which tells Unreal Player Setup of what to display and what mesh, texture and behaviour to use for the player is called "Hitman.upl" (or any .upl filename you want to use.)
Take care to write everything into one single line.
I ended up in trouble, when I inserted linebreaks.

[Public]
Player=(DefaultName="Hitman",Mesh=HitmanModel.HitmanMesh_Male,
species=xGame.SPECIES_Merc,BodySkin=HitmanTextures.HitmanSkin,FaceSkin=HitmanTextures.HitmanSkin,
Portrait=HitmanTextures.HitmanPortrait,Text=XPlayers.HitmanBio,Sex=Male)

If you want to use the ActorX plugin, you should take care to have the correct version installed.
StudioMax R4 requires ActorX (vers. 4) (68.7 kB).
whereas StudioMax R5 requires ActorX (vers. 5) (68.8 kB).

 

Another complete set of textures, animation and Unreal player package is contained in UT2-Lady (some 4 MB).