Outfitting a 3D Model for the Content Pipeline
From Trinity Reign Wiki
Outfitting your freshly completed 3D model for the content pipeline is important because if you try to just simply export your model and stick it in game, something weird will probably happen. First you have to prepare it. Doing so is very straightforward and this guide will show you how to do it with minimal effort.
Part 1: Spank My Monkey
So you've created a beautiful monkey head statue for the game and now you want to bring it to life in Trinity Reign. http://s2.photobucket.com/albums/y46/denreaper/?action=view¤t=monkey_render.png
First and foremost you need to create a physics object for your monkey head. The physics objects must be comprised only of cube primitives. You may scale and rotate these in whatever way you need to, just don't edit the vertices. The physics object doesn't need to match the model perfectly; here is a good example of a physics object for the monkey statue: http://s2.photobucket.com/albums/y46/denreaper/?action=view¤t=monkey_physicsobject1.png Note that the box around the monkey is the physics object. Note that you can have multiple boxes if you need them.
Part 2: Kicking Ass and Taking Names... Or Just Taking Names...
Now we move on to the way the physics objects are loaded into the game. Let's say that our monkey model is named "mr_monkey." The physics objects need to follow with something such as mr_monkey_physics_1. You'll want to name them like this for organizational purposes. From there, you need to make a file named "mr_monkey.phy." You don't have an option here. This has to be the name of it. Now on the top line write "mr_monkey_physics_1.mesh.xml" without the quotations. In this file you place the physics object file names (we use mesh.xml for our physics objects) which will be used for a particular model.
Here's an example of a setup of files where there is a model with 3 attached physics objects:
- house.mesh
- house.phy
- house_physics_1.mesh.xml
- house_physics_2.mesh.xml
- house_physics_3.mesh.xml
The contents of house.phy simply are as follows:
house_physics_1.mesh.xml
house_physics_2.mesh.xml
house_physics_3.mesh.xml
Part 3: The Ass-end of the Article (I just wanted to add a curse word)
Another thing to note is that models which are generally there to add detail don't usually need a physics object. As a good guideline, don't add a physics object for the model if it's intended to be pretty small (a fourth of the size of the player or smaller) or is originally intended to be a prop for decorating a room or similar (unless it's a very large prop that you don't want people going through). If you aren't sure, ask! And if no one is around to ask, it's probably best to make it. Remember, it's easier to remove clothes than to put them on (Oh yes, I'm very familiar with that).
As you can see, preparing your model to enter the world of Ura is quite simple and straightforward. If you have any questions, send them to denreaper@trinityreign.com or contact denreaper on IRC. Good luck!
