View Full Version : Query - Getting the AI to balance guilds
HoreTore
02-01-2007, 18:20
How do you get the AI to get other guilds than thieves guild in cities?
I think I can count the number of times I've seen any other guild on one hand... Even Venice and milan has thieves guilds instead of merchants guilds in the italian cities. It's getting a bit dull...
So, does anyone have a way to encourage other guilds for the AI? Any files to change or something like that?
LordKhaine
02-01-2007, 18:54
I've seen them have other guilds many times, but they do tend to mainly have thieves guilds. I suspect this is due to the thieves guild being offered so much, and they accept the first guild offer they get. I know as a human player I get offered thieves guilds far more than any other.
I've gotten Sword Guilds in many castles... but yeah, first order of business in captured city: knock down the Thieve's Guild.
Well I just did a quick inspection of the export_descr_guilds.txt file to see what you could do about this... and I stumbled right into the reason it happens. Check out these two triggers:
;------------------------------------------
Trigger 0211_Spy_On_Settlement
WhenToTest CharacterTurnEnd
Condition EndedInSettlement
and not SettlementIsLocal
Guild thiefs_guild a 2
;------------------------------------------
Trigger 0212_Spy_Mission
WhenToTest SpyMission
Condition MissionSucceeded
Guild thiefs_guild a 10
0211 says that anytime a spy ends his turn in an enemy settlement (local would mean you own it, so not local is anyone elses), all settlements controlled by that spy's owner gain 2 points toward a thieves guild. 0212 says when a spy succeeds at a mission, all his owner's settlements get 10 thieves guild points.
0211 is a real killer, since all the computer factions spam spies so much there will always be tons in enemy settlements, probably generating 10-20 thieves guild points each turn at a minimum. Toning 0211 down to 1 point, or even removing its effect entirely, may be able to actually bring some balance to the guild recruitment (as I'm sure the computer just accepts whatever guild it is first offered).
I'm not sure if 0212 refers to missions given by someone to the player in the game, or just to spies completing an assignment you gave them. If it's the latter, that too would be a ridiculous source of thieves guild points to the computer. I've never seen a "spying mission" given from anyone in-game, so I'm speculating it is in fact every time a spy does anything successfully. If true, we'd also want to cut that back a lot probably.
HoreTore
02-01-2007, 19:56
Thanks a lot for the help so far :)
So far, 2 possible fixes:
1. find out how to make the ai refuse guilds. or thieves guild in particular. best fix, however, I've no clue how to do it.
2. Tone down those to triggers. I'll try that next time I start a campaign(currently playing russia and having too much fun holding the mongols out..). I'll probably try removing the first one completely, and tuning down the second to 1 or 2...
BTW, I'm 99% sure that "spyingmission" refers to spying on someone, as the other guild missions read "id_merchant_guild_mission" or something like that...
Be warned, the AI seems to re-order it's spys in a settelment to spy on that settelment again at the end of each turn so every spy in every settelment will get the bouns from the second trigger every turn, thats a big one.
HoreTore
02-01-2007, 21:35
Was hoping you'd drop by, Carl :)
hmm...How sure are you about that? If that's true, maybe leaving the first one and removing the second one will be better...
hmm...How sure are you about that? If that's true, maybe leaving the first one and removing the second one will be better...
I reguarly see AI spies stand up i cities they are allready in and then dissappear back into it. they don't leave they just re-enter it, bu my own only do that if I order them to.
Was hoping you'd drop by, Carl :)
This will make my ProblemFixer. Ill probably remove both as they easilly accumulate 10+ points a turn each even at 1 point a time.
HoreTore
02-01-2007, 22:28
I've changed the values in the second one down to 1, and left the first one as is. I'll start a new campaign now(as the Moors), and I'll be happy to give you the result in a couple of days if you wish, Carl.
YES PLEASE~;p.
Would be VERY useful to have this info TBH.
I reguarly see AI spies stand up i cities they are allready in and then dissappear back into it. they don't leave they just re-enter it, bu my own only do that if I order them to.
Hmm... I had assumed that it meant even more spies were piling into my cities, lol. Would've sworn the cities took a further PO drop too (which would mean another spy). Of course I typically have map movement accelerated, so I have no idea really if those spies were actually coming from somewhere else or were the ones already in the city.
I loften Spam Whatchtowers everywhere so no spy can approach my cities unseen, I often include my own spies in them too so they can't get near without being seen. i play at accellerated too, but you can't even get near my Borders without me knowing about it:smash:.
This is definitely a major problem for the AI. Re: spies, I got rid of the first trigger (211) ages ago, as it's definitely bad news. For the second I reduced the value from 10 to 5. This seems to be much better overall. Don't know how the AI will ever get the Alchemist guild though. By the time gunpowder comes around most cities/castles already have guilds.
If you use an AI money script at all, then get rid of the merchant treasury triggers too, otherwise all the AI will have is Merchant guilds. ;)
Praetorian308
02-02-2007, 01:45
Where is export_descr_guilds.txt located I can't find it in the program file anywhere.:help:
HoreTore
02-02-2007, 01:51
You'll have to download it from totalwar.com. To use an edited file, you'll have to put it in your data folder, and add --io.file_first to your shurtcut so it looks like this:
"whereveryouhaveyourgamedirectory\SEGA\Medieval II Total War\medieval2.exe" --io.file_first
TevashSzat
02-02-2007, 02:50
It would be nice to make the ai have a maximum percentage of its provinces have thieves guild so that they will accept enough offers to get the bonuses, but not have so many of them that they dont get anything else
Darth Venom
02-02-2007, 13:53
I reguarly see AI spies stand up i cities they are allready in and then dissappear back into it. they don't leave they just re-enter it, bu my own only do that if I order them to.
I think that's just spies being kicked out of your city at the end of your turn and then reentering it at the AI's turn. You should get a "spy found but escaped" message next turn.
zverzver
02-02-2007, 14:27
I think that's just spies being kicked out of your city at the end of your turn and then reentering it at the AI's turn. You should get a "spy found but escaped" message next turn.
I though it was exactly that. Spy rarely lives your city unless he is kicked out.
HoreTore
02-02-2007, 14:45
ok! been playing my moorish campaign now, and I've gotten to turn 35(it's hardly been any combat, so it's gone fast..). I have 3 cities capable of getting guilds. These are cordoba, lisbon and Marrakesh.
First off, Cordoba:
I used this city to train my spies and merchants, and enough of them to cover every city in spain, as well as toulouse. It was here I got my first guild offer, a thieves guild. Predictable enough, I had trained 8 spies here. I accepted this. However, it was much later than normal, I got the offer around turn 20-25.
The next city to get a guild, was Lisbon. It had no guild when I took it from the Portugese. However, they had probably used it to train spies, as it was their only city and had a brothel, so the first offer I got was from the thieves guild. I rejected this, and after I constructed a new market, I got a merchants guild.
Marrakesh wasn't offered a guild until after that however, and got the Theologians guild. It seems that I'm now only able to get thieves guild in the cities where I actually train spies, at least in the early game. Before, I would have been offered thieves guild in cities where I never train any spies, however that seems to have changed.
The only guild I know the AI has built, is a Thieves guild in Leon. That is appropraite however, the spaniards have spammed spies on me. I'll have to wait until I know what guilds have been built in other parts of the world, particularly france, germany and italy before drawing any conclusion however.
Other guilds that the AI always tends to build are swordsmiths for the Catholic factions (they tend to have all the 'sword' troops that count, plus they rely a lot on castles) and horse breeders for the Muslims (racetracks and they tend to be more urbanized). Every castle in France had a swordsmith in my last game.
HoreTore
02-02-2007, 15:50
Well, you don't really have much of a choice in castles, if you're not crusaderhappy, then all you can ever get is swordsmiths guild.
What I'd really like to see, is a good balance between assassins, thieves, merchants, theologians and perhaps horse breeders in cities.
Papal States tends to get Theologians Guild HQ all the time, or maybe Rome begins with one. Sometimes I do see Assassins Guilds in Muslim cities I capture.
Crusader chapters also make an occasional appearance; I captured one or two Templar Minor Houses and one HQ in the Balkans. Too bad Spain can't build anything from them.
LordKhaine
02-02-2007, 17:09
Hmm... I had assumed that it meant even more spies were piling into my cities, lol. Would've sworn the cities took a further PO drop too (which would mean another spy).
Well a spy re-entering probably gained a point of skill, so it would disrupt your city more. That and if autogoverned then it would auto adjust its taxes differently making the spys effects seem greater (since it hasn't had time to autoadjust taxes down to bring back order)
An important tip for spy defence is to scan diplomats and the like with your defensive spys. This quickly gains them 5-6 levels, the amount needed to really put a stop to enemy spy activity.
ok! been playing my moorish campaign now, and I've gotten to turn 35(it's hardly been any combat, so it's gone fast..). I have 3 cities capable of getting guilds. These are cordoba, lisbon and Marrakesh.
First off, Cordoba:
I used this city to train my spies and merchants, and enough of them to cover every city in spain, as well as toulouse. It was here I got my first guild offer, a thieves guild. Predictable enough, I had trained 8 spies here. I accepted this. However, it was much later than normal, I got the offer around turn 20-25.
The next city to get a guild, was Lisbon. It had no guild when I took it from the Portugese. However, they had probably used it to train spies, as it was their only city and had a brothel, so the first offer I got was from the thieves guild. I rejected this, and after I constructed a new market, I got a merchants guild.
Marrakesh wasn't offered a guild until after that however, and got the Theologians guild. It seems that I'm now only able to get thieves guild in the cities where I actually train spies, at least in the early game. Before, I would have been offered thieves guild in cities where I never train any spies, however that seems to have changed.
The only guild I know the AI has built, is a Thieves guild in Leon. That is appropraite however, the spaniards have spammed spies on me. I'll have to wait until I know what guilds have been built in other parts of the world, particularly france, germany and italy before drawing any conclusion however.
Sounds at least more promising than the original behavior the game had. It's pleasant to think that one of your cities actually got offered a guild other than a thief's guild as it's first offer!!! This only seemed to happen for me before if I absolutely avoided training or using any spies... which is of course just begging for pain on your front lines from all the enemy ones.
Well, you don't really have much of a choice in castles, if you're not crusaderhappy, then all you can ever get is swordsmiths guild.
Don't forget Woodman's Guild. Granted you have to work at it if you're not playing as England, but keeping a governor with more than 4 Chivalry in a castle gets that settlement 5 woodsman guild points each turn, so if you get good at gaining chivalry points, Woodman's Guild is easily attainable, just takes time for the governor to build up the points. The brothel building line get good Woodsman points too, and of course upgrading settlements does just like it does for every guild.
HoreTore
02-02-2007, 23:18
Yeah well, at least it seemed promising...
I've played a few turns more, and have seen three more guilds, in paris(french), dijon and marseille(both milanese), and they've all been thieves guilds...
As of now, it seems like it may take a bit more to make it balanced. But there's impossible to draw any conclusion, I haven't seen more than 6 enemy cities( of which 4 had the thieves guild, the other two had none, but were both small/early).
However, one thing that might make matters brighter, is that when Algiers and Zaragoza got stone walls, Zaragoza got offered merchants guild, which I accepted, while Algiers got offered Theologians guild first, then thieves and then finally merchants guild that I accepted.
None of those cities had produced any spies, neither by me or the AI.
However, if thieves guild still is the dominant guild, I might have another solution:
We all know that the AI uses a lot of spies, and as we kill a lot of them too, they must be producing them rapidly, and that means that they cannot be centralising their production. So, they're producing a lot of them in every province. As the player, you produce them in a select few provinces, so capping the global triggers stops you getting offered thieves guild in every province. This might not work on the AI, as they produce from every province, thus getting enough points from settlements specific triggers. If the global change doesn't work, I'll try halving the trigger on training spies(from 10 to 5).
vBulletin® v3.7.1, Copyright ©2000-2025, Jelsoft Enterprises Ltd.