PDA

View Full Version : Is it possible to mod in settlement specific units?



Zaleukos
12-07-2007, 13:14
I thought about making certain mercenary units recruitable from the city/castle walls in their "home" regions. For instance Galloglaich in Scotland/Ireland, Flemish pikemen in Antwerp/Brussels, etc. Ideally this should tap the mercenary pool for that region (sort of giving the owner of the province a first go at recruiting the local mercs), but that is secondary.

My main problem is that I dont know how to limit recruitment to a particular settlement. For the purpose of testing I have a savegame with the scots in control of Edinburgh (wooden_wall) and York (wooden_pallisade) and try to mod in Irish Kerns (the choice of unit will be obvious).

First I added scotland as owners in export_descr_unit.txt

Editing export_descr_buildings.txt by adding recruit_pool "Irish Kerns Mercs" 1 0.2 2 0 under the wooden_wall section obvious lets any country recruit these from a large town anywhere. Adding requires factions { scotland, } makes them exclusively scottish, but available anywhere on the map.

Then U tried to set the numbers to [i]1 0.2 0.9 0 to test if the local mercenary pool would spill over into the town (it does for replenishment of non-crusader units). No luck there.

So is there any known way to make the local mercenary pool recruitable inside a particular building (this would save me some regionalisation work), or to simply add a location requirement to the recruit_pool line?

Zaleukos
12-07-2007, 18:57
A few hours of searching (damn my slow connection) directed me to the use of hidden resources and the world\maps\base\descr_regions.txt file.

I added resources for the relevant provinces (a hidden resource called skottland) and appending the hidden resources list in export_descr_buildings.txt, and also added "requires hidden_resource skottland" to the recruitment pool requirements for my mercenaries. It doesnt work yet, so I must have missed something.

Zaleukos
12-07-2007, 19:54
Deleting the world\maps\base\map.rwm (recompiled upon restart) seems to do the trick, at least for restarted campaigns. I guess that the map file is saved together with the savegame and that is the reason that the addition of new hidden resources wont show in the save game.

Hellenic_Hoplite
12-07-2007, 21:28
Deleting the world\maps\base\map.rwm (recompiled upon restart) seems to do the trick, at least for restarted campaigns. I guess that the map file is saved together with the savegame and that is the reason that the addition of new hidden resources wont show in the save game.

I had a big problem with that file too a while back, just remember to always delete it whenever you create a new resource.

blacksnail
12-10-2007, 20:34
Check out Europa Barbarorum (https://forums.totalwar.org/vb/forumdisplay.php?f=70) for RTW. We use province-specific recruitment exclusively. We have a system of HRs that uniquely identify all 199 regions. If you're interested I'll see if I can dig up a map.

Zaleukos
12-11-2007, 11:00
Thanks for the tip, but I think I've achieved the desired effects now:) I've added regional mercs to the city/castle buildings and made various elite units rarer outside the factions heartlands. Havent had the time to see how it affects the AI, but I can hardly imagine that it will come up with worse stacks than in the past, and I am also a fairly casual campaign player.

In all I found this an extremely easy thing to mod compared to some other aspects, the data isnt spread out across a lot of files. Compared to the fuss of giving the scots archer militia or changing the names it's a piece of cake.

Out of "academic" interest, does RTW allow a higher number of hidden resources (than the 64 of MTW2) or did you use a combination of multiple resources to identify each region? :)

Zaleukos
12-11-2007, 11:17
I'm thick, didnt realise that EB2 were for MTW2 right away:)

blacksnail
12-11-2007, 19:01
No worries, we're still in the buildup. EB1 is for RTW, EB2 is for M2TW.

RTW had 64 as well. We used a combination - arbitrarily splitting the map into three overall sections (using 3 HRs), then splitting each section into 5 subsections (using 5 HRs), then each subsection in to 16 regions (using 8 HRs - 4 binary "yes" and 4 binary "no"). You'd end up with "EA C y8 n4 y2 y1" which meant "Eastern section, subsection C, region 11." We weren't using many HRs at the time so we could afford to use 16 in this fashion. This meant there would be 6 HRs in each region no matter what, but there wasn't a restriction so we were good to go.

Hellenic_Hoplite
12-11-2007, 20:12
Thanks for the tip, but I think I've achieved the desired effects now:) I've added regional mercs to the city/castle buildings and made various elite units rarer outside the factions heartlands. Havent had the time to see how it affects the AI

don't worry when I did it they seemed to recruit regional units just like they would recruit normal units. although I did have the HRE spamming flemish pikemen, thats a pain to have to deal with :beam:

Zaleukos
12-14-2007, 10:11
For me the main pain would be Turks with Armenian cavalry:D

I'm more worried about them suffering from a lack of elite units once they expand outside of their heartlands.:p Now I've set the max unit pool for arbitrarily defined elite units to 1 outside a factions heartlands, but I havent playtested it much. But since the AI seems to max out recruitment on a per turn basis I'd guess this means that I'd run into low grade or mercenary armies outside of a factions heartlands, with the specific units being more of a spice.

blacksnail: I imagined such a system. I've just put a regional layer using the Swedish names of the general area (Italien, Flandern, etc, with about 15 general regions for the faction units and a few specific ones for the merceneries). I dont think I'm going to do anything as ambitious with minor tweaks that only are for my own enjoyment, as I want to spend more time playing the game than modding it:)