How to: Reducing side file size (FAQ)
Posted: Sat Apr 14, 2007 3:55 pm
I notice a lot of maps with big huge 200mb sides with not much changed.
This should help you reduce that (if you understand it)
IF YOU'RE JUST EDITING SKINS (no ODFs)
You're going to make a 'skin side'. Make a new side and name it. In my example Im making 212nd legion skins, so ill call it "212nd". Then make a MSH and REQ folder in your side. In the msh folder, put all the skins you edited.
Next go to the REQ folder and make a new text file for each skin you edited. For example, if i edited the rep_inf_ep3trooper.tga i'd make a notepad file called "212_inf_ep3trooper" (it doesn't matter what you call it though). Now open up the newly made file, and add the below.
You might notice a skins req is different from a unit req
Another example is the clone sniper, which needs two parts in his req because he has 2 textures.
Do this for each skin you edited.
Next open up the SIDE req file, in my case its called 212nd.req.
In it, add the names of all your req files. My req would look like this-
Basically you've just made a 'skin' side. Lastly, to over-write the shipped skins just load your skins in your maps LUA, just like you would units. But make sure you load the skins after all the other sides, or nothing is changed.
This is what is in my LUA.
IF YOU'RE JUST EDITING ODFs
This was pointed out by another member. Basically you edit the shipped sides just as you normally would. After you do, add this line to any edited ODF under [GameObjectClass]
Just a note though, the edited ODFs name should be one other then the ClassParent = name. You can do this for weapons and vehicles too (unless i'm mistaken). Basically this gets rid of the need for msh's and tga's because the unit will get them from the class parent.
Then in your LUA load your side AND the side containing the Parent ODFs.
SO if i edited the jettrooper with this technique this is what LUA would look like.
A HINT on 1st person
In your custom sides you only need FPM of the weapons, unit and vehicle FPM is included the game data so you can delete it from your side.
This should help you reduce that (if you understand it)
IF YOU'RE JUST EDITING SKINS (no ODFs)
You're going to make a 'skin side'. Make a new side and name it. In my example Im making 212nd legion skins, so ill call it "212nd". Then make a MSH and REQ folder in your side. In the msh folder, put all the skins you edited.
Next go to the REQ folder and make a new text file for each skin you edited. For example, if i edited the rep_inf_ep3trooper.tga i'd make a notepad file called "212_inf_ep3trooper" (it doesn't matter what you call it though). Now open up the newly made file, and add the below.
Code: Select all
ucft
{
REQN
{
"texture"
"skin name.tga"
}
}Another example is the clone sniper, which needs two parts in his req because he has 2 textures.
Code: Select all
ucft
{
REQN
{
"texture"
"rep_inf_ep3sniper"
}
REQN
{
"texture"
"rep_inf_ep3sniper_cape"
}
}Next open up the SIDE req file, in my case its called 212nd.req.
In it, add the names of all your req files. My req would look like this-
Code: Select all
ucft
{
REQN
{
"lvl"
"212_inf_ep3armoredpilot"
"212_inf_ep3trooper"
"212_inf_ep3_jettrooper"
"212_inf_ep3_officer"
"212_inf_ep3_sniper"
}
}This is what is in my LUA.
Code: Select all
ReadDataFile("SIDE\\212nd.lvl",
"212_inf_ep3armoredpilot",
"212_inf_ep3_sniper",
"212_inf_ep3_officer",
"212_inf_ep3_jettrooper",
"212_inf_ep3trooper")IF YOU'RE JUST EDITING ODFs
This was pointed out by another member. Basically you edit the shipped sides just as you normally would. After you do, add this line to any edited ODF under [GameObjectClass]
"name" being the original ODF. So if I edited the jet trooper ODF id putClassParent = "name"
Code: Select all
ClassParent = "rep_inf_ep3_jettrooper"Then in your LUA load your side AND the side containing the Parent ODFs.
SO if i edited the jettrooper with this technique this is what LUA would look like.
Code: Select all
ReadDataFile("SIDE\\REP.lvl",
"rep_inf_ep3_jettrooper")
ReadDataFile("dc:SIDE\\REP.lvl",
"new_inf_ep3_jettrooper")In your custom sides you only need FPM of the weapons, unit and vehicle FPM is included the game data so you can delete it from your side.
<---- Warrant officer badge