Adding Leader Slots Work In Progress
This guide is a runthrough on the leaderpicker.gfx
file. This controls the leader selection menu and can be modified to reposition and modify the menu to look wildly different from what it normally does.
Quick Tip: You can edit most .gfx
files while Halo Wars Definitive Edition is open, and see those changes without reloading the game entirely. To do this, all you need to do is refresh the piece of UI that you are currently editing. To do this, simply exit the leader selection menu (if it is already opened), and then go back into it.
-
You will need a flash editor (https://github.com/jindrapetrik/jpexs-decompiler is the one this guide will use)
-
You will also need the
leaderpicker.gfx
file. For your convenience, a baseline one with 6 extra slots has been uploaded and will be used for this guide. (leaderpicker.zip) This file will need to be placed in the following directory within the mod folder: (art\ui\flash\pregame\leaderpicker\leaderpicker.gfx
) -
Open the
leaderpicker.gfx
file with the editor. In the top right of your tools at the top of the application, select Tag List (this will make it easier to follow the guide)
-
Click
frame 1
on the left side to expand the list of options within, then scroll down toPlaceObject (45) Depth: 80 (leader5INST)
-
Right-Click That
PlaceObject
, and clickclone
from the list of options. Right underPlaceObject (45) Depth: 80 (leader5INST)
, there should be aPlaceObject (45) Depth: 80 (leader5INST) [2]
-
Right-Click the new object and select
Raw edit
. At the bottom of this text, changeleader5INST
–>leader__INST
The underscores will be whatever number is next in the sequence of theleader_INST
series. For the file provided, 15 would be the next number. So, the new string will beleader15INST
-
After this is done, you should have a completely new leader slot in the
.gfx
file. To reposition this slot, expand thematrix: MATRIX
tab in theRaw edit
, and edit thetranslateX
&translateY
values to move the new slot around the UI.
- Last thing that will need to be edited is directly at the top of the list of options in
frame 1
. That is theDoAction ActionScript
source script. Click this tab, scroll down to line 114 and changewhile(i < 15)
towhile(i < 16)
. You should increase this by one for every additional leader slot you add.
If you’ve done everything correctly and remembered to save your changes, then you changes should now be visible ingame!