Creating Giant Units Mods with SLX Studio and AGE

Here’s a mod I created that makes Berber Bombard Cannons 4 times larger than regular Bombard Cannons:

Because I wanted this custom unit to be unique only to the Berbers, I created new SMX files and units. To do this, I used the following software:

  • Advanced Genie Editor (comes with AoE2:DE)
  • SLX Studio

Part 1: SLX Studio
The Bombard Cannon and its projectile have 14 SMX graphics files that make up their animations. They are:

  • p_ball_shadow_x1 and p_ball_shadow_x2
  • p_ball_x1 and p_ball_x2
  • u_sie_bombard_cannon_attackA_x1 and u_sie_bombard_cannon_attackA_x2
  • u_sie_bombard_cannon_deathA_x1 and u_sie_bombard_cannon_deathA_x2
  • u_sie_bombard_cannon_decayA_x1 and u_sie_bombard_cannon_decayA_x2
  • u_sie_bombard_cannon_idleA_x1 and u_sie_bombard_cannon_idleA_x2
  • u_sie_bombard_cannon_walkA_x1 and u_sie_bombard_cannon_walkA_x2

The X1 and X2 suffixes refer to regular graphics and UHD graphics respectively.

Copy these 14 SMX files from resources\_common\drs\graphics to your work folder. Open SLX Studio, go to Graphics → Batch Extract SMX to SLX. Using the dialog box that appears, browse to the work folder where these 14 SMX files are located. From these SMX files, SLX Studio will create 14 subfolders, each of them containing an SLX file and bitmaps of the SMX’s animation frames.

Open the SLX file with SLX Studio. This will load all the animation frames into the software. To resize all the images, go to Tools → Resize Graphic Scale. Type “400” in the Resize Scale box and then clicked the “Apply To All” button. After that, go to Graphics → Batch Convert to SMX or SMP → SMX Format (Compressed) and select the folder where you want to save your SMX file. If your SMX has a lot of images this conversion might take a while; I think it took about an hour to convert the 14 SLX files. Once you save your SMX file, rename the SMX file to whatever. Here’s how I named the SMX files for the Big Bombard Cannon:

SMX

Alternatively, you can use an image viewer such as IrfanView to batch resize the frames. For some weird reason, using an external program to resize the frames reduces SMX file sizes. After resizing your BMPs, overwrite the original BMPs with the new BMPs. Now reopen SLX Studio

Because the frames were resized outside of SLX Studio, you will need to correct the anchor points i.e. the point where the selection ring is anchored to. To do that, go to Edit → Modify Selected Anchor by Amount. In the Modify Anchors window, switch operators to the multiplication symbol and set By Amounts to 4 for both X and Y. Finally, click Apply To All to apply new anchor points.

In addition to SMX files, some units also use particle effects. Particle effects are .json files located inside resources\_common\particles. For the Bombard Cannon, the particle effects it uses are the following:

  • impact_dust
  • Impact_water
  • smoke_hit
  • smoke_trail

Copy and rename these 4 .json files (for my mod, I just added “_big_bombard” to the the names). Inside each particle file, multiply the scale value by 4.

Now that you’ve resized your graphics, move all of your modified SMX and .json files into your mod folder. The SMX files will go inside resources\_common\drs\graphics while the particle files will go inside resources\_common\particles.

Now let’s get the graphics into the game with the Advanced Genie Editor.

Part 2: Graphics and Terrain Table
After copying empires2_x2_p1.dat to your mod folder, open that file with AGE and go the Graphics tab. For the Bombard Cannon unit, its graphics entries in the Advanced Genie Editor are:

  • BombardCannon (Attack) (654)
  • BombardCannon (Death) (657)
  • BombardCannon (Idle) (660)
  • BombardCannon (Decay) (661)
  • BombardCannon (Walk) (664).
  • Projectile Ball (3382)
  • Projectile Ball (Shadow) (3383)
  • Smoke Trail (1711)
  • Impact Building (1744)
  • Impact Ground (4203)
  • Impact Water Large (5507)

For these 11 graphics entries, copy and paste them as new graphics entries and rename them (for my mod, I just added the word “Big” to the name). For the BombardCannon and Projectile Ball entries, change the SLP names to match the modded SMX file. For example, for BigBombardCannon (Attack), you would change the name from u_sie_bombard_cannon_attackA_x1 to u_big_sie_bombard_cannon_attackA_x1. The game will automatically handle the X2 stuff.

The Smoke Trail and Impact entries use particle effects instead of SMX files. For these entries, you need to change Particle Effect Name as opposed to SLP Name.

The Definitive Edition does not use DRS files, so the SLP number does not matter.

We now need the terrain impact graphics (Impact Ground Big Bombard, Impact Water Big Bombard) to appear when the Big Bombard Cannon’s projectile hits the ground/water. To do that, go to the Terrain Tables table, copy table 12 (All -bridge, ground impact) and paste it as a new table. Now, you will need to go through each terrain and change the Enter Tile Graphic entry to either Impact Ground Big Bombard or Impact Water Big Bombard. This will be a tedious process, but the copy and paste buttons can speed things up. Note that this new table will just be named “Table” and that you’ll be unable to rename this table. You don’t need to worry about that.

Part 3: Units
With graphics and terrain tables entries set, we can now switch to the Units tab.

First, make sure the “Including graphics” option is checked. Then, copy the Bombard Cannon (36), Projectile Bombard Cannon (368), BCANN_D (16) and Trail Smoke (247) unit entries and paste them into new unit entries (I pasted those four entries at 1786, 1787, 1788, 1789 respectively). To make tracking units easier, change the Language File Name for the units to an unused name such as 0 or 7000 and give them a custom name. For my mod, I renamed 1786, 1787, 1788 and 1789 to BIG BOMBARD CANNON, Projectile Big Ball, Big BCANN_D and Trail Smoke Big respectively. Make the Big Bombard trainable at the Siege Workshop by setting Train Location to Siege Workshop (49) and Train Button to 4 and edit its stats while you’re at it.

Now let’s link the units to the graphics entry. For BIG BOMBARD CANNON, change Standing Graphics to BigBombardCannon (Idle), Dying and Undead Graphics to BigBombardCannon (Death), Walking and Running Graphics to BigBombardCannon (Walk), Attack Graphic to BigBombardCannon (Attack), Projectile Unit to Projectile Big Ball and Dead Unit to Big BCANN_D.

For Projectile Big Ball, change Standing Graphics + Walking and Running Graphics to Projectile Big Ball, Dying and Undead Graphics to Impact Big Bombard, Terrain Table to 32 and Trailing Unit to Trail Smoke Big. For Big BCANN_D, change Standing Graphics to BigBombardCannon (Decay). For Trail Smoke Big, change Standing Graphics + Dying and Undead Graphics to Smoke Trail Big Bombard. Here’s a table summarizing what I’ve said:

Finally, let’s make the Big Bombard Cannon available to the Berbers. To do that, create an effect command that upgrades Bombard Cannons to the Big Bombard Cannon (Upgrade Unit is command type 3). Then create a Tech that sets the effect to that Big Bombard effect you just created and the civilization to Berbers. From here, your Big Bombard Cannon mod will now be available in game. Unlike UI mods, graphics mods can be combined with a data mod.

If the unit’s custom graphics aren’t showing up, go back to the unit entry, uncheck Automatically, click the Copy button next to Including graphics and recheck the Automatically button. Special thanks to PsychoticSock on the SLX Studio Discord for pointing out this graphics fix.

4 Likes

Hey, thanks for sharing this! I was wondering what steps would be different if you wanted to make a giant unit available to all civs, i.e. just a graphics mod and not a data mod? For my example, I want to make the militia unit 2.5x bigger so that I can have a “Giant” for use in the scenario editor.

To replace the sprites of existing units, you simply need to make the sure name of the SMX files in your mod folder is the same as the original SMX files. For example, to replace Militia graphics, your modified SMX files in the mod folder should be named:

  • u_inf_militia_attackA_x1 and u_inf_militia_attackA_x2
  • u_inf_militia_deathA_x1 and u_inf_militia_deathA_x2
  • u_inf_militia_decayA_x1 and u_inf_militia_decayA_x2
  • u_inf_militia_idleA_x1 and u_inf_militia_idleA_x2
  • u_inf_militia_idleB_x1 and u_inf_militia_idleB_x2
  • u_inf_militia_walkA_x1 and u_inf_militia_walkA_x2

Are you tired of your bombard cannon being the same size as everyone elses? Fear not… call our expert bombard cannon enlargers and your bombards can be up to 4 times larger than regular bombard cannons and give you 4 times the pleasure of using it!

1 Like

You can’t edit DLC campaigns with the scenario editor, as those files are encrypted. However, you can still play those campaigns with modded data files. That’s why I can play DLC campaigns with a giant Babur and Rajendra Chola:

Babur and Rajendra are both melee cavalry units, so I did not need to deal with projectile graphics. Nevertheless, resizing both units was still a bit tricky.

Babur by default uses the same sprites as the Imperial Camel. Because I also did not want have giant Imperial Camels, I had to create new SMX files specifically for Babur. Then there was the fact that the Imperial Camel graphics consisted of over 23,000 frames, given that Imperial Camel animations run at 60 frames per angle. Thus, when resizing the frames with Irfanview, I had to use the lower quality Hermite resampling method instead of the default Lanczos method. Even with Hermite resampling, though, the 12 new SMX file had a combined size of over 1.4 GB. This is why I have no plans on uploading this mod. It was a bit easier to resize Rajendra, given that Rajendra’s animations only run at 45 frames per angle. Even then, the 12 SMX files came out to be over 700 MB.

Once I created the SMX files, I now needed to resize the golden hero glow. Every hero cavalry unit’s Hero Glow Graphic entry is set to the HeroGlow Cavalry graphic. HeroGlow Cavalry in turn references the HeroGlow Medium graphic entry. Finally, HeroGlow Medium references the heroglow_medium particle effect. For this mod, I copied and pasted HeroGlow Cavalry and HeroGlow Medium into new graphic entries, naming them HeroGlow 4x med and HeroGlow 4x Cavalry respectively.

Inside heroglow_medium.json, I changed the scale from 0.25 to 1.00. For HeroGlow 4x Cavalry, I changed Offset Y from -25 to -100. Finally, I changed Babur’s and Rajendra’s Hero Glow Graphic to HeroGlow 4x Cavalry. With this, the hero glows around Babur and Rajendra were now properly placed.

While Babur and Rajendra are 4 times larger than their default versions, I decided that they should only move twice as fast and attack at half speed. To get this half-speed effect, I doubled the Anim Duration for all the graphics and doubled the Reload Time for each unit. For example, Rajendra’s attack animation by default lasts for 1.4 seconds, while his Reload Time is 2. Thus, to make Rajendra attack at half-speed, I increased his Anim Duration and Reload Time to 2.8 and 4 respectively.

how i can download the giant cannon?
PD: i dont understand nothing LOL

Hi, I was trying to load .SLP files from AOE1DE to convert them into SMX files for use in AOE2DE. However I get the below error message when using SLX Studio. What is the issue please? The Continue or Quit options both lead to the SLX studio hanging with no resolution. I am using the x64 version of the SLX Studio btw.

image