Log in

View Full Version : scripting campaigns from beginning



rorarii
10-01-2006, 11:47
Ok, I'm trying to run a script from the beginning of a campaign and attack a army (fight a tactical battle) then attack a city .. just to start with a little historical accuracy, but I'm having a few problems with a few script commands.

(1) I've tried ENGAGE_ARMIES <Character1>, <Character2> and got it to work ok BUT the command doesn't return to the script once complete, it must terminate_script or something. Anyway around that?

(2) Has anyone been able to create a battle through scripting, like in the Prologue campaign? I'm unable to get the game to move from the strategic map to the battle map? I think the basic code required is something like this but I'm missing something / everything?




spawn_battle campaign\battleDir\Battle_1
prepare_for_battle

while ! I_BattleStarted
end_while

while I_InBattle
end_while

end_battle

What's the minimum code required to start a tactical battle? I don't want to manipulate the battle too much, just return to the script after the battle is over..


any help thanks



R

Myrddraal
10-02-2006, 20:18
(1)

I can't remember the command exactly, but it's something like:

supsend_during_battle = true

Or something like that... You need to call it before the battle for the script to start up again afterwards.