Campaign Carry Over Troops

Modders can post their questions on scripting and more.

Moderators: Slitherine Core, BA Moderators

Post Reply
lpgamble
Administrative Corporal - SdKfz 232 8Rad
Administrative Corporal - SdKfz 232 8Rad
Posts: 167
Joined: Mon Jun 25, 2007 8:00 pm
Location: Houston. Tx

Campaign Carry Over Troops

Post by lpgamble »

I need to dig around in the scripts some more, but is carrying-over troops from one scenario to the next supported? It doesn't look like it is setup for that type of operation. Seems like a seperate csv file written at the end of the battle to record the troops and a load at the start of the next scenario would be cool.

Failing that could you total up the cost of the surviving troops, save it and load it up for the force selection in the next scenario?
pipfromslitherine
Site Admin
Site Admin
Posts: 9863
Joined: Wed Mar 23, 2005 10:35 pm

Post by pipfromslitherine »

The game currently doesn't have support for this built in. However (and I must stress this isn't something we have tested) you could use the campaign variables to try and carry across data about surviving units.

To use campaign variables, you need to set them up at the top of your campaign.txt file in the form

VAR <name>

e.g.

VAR carryover1
VAR carryover2

You can have up to 64 campaign variables. You can then access them from within scripts using the GetCampaignVar and SetCampaignVar commands. All campaign variables are basically an 8 entry array, so you actually get 512 variables to play with.

We are tinkering with having proper carryover support, but it won't be in the short term for sure.

Cheers

Pip
Post Reply

Return to “Battle Academy : Modders Corner ”