I've been asked to make a small tutorial about making a new uniform, so here you go:
A uniform has several textures, one for the shop item and a few for the actual model skin, male, female and so forth.
The shop item textures can be found in the BMP\Items\ folder while the model textures are in the Media\actors folder, probably inside the Pack0.azp archive.
We'll start by creating the shop item and add it to the game. You need to add the uniform to several files in the INI\ folder:
\INI\economy.ini
Item "My New Uniform" 1000.0
\Ini\Items\ITEMINFO
ITEM "My New Uniform" //this is the name the engine uses to keep track of the item
RealName "Uniform" // this entry is what you'll see in the shop
Add your description here
END
\Ini\Items\ITEMLEVELS.INI
"My New Uniform"0 0 // the first number is the CGL and the second is the %chance of the item turning up in the shops.
\Ini\Items\ITEMS
"My New Uniform"
UniformItem
None "Items\carabineeruniform.act""carabinersol.e6b " //these entries calls the pic and model for the shop item
Uniform
Stalker //Loyalty(can be Algeira, Guerillas, Palinero or something you make up yourself, like I did with the Stalker faction)
Stalker //Type (can be Guards, Police, Soldiers and so forth. I made a new type called Stalker)
Soldier //Rank (What epaulets will ne used, if any.)
2600 //Weight
\Ini\Items\ITEMSROTATION
"My New Uniform"
X 0
Y 0
Z 0
\ShopINI\LasVacasionesNonLegalTraderShop.INI //this is the trader in Puerto Viejo.
Item "My New Uniform"
Level 1
Price 5000.0
We now have a new uniform in the game that can be bought at the trader that you added it to in the shopINI file. The character still don't change the model when the uniform is put on, so that's what we'll be fixing next. We need a 3d model that uses the uniform that you plan to change and use, the 236_carabineer_01.azp will be the one we're using today.
These are the packs for that model, the first is the pointer file while the second the male and the third the female. Since this model wears gloves there's only one model for the male, others might use two, one white and one black.
\Actors\Monsters\236_carabineer_01.azp
\Actors\Monsters\236_carabineer_01_body.azp
\Actors\Monsters\236_carabiner_bodyW.azp
Start by renaming them, something like this:
New_Uniform_01.azp
New_Uniform_01_body.azp
New_Uniform_bodyW.azp
Then open up the New_Uniform_01.azp and change the pointer in the ACTOR.ACT.DESCR to this:
COPYFROM Body New_Uniform_01_body
COPYFROM Head 236_carabineer_Head //this wont be used unless you change some entries in the EQUIPMENT.INI which I wont do for this exercise
END
Now it's time to find the skins for these models, they are located in the \media\Actors\ folder and the exact name can be found in one of the ACT files inside the New_Uniform_01_body.azp and New_Uniform_bodyW.azp archives. There are several ACT files that calls different parts of that model, and we're looking for the one that is the body textures. in this case they're called 236_bodyblack_s.tga and 236_bodyblack_s_W .tga and can be found in the \Media\Actors\ folder inside the Pack0.azp archive. But we need to rename them so that only the textures for this uniform is changed when wearing it, not the original carabineer textures. To do this you need a hex or binary editor since the ACT files are in a binary format. I use Binedit which is a free prog that makes it very easy for you. There is one thing that is important to keep in mind, the number of letters in the new texture file name must be the same as in the original.
236_bodyblack_s.tga -> 400_bodyblack_s.dds
236_bodyblack_s_W .tga -> 400_bodyblack_s_W .dds
You need to change the ACT file as well as the LOD1 and LOD2 files, those LOD files are for viewing the model from a distance and if you don't change them as well the model will still be using the original textures.
Notice that I changed the file ending from TGA to DDS. The TGA's are actually renamed DDS files and some texture progs will have a problem if they're not changed back to DDS format and the mipmaps might be lost if you continue to use the TGA format.
You can now edit the 400_bodyblack_s.dds and 400_bodyblack_s_W .dds to your liking.
The final step is adding the new uniform to the soldier list so that the game engine changes the model when the uniform is worn. This is done in the \ini\SOLDIERS file.
Combatant Stalker //Remember this from the ITEMS file?
Army Stalker // also connected to the ITEMS file
New_Uniform_01 White Man
New_Uniform_01_body White_Sebastian Man
New_Uniform_bodyW White Woman
New_Uniform_01 Nigga Man
New_Uniform_01 BigNigga Man
Then we have the Epaulets which is controlled by the \ini\SOLDIEREPAULETS file
Combatant Stalker
Army Stalker Stripe "Media\Actors\nashivka_s.tga"
0 Soldier Epaulet "Media\Actors\epaulet_r_01.tga"
You can make new Epaulets if you wanna, just make some new ones and point at them from this file.
Place all the new files in your game directory and see if it works by buying it at the trader in Puerto Viejo
Good luck
R@S
Edit: I forgot about the shop model and textures, The ITEMS file points to them so they're easy to find. It's the same procedure with the ACT file as I showed above, but this time they should be in the TGA format
Last edited by R@S; 05-16-2010 at 11:53 AM.
|