Call to Arms - Gates of Hell: Ostfront

Call to Arms - Gates of Hell: Ostfront

Spawn Menu - Ultimate Edition
aeternitas  [developer] Aug 24 @ 6:57pm
2
Spawn Menu for custom missions
How to add spawn menu for custom missions:
1) Go to the root path of the game and find the mods folder there.
2) Find the templates folder, duplicate it, and rename it to the name of your mod (it is important to remember that you cannot use spaces, periods, or dashes in the name of the mod folder, otherwise the game will simply not see your modification. It is recommended to use a single word as the name, or use underscores instead of spaces).
3) Delete everything unnecessary from the newly created folder (files with the .pat extension and readme.txt).
4) Open mod.info with a text editor (I recommend Notepad++) and change the name of the mod to suit your needs.
5) Copy the map folder from the mod with the custom mission to the resource folder. If there are several missions and you want to add only one or not all of them, simply delete the folders with the missions that do not suit you.
6) In the mission folder, delete everything except the 0.mi and interface.set files.
7) Add the line
(include “/menu/init.mi”)
to 0.mi. Examples of how and where to add this line can be found in the spawn menu files.
8) This step will be a little more complicated than the previous one, but I hope you can handle it. Now we need to add mission options to interface.set. If the custom mission did not originally have an interface.set file, create it and write the following structure there:
{location {mission_options {checks {“spawnmenu” {options “with_spawnmenu”} {selected “”} } } } }
If the file already exists, you will have to act according to the circumstances. In general, I think it is easy to understand what to insert and where by simply looking at a couple of examples from the spawn menu files.

At this stage, everything should already be working if you haven't made any mistakes, but the game option menu that appears before the mission starts will look ugly. If you don't care about that, you can stop reading and enjoy the game.

9) Now we need to create localization files. The easiest way to do this is to copy the localization folder from the spawn menu. There you will find files with the .pot extension. Duplicate one of them, and then delete everything except the new file. The name of the new file doesn't really matter, but I recommend naming them in a special way so that the names don't conflict with the spawn menu files.
10) Now open your .pot file. In it, you will most likely see the localization already added for other missions. Our task now is to change this so that the localization works for custom missions. To do this, you need to insert the following code:
msgctxt “mission/single/your_custom_mission_folder_name/custom_mission_name/spawnmenu” msgid “” msgstr “Spawn Menu Parameters :” msgctxt “mission/single/your_custom_mission_folder_name/custom_mission_name/with_spawnmenu” msgid “” msgstr “Use Menu in this mission”
And so on for each individual mission. You can see examples in the same file, and after you finish, delete all previous entries that did not relate to your missions.

Now you can see your mod in the mod list. However, the order of activation is important. I recommend first activating the original mod for the custom mission, then activating the spawn menu, and finally activating the adapter you created to use the menu in the custom mission. Otherwise, if the loading order is violated, either the menu will not appear in the mission, or the game may crash altogether.
Last edited by aeternitas; Aug 24 @ 7:03pm