Hi,
this tutorial shall show you how to create new building models and how they're added to the game.
Requirements:
A 3d modelling software like Milkshape 3d
UU3D to convert the model
Adobe Photoshop, Gimp or something similar
And a DB editor
As example for this tutorial I'll create a part of a draft by Georg Ludwig Friedrich Laves for an academy witch I'll using for the enlightened university for Hannover.
Here are the ground plan and front plan (I mean the front and ground plan on the top):
Spoiler Alert, click show to read:
Part 1 - How to create the model Usually I start with a ground plan. I add the ground plan as a background image and scale it normally to 0.1:
Spoiler Alert, click show to read:
Now we have a ground plan, so we can add the basic geometric elements of the building:
Spoiler Alert, click show to read:
You can see that I already add a box on the top and as 2nd step I added a cylinder.
If you increase the number of slices the more round your cylinder will be.
Spoiler Alert, click show to read:
After this step I deleted everything I won't need.
Spoiler Alert, click show to read:
As next step I add the front plan as background image. This is a bit tricky because you need to find the right settings to fit your basic elements and the ground plan.
Spoiler Alert, click show to read:
Here I needed to move the front plan on the x-ace.
Note that you never need to move the background image on the y-axe. Just move your model up and down.
Next step is adjusting the heights of the vertice lines from the cylinder to the height of the elements shown in the front plan.
You can see the some lines are not at the height of some edges but we'll need them later.Spoiler Alert, click show to read:
The result is follwing:
Before working on them I'm creating the rectangular elements of the avant-corps.
For that I cloning the already existing boxes and scale them according to the front and ground plan.
To create the triangle I also clone a box and scale the box to the size of the future bottom line of the triangle. After this I'm selecting the upper front 2 vertices and snap them together. Than repeat the method with the back vertices.
Spoiler Alert, click show to read:
Hereafter I created the stairs. As you may have seen I'd already created a box in the position of the stairs. I selected the upper vertices and then moving to the position where the end upper end of the stairs are located on the ground plan.
Spoiler Alert, click show to read:
Of course the result aren't really stairs but campaign building models are that small that humans are not able to see single steps in-game.
Let's move on to the next step; creating the top ledge. For that I used the scale tool. When scaling parts I always use small number such as 0.98 or 1.01 as to avoid making to large steps. Also I recommend if you haven't a cube that you scale your element on x- and z-axe separately.
After that connecting everything witch is empty now with faces. Note that you turn right while creating faces unlike you it is your intention to create a surface witch will be visible from the opposite direction.Spoiler Alert, click show to read:
Spoiler Alert, click show to read:
Now I simply repeated the shown methods until the avant-corps is finished.
The next step is to adjust the higher parts of the cylinder:
It is a mixture of scaling things right and move the vertices on the right hight:
Spoiler Alert, click show to read:
After this step connect the vertices as to fill the gaps between the building parts.
At last I added the pillars. At first create an cylinder with just 1 stack.
Spoiler Alert, click show to read:
Then move the pillar to its right position on the ground plan.
Spoiler Alert, click show to read:
Clone the pillar and move the cloned ones to their right position and finally adjust the height of the vertices via: Vertex>Flatten>Z
Spoiler Alert, click show to read:
Now the model is done!
Part 2 - How create the texture At first create a plain texture with every part of the facade and the roof by using an image editing program.
Spoiler Alert, click show to read:
Now open your model press right on the 3D preview and select "textured" as to be able to see your following changes.
After this you need to create a new material and assign all groups to this material. Important is that the name of the material is the same as the one of your texture file (see part 3 for the reason). Add the texture in the texture box:
Spoiler Alert, click show to read:
Then start with the real mapping. First select the parts of the model to which you to add the texture. A hint is that you hide to parts of the model you don't want to edit to make it easier to select the right faces.
Spoiler Alert, click show to read:
Press Ctrl+T to open the texture tool from Milkshape. Select with the "Region" the area where you want to add the texture coordinates. Then press "Remap". After this you can edit the coordinates with the "Select" and "Move" tools.
Spoiler Alert, click show to read:
When adding texture for a round part I orientated myself on the ground plan for the positions of the texture coordinates. The result will not be perfect but the player won't be able to see it in the game.
Spoiler Alert, click show to read:
Finally this is the result:
Spoiler Alert, click show to read:
Part 3 - How to scale the model The first step is here to merge our model with an already scaled building model (extract one of the models from the CA and convert it with this tool: into the .ms3d format).
Spoiler Alert, click show to read:
Then use the scale option until the building model fits on the ground square. Note that the final model is very small. Sometimes it helps to safe the model, close Milkshape and open it again to have a full view on your now smaller model.
Spoiler Alert, click show to read:
After this delete everything from the old model except the ground square.
Spoiler Alert, click show to read:
At last retexture the ground square. Now your model should look like this:
Spoiler Alert, click show to read:
Part 4 - How to convert the model For this step you need UU3D or someone who has this tool and is willing to help you (wangrin is helping me with this steps and I can not be thankful enough) You need to convert the model into the .rigid_model format. Doing this the material of the model absolutely need to have the same name as your texture file! In my case "hanover_diffuse".
Now you can add your model into a .pack file.
Part 5 - How to add the model to the db-tables
At 1st you go in the warscape_rigid_tables and create a new one. Copy a line from the vanilla (use one with this entry in the 2nd column: "RigidModels/CampaignBuildings/Textures" and this one in the 3rd: "campaign_building") one and just change the name from as example: "EU_town_education_lvl1" to "hanover_enlightened_university".
Spoiler Alert, click show to read:
2nd go to the warscape_rigid_lod_tables, create again a new table and then add generic key in the 1st column, the path where your model is located in the .pack files in the 2nd, "0" in the 3rd and in the 4th the name you used before, so "hanover_enlightened_university".
Spoiler Alert, click show to read:
At last you've to go to the "building_culuture_variants_table" or "building_fraction_variants_table" or "building_culuture_gov_type_variants_table", whereever your building is located and add there the name "hanover_enlightened_university" in the 3rd column for the "building_fraction_variants_table" or the 4th for the "building_culuture_variants_table" and "building_culuture_gov_type_variants_table".
Here is a pic of the model after I incorporated it into the game:
Spoiler Alert, click show to read:
At the end will thank wangrin for his help and support when I was new to modeling and the long night we tried to figure out how the texture worked!