WIZARD TUTORIAL - ASSET PACK
The asset pack wizard in the Mod Builder can be used to generate the appropriate file structure for a new Asset Pack. This guide will walk you through its usage. Also, don't forget to have a look at the paired Asset Pack Example.
Running The Wizard
- Launch the Mod Builder.
- Click File and select New.
- In the New Mod dialog, select AssetPack for Type and click OK.
- Click the … button beside the Mod File text box and select a location for your mod. You can save your mod anywhere, but it is recommended that you create a folder for it, e.g. C:\mods\my_asset\my_asset.mod.
- Enter in a Name and Description for your asset. This is the name and description that will show up in the Steam Workshop.
- If you have a preview image for your asset, click the … button beside the Preview Image text box and select it. It should be a TGA image with a resolution of 280x280. You can add this image later time if you do not have one.
- Click the … button beside the Art Path text box and select a location for your assets.
- Click OK to complete the wizard.
If you do not specify a full path for any paths other than the Mod File, the paths will implicitly be relative to your Mod File path.
Your completed wizard might look something like this:
Creating Assets
Creating Grass Assets
Grass assets are composed of a grass tuft TGA file, a blade file, and a grass file. To create a new grass asset:
- For each grass blade <name>:
- Create a 32 bit normal grass tuft TGA file named <name>_01.tga and save it to the location of the Burn Folder in data\art\sceanrios\grass\blades\texture.
- Create a 32 bit crushed grass tuft TGA file named <name>_crushed_01.tga and save it to the location of the Burn Folder in data\art\sceanrios\grass\blades\texture.
- Create a 32 bit burnt grass tuft TGA file named <name>_burnt_01.tga and save it to the location of the Burn Folder in data\art\sceanrios\grass\blades\texture.
- Create a blade file named <name>.bdf save it to the location of the Burn Folder in data\art\sceanrios\grass\blades.
- Create a grass file referencing each blade file and save it to the location of the Burn Folder in data\art\sceanrios\grass\types.
For example, if your normal TGA file was called my_grass_01.tga, your my_grass.bdf file might look like:
scale = 1
tint = { 255, 255, 255, 255 }
tint_variation = { 0, 0, 0, 0 }
And you my_grass.gdf file might look like:
scale = 1
blades =
{
{
blade_name = "my_grass",
mesh = 0,
blade_heights =
{
125,
150,
},
},
}
Using Grass Assets
- In the World Builder, enter the Grass Editor.
- Under Grass Types, click the + button and select your new grass type.
- Select your new grass type in the Grass Types list.
- Paint your grass on the terrain.
Creating Splat Assets
Splat assets are composed of alpha, diffuse, normal and specular TGA files, and a terrain material file. To create a new splat asset:
- Expand data\art\scenarios\textures\splats and double click your splats folder.
- In your splats folder, create a terrain material file called <name>.terrainmaterial.
- Next to your terrain material file, create an alpha TGA file called <name>_alp.tga. This is the grey-scale shape of your decal.
- Next to your terrain material file, create a diffuse TGA file called <name>_dif.tga. This is the color of your decal.
- Next to your terrain material file, create a normal TGA file called <name>_nrm.tga. If you do not wish to have a normal effect, fill this image with 127, 127, 255.
- Next to your terrain material file, create a specular TGA file called <name>_spc.tga. If you do not wish to have a specular effect, fill this image with 0, 0, 0.
For example, if your <name>.terrainmaterial file might look like:
material =
{
alp = "<name>_alp",
dif = "<name>_dif",
nrm = "<name>_nrm",
spc = "<name>_spc",
}
Using Splat Assets
- In the World Builder, enter Splat Placement.
- Under Textures, select your splat.
- Right click on the terrain to place your splat.
Creating Tile Assets
Tile assets are composed of diffuse, normal and specular TGA files, and a terrain material file. To create a new tile asset:
- Expand data\art\scenarios\textures\tiles and double click your tiles folder.
- In your tiles folder, create a terrain material file called <name>.terrainmaterial.
- Next to your terrain material file, create a diffuse TGA file called <name>_dif.tga. This is the color of your decal.
- Next to your terrain material file, create a normal TGA file called <name>_nrm.tga. If you do not wish to have a normal effect, fill this image with 127, 127, 255.
- Next to your terrain material file, create a specular TGA file called <name>_spc.tga. If you do not wish to have a specular effect, fill this image with 0, 0, 0.
For example, if your <name>.terrainmaterial file might look like:
material =
{
dif = "<name>_dif",
nrm = "<name>_nrm",
spc = "<name>_spc",
}
Creating FX Assets
FX are particle effects that can be placed in your scenario. To add FX to your asset pack:
- Right click on the data alias and select Add Burn FX…
- Select a folder for your FX (it is recommended that your create a new folder) and click OK.
- Double click your FX folder to launch the FX Editor.
- Create an FX in the FX editor and save it.
Using FX Assets
- In the World Builder, enter Render Marker Prox.
- Under Marker Mode, select Action Markers.
- Right click on the terrain to place an action marker, then select it.
- Click Edit Action.
- Using the New Commander combo box, select fx_attach.
- Click the … button next to the fx_attach\fx property and select your FX.
- Click Apply Changes.
Completing The Asset Pack
- If you wish to update the Steam Workshop name/description of your asset:
- Expand info then double click your asset's name. The Mod Info dialog should appear.
- Edit your asset's name or description.
- If you wish to add a Steam Workshop preview image for your asset:
- Right click on info and select Add Burn File…
- Browse to your preview image and select it. It should be a TGA image with a resolution of 280x280.
- Right click on your preview image and select Add Burn Settings then generic-image to data-rgt. This will compress the image decreasing the size of your mod.
Testing the Asset Pack
- Click Build then select Build.
- A dialog will appear informing you that the build is in progress, wait for it to complete.
- If the build is a success, your asset will be copied to your Documents\My Games\Company of Heroes 2\mods\assets folder.
- See using asset packs.
- If you are happy with your asset and wish to publish it to the Steam Workshop:
- Select the Modding HUB from the Company of Heroes 2 Main Menu.
- Select the Manage tab.
- Select your asset pack.
- Click Publish.