Can we script Rome siege?
I am trying to force HRE to siege Rome (a simulation of the sack of Rome):
Code:
if not I_IsFactionAIControlled papal_states and not I_SettlementOwner Roma = hre
spawn_army
faction hre
character random_name, general, age 23, x 212, y 181, label Rome_italy_invasion1
traits NaturalMilitarySkill 3
unit NE Bodyguard exp 2 armour 0 weapon_lvl 0
end
end_if
siege_settlement Rome_italy_invasion1, Roma, maintain
The unit is created next to Rome, but it doesn't siege the city for some reason...
Is Rome special or something? I am doing something wrong maybe?
Re: Can we script Rome siege?
What are the starting relations between papal states and HRE in your descr_strat ? Are they at war and with -1.0 faction standing ?
Re: Can we script Rome siege?
They might be indeed in good terms. In that case I wonder if there is a way to script hre declaring war on papal states?
Re: Can we script Rome siege?
Hmm... Checked yesterday and they have a -0.1 relation.
So it doesn't look different than when I use this on other factions.
Re: Can we script Rome siege?
-0.1 is almost nothing. Try -1.0 instead, they will really hate each other much more. In faction standings, also set them at_war already.
Re: Can we script Rome siege?
I assume they're not allies either then.
Quote:
I wonder if there is a way to script hre declaring war on papal states?
console_command diplomatic_stance hre papal_states war
But scripting them to lay siege to papal_states would already do that.
Are you sure the internal name is Roma? In vanilla it is Rome. I tried "Roma" at first and got a log error. (It worked after I fixed that, without needing to declare war first.)
If this is being done during turn end (your script doesn't show when it's being done) then maybe they do lay siege but break it off within hre's turn. If I was the AI then I wouldn't want to be maintaining a siege with just a general either.
You will need to move that siege_settlement into the if...end_if block above it, otherwise it will be trying to lay siege even if nobody was spawned. Not that this is your problem here.
Re: Can we script Rome siege?
Quote:
Originally Posted by
Withwnar
I assume they're not allies either then.
console_command diplomatic_stance hre papal_states war
But scripting them to lay siege to papal_states would already do that.
Are you sure the internal name is Roma? In vanilla it is Rome. I tried "Roma" at first and got a log error. (It worked after I fixed that, without needing to declare war first.)
If this is being done during turn end (your script doesn't show when it's being done) then maybe they do lay siege but break it off within hre's turn. If I was the AI then I wouldn't want to be maintaining a siege with just a general either.
You will need to move that siege_settlement into the if...end_if block above it, otherwise it will be trying to lay siege even if nobody was spawned. Not that this is your problem here.
You were right, they actually were breaking the siege because the army was obviously too weak to take Rome. I added a proper army with cannons and it fixed the issue.
Thanks for the diplomacy command by the way, I needed that for another script anyway :P.