Quick mod question. How do I change the max # of units that can be recruit from a building? Thanks for any help.
Quick mod question. How do I change the max # of units that can be recruit from a building? Thanks for any help.
In your m2tw folder, you'll find the Data file -- if it is a mod you're playing, then go to the data folder for that mod (also in your m2tw more than likely). Okay so in "Data" you'll see a bunch of text files.. Find Desrc_export_buildings.txt. (it might be called export_desrc_buildings, or in a diff order than I said but thats the file). You may have to unpack your game files if you do not see it.
This file lists all the buildings, and the factions and culture that can build them, and then also if the building can recruit units or agents.
So it will be divided by building types, like .. from no walls to huge walls, then stables to kings stables etc... So you will look for the unit you want to adjust.
Lets say it is .. Pike Militia -- you will find in the 'militia barracks' tech tree that pike militia starts off at like the 3rd or 4th tech upgrae for that building. Among all the other units you'll see sometihng like this...
recruit_pool "Pike_Militia" 1 0.5 4 0 (milan, venice, papal_states, hre, france, spain, portugal) ...
The first number I don't know what it does, i never change it from whatever it is by default.. OKAy but the next 3 are important.
the " 0.5" means how fast the unit replenishes itself... the "4" means the Max Available (which is what you want) and the 0 at the end will be the experience of the unit... and in the brackets at the end is the factions available to recruit the unit (note, you cannot add another faction to recruit a unit here without going to the unit file as well, and a few other things to make sure it works properly).
You will see that with the majority of units, when they are first available it has a 0.3 (slow replenish), a max available of 2 , and no experience... but, when you get to the last tech upgrade in the building tree -- you will find that ordinary units have a 0.7 replenish, 6 max avail, and 2 experience.
Last thing, some units special are recruited in different places like Familgia ducale and forlorn hope - from a mayor's palace, or danish war clerics - from an abbey , or Order Knights from guilds, or plaza del torros and racing tracks get some cavalry -- so you may have to check the list bellow the main buildings if you're looking for something specific.
Wow, awesome explanation. Thanks so much.
Nice description Prestigealso I believe the first number represents how many units you can recruit initially once the building is complete. For most units it's 1, for Bodyguards it's 0.
To Mod Workshop>Text Editing and Scripting section.
Don't discuss modding in the general discussion forums.
Just to clarify the first 2 numbers if anyone is interested: The first 0 is how many units are ready to recruit upon construction of the building. And the 0.5 tells you that the building will allow recruitment of 1 unit every 2 turns, or essentially that it will gain 1/2 a unit per turn.
so to clearify:
recruit_pool "Pike_Militia" 1 0.5 4 0 (milan, venice, papal_states, hre, france, spain, portugal)
the 1 is how many units are availible at the start of the building complete
the 0.5 is how often the unit replenishes
the 4 is unit max availible
the 0 is the unit XP
correct?
We all die, its just a matter of how.... and when
-William Wallace
nvrmind, I was wrong
Last edited by Nosfearatu; February 13, 2011 at 10:36 AM. Reason: I was wrong, was thinking about ; stat_cost
Correct.![]()