July 21, 2009 - 22:24
How to Setup Your Vehicle Models for Generals

Preliminary Steps
This tutorial is not about how to model or texture or anything, but rather how you should set up your model for the game.  Before you can get your tank or airplane or whatever in Generals, you first have to get the model into proper format.  There are a first steps, but before this you have to have the right tools.  The tool that supports the file formats used by Generals is the Gmax modeling program with the RenX plugin.  Assuming you have and installed both of these, we can proceed.

Preliminary Step 1: Setting up the model
Generals has a relatively low poly count range for models, and to quote a man quoting a man;

Infantry 100/400
Vehicles 500/900
Base defense 600/1500
Structures 1000/2000
Super Weapons 1500/3000

*DaFool’s Tip* Make your models as efficient as possible, aka using the least amount of polygons as you can.  Delete faces that are hidden inside of your model, and if you find that there are flat areas that are unnecessarily cut up into more faces than it should, fix it!  Also pay attention to faces you make that are not squares or rectangles.  I once saw a model that had a pentagonal face that was divided up into 5 triangles.  There was a point in the middle and an edge coming from the 5 points.  The most efficient way of divvying up a pentagon is to take one of the points on the shape and make 2 edges to the other 2 points it is not connected to, thus making the shape with 3 triangles.  All that to save 2 faces, well, I get into it.

So you should strive to have your models within these limits, or if you may, ‘recommendations‘.  Models with smaller polycounts will work better in the game, especially when larger armies of them are built.  Then you should consider your model as a whole.  Each part that moves together should be part of the same object.  Take your general vehicle, say a tank, you have the treads, the chassis, and the turret.  It works much the same way in Generals.  Your treads or wheels should be their own object, anything with the chassis or body should be one object, and the turret.  The barrel should also be it’s own object.  Too add a little foresight for you, anything that is remapable (or housecolor as you will call it when you become more of a Gen modder than a TS/RA2 modder Wink if your are neither yet, this means it changes color to the player‘s color ingame) is going to be it’s own object.  However, you should note that you should have a separate remap object for every moving part that the house color is on.  For example; the remap that moves with the chassis should be a different object than the remap that moves with the turret or barrel.

*DaFool’s Tip* Sometimes when you make a model you want a certain face on the model to be remapable.  Rather than make a plate to go over the face, I simply copy the whole model and move it directly above the original.  I then delete the face that is to be remapable on the original model, and everything else but the remapable face on the new model.  Then you just slide the remapable face into the hole, and everything should be perfect!

Preliminary Step 2: Get it into RenX.

You’ll either have to import it or if you made the model in RenX, you’re all set.  Generals wants the model in a particular way, as is:  The model should be centered and standing on top of the origin, facing the right hand side.

Real Deal Step 1:  Right Size.

An important thing is scale, so you have two options.  One is trust me when I say that a tank is has an average length of about 30 units in RenX or you can import a model and scale yours accordingly.  It will be best you don’t trust me (Wink), and to do this you will have to extract a model from the game and import it into RenX using a script.  Then you can simply scale your model to your pleasure.

Real Deal Step 2:  You Name it!

For the game to recongize the parts, they have to be names properly.  You should (or I don’t know if this is totally correct, but just do as I say Wink ) use capitol letters and if there are several instances of the object type (say wheels) they should end in numbers 01 and up.  So here are some names that I use a lot:

CHASSIS…the chassis or main body of the vehicles
TURRET…the turret
BARREL….the barrel
HOUSECOLOR…the remapable part

Step 3:  Hierarchy
The models work in a way that one or more parts are ‘attached’ to another.  For example, the barrel is attached to the turret, and the turret is attached to the chassis, and that’s the way it goes.  So next to the move button you’ll see a picture of a cursor over some lines.  Click on that and click the option to ‘display subtree’.  This shows you which objects are currently attached to which.  Now select an object which will be dependant on the movement of the other, say the barrel.  On the same line as select by name, on the far left side you will see an icon with two squares and a red chain.  That’s the Link button, and it’s your friend.  Click on it, and pull the select by name menu back up.  Click on the object which the object you selected before is dependant on.  The two should now be attached.  Rinse and repeat until everything is attached.  Usually everything under the chassis.

Step 4:  Rotation
In order for your model to rotate properly, or your turret rather, you need to do a few things so the game knows how to rotate it.  Select your entire model and then select the hierarchy tab on the right hand side.  Then ‘Affect Pivot Only’ followed by the button below that; ‘Align to World’.  Next, just select the turret, and you will need to move the axis to the spot on which you want the turret to turn. When your done with that, deselect ‘Affect Pivot Only’, and you’re done.

*DaFools Tip* You could really do this step at anytime during the process, but I like to do this step after I have the hierarchy done, because I can then test the pivot.  By rotating the turret, I can see how it, and any objects attached to it, look when it rotates.

Step 5:  Giving it Some Backbone
There are all kinds of little animations and details that Generals allows you to have by adding bones, which are basically just coordinates for the game to play an animation at.  Bones are just small little objects that you place in various locations on your model.  It is important however that they are not seen ingame.  To do this, click on the Utlilities tab on the right hand side (the hammer) and then click on ‘W3D Tools’.  When you select your bone, you can see some options below.  Make sure you deselect ‘Export Geometry’ on all your bones, as this make it so they are not seen ingame.  You will also have to add them to the hierarchy, as discussed step 3.

Step 6: Export
Once your model is all set, you can export it by File\Export…. And then make sure you export it as a .w3d.  Click ok, and then a small menu will pop up with some options.  Choose the one that bests fits what you’ve just made, and in our case, a Hierarchal Model.  Once RenX is done exporting, you can move the model into your Generals Directory under Art\W3D and your model is all set for use ingame (And textures go in Art\Textures)!

I know that this is a lot of text above, but once you get used to it you will fly through it in no time....