Try to copy the code from Warband. The only problem is that allow you only to choose faction and troop type, but not troop tier: you have to change every time with python. A menu like the good old custom battle mod of Vanilla should be better.
Edit mode is for editing the physical properties of the scene, including the entry points from which troops will spawn. You cannot spawn agents in edit mode unless you code in a mission_template trigger to do so. As for your original question, download the Module System and go into module_game_menus.py and look for custom_battle_2.
The first block of code you'll see resets the player's stats between each battle. The code after (set_visitor, 0, "$g_player_troop"), has to do with equipping the player. This is followed by the list of other troops to spawn - for example (set_visitors, 1, "trp_farmer", 13). The 1 is the entry point - you can see where this is in edit mode. The trp_farmer represents the troop which will spawn there - go in module_troops to see the entire list. The 13 represents the number of troops to spawn there.
vota dc said:
Try to copy the code from Warband. The only problem is that allow you only to choose faction and troop type, but not troop tier: you have to change every time with python. A menu like the good old custom battle mod of Vanilla should be better.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.