I've got this idea working.
Spoiler Alert, click show to read:
The only problem I have is if Bern is controlled by rebels, it causes a CTD. How can I make the script not run if the settlement is rebel owned?
I've got this idea working.
Spoiler Alert, click show to read:
The only problem I have is if Bern is controlled by rebels, it causes a CTD. How can I make the script not run if the settlement is rebel owned?
to check if the rebels do not own the settlement you need to use a condition I_settlementOwner
"not I_SettlementOwner = slave".
Last edited by J@mes; August 08, 2008 at 05:25 PM.
OK, thanks for the help J@mes. This is progress, the CTD is no more. However the rebel general doesn't attack now, whether Bern is slave owned or owned by a faction.
23:45:19.549 [game.script] [error] Script execution error for <siege_settlement>, at line 297, in mods/expanded_americas/data/world/maps/campaign/imperial_campaign/campaign_script.txt:
Attacker <Leopold> cannot siege settlemnt <Bern>.
23:45:19.549 [game.script] [error] Script execution error for <siege_settlement>, at line 298, in mods/expanded_americas/data/world/maps/campaign/imperial_campaign/campaign_script.txt:
Attacker <Leopold> cannot siege settlemnt <Bern>.
you have spawned a character called Skaris in the above script but your log says: Attacker <Leopold> cannot siege settlemnt <Bern>., is this a different script?
No sorry to confuse, I've just added the name Leopold to the slave section in the name.txt
Here is the full script.
Spoiler Alert, click show to read:
Without the monitor the rebel army spawns, besieges and attacks bern, no errors at all (provided bern is owned by a faction other than slave). However without the monitor if the settlement is already slave owned the army spawns besieges and attacks and then CTD's as it starts to zoom in. Presumably because a faction cannot attack itself...
How is the rebel army spawning without the monitor?? Or did you mean without the I_SettlementOwner condition?Without the monitor the rebel army spawns
I where starting to wonder the army would not spawn with the settlement not being slave so attacking its own faction should not be a problem here. (correct me if i'm wrong its 12.41am here)
OK guys, sorry to waste time, but changing the name back from Leopold to Skaris allows the little blighter to attack again, (don't know why) just gonna check it as bern slave owned...
OK, success! With Bern slave owned, I still get the event but no army spawns. Which at this time of night will do nicely for me!! Thanks for your help!!
+rep
Last edited by Amroth; August 09, 2008 at 10:51 AM. Reason: dp