Market Garden carry over campaign mode

Modders can post their questions on scripting and more.

Moderators: Slitherine Core, BA Moderators

Post Reply
rf900
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 339
Joined: Fri May 04, 2012 6:59 am

Market Garden carry over campaign mode

Post by rf900 »

Hi, I have read that the Market Garden expansion has a mode for campaign in which you carry over units from mission to mission. IMO it is a very interesting mode, wished I had picked it up during the sale. My question is, ¿is this mode optional? ¿Would it be possible to include it in other campaigns only by modding?
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Re: Market Garden carry over campaign mode

Post by junk2drive »

I'm pretty sure that one of the updates put it in the editor.
You can call me junk - and type that with one hand.
IainMcNeil
Site Admin
Site Admin
Posts: 13558
Joined: Fri Apr 01, 2005 10:19 am

Re: Market Garden carry over campaign mode

Post by IainMcNeil »

Yes it can be added to anything but requires the campaign to be built with it in mind so would need a lot of changes to a standard campaign.
rf900
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 339
Joined: Fri May 04, 2012 6:59 am

Re: Market Garden carry over campaign mode

Post by rf900 »

I see it thanks
rf900
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 339
Joined: Fri May 04, 2012 6:59 am

Re: Market Garden carry over campaign mode

Post by rf900 »

I don't have the expansion, but what happens with reinforcements during scenarios? Do those stick up with your starting units to carry over to the next scenarios?
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Re: Market Garden carry over campaign mode

Post by junk2drive »

When you create the scenario you can designate units to be carryover units or just regular units. Only surviving carryover units will carryover to the next battle. Reinforcements cannot be carryover as far as I know.
You can call me junk - and type that with one hand.
pipfromslitherine
Site Admin
Site Admin
Posts: 9937
Joined: Wed Mar 23, 2005 10:35 pm

Re: Market Garden carry over campaign mode

Post by pipfromslitherine »

You can carry over reinforcements, you just need to add some scripting to do it. You need to set and attribute on the unit called System_Carryover to 1 and it should be carried over just like any units placed on the map.

Cheers

Pip
rf900
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 339
Joined: Fri May 04, 2012 6:59 am

Re: Market Garden carry over campaign mode

Post by rf900 »

Just purchased the Market Garden expansion, I am a bit confused on how the carryover is working. From the playing perspective is not very clear which units are carried over.

Looking at the scripts I see this code:

Code: Select all

count = GetCarryoverCount(1,0) ;    // mission 2(remember missions start at 0) side 0  
			for(i=0;i<count;i++)
				{
				// fetch and place the i'th unit from the carryover data
				id = AddCarryoverUnit(19+i, 18, 1,0,i ) ;
				}
I suppose is the only one that places the carryover units, but this appears only in Mission1b.BSF and Mission7.BSF. And from ingame texts it says some units will reappear in mission4 and another one that seems not to match the previous scripts numbers. Will check this better in another play through.

Anyway, am I missing something? Is there another way in which it recovers units from other missions? Are the promotions kept? Would it be possible to add visible icon to units that will be carried over to another scenario and another icon that denotes that a unit comes from a previous one?

I was expecting more of a story progression of units for this campaign, right now I am not able to tell the differences from one another.
pipfromslitherine
Site Admin
Site Admin
Posts: 9937
Joined: Wed Mar 23, 2005 10:35 pm

Re: Market Garden carry over campaign mode

Post by pipfromslitherine »

The scripting is for units which come on as reinforcements after being carried over from a prior mission. The editor allows for automated additions of any carryover units at the start of the mission.

Unit status (i.e. promotions) are carried over, as are unit strength. It's possible the script to carry over other attributes.

Cheers

Pip
rf900
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 339
Joined: Fri May 04, 2012 6:59 am

Re: Market Garden carry over campaign mode

Post by rf900 »

Thanks again, I saw yesterday the option to add them in the editor with more help, I think I got it now.
rf900
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 339
Joined: Fri May 04, 2012 6:59 am

Re: Market Garden carry over campaign mode

Post by rf900 »

I have finished the campaing and its good, but was expecting more progression for the units with the carryover system. My main problem was that I really didn't knew which units are carried over and taken to next missions as not all of them are.

I have added a (*) before the name of the units for the ones that are carried over to next missions. Not sure if it gives an unfair advantage, but I think it make sense to know which ones you will have at the end game.

Code: Select all

	StartString() ;
	
	if (GetAttrib(me, "System_Carryover") == 1 )
	{
	PrintStringLiteral("*") ;
	}
	
	PrintStringIndexed("IDS_UNITNAME", GetUnitStringID(me) ) ;
Attachments
UI.zip
Carryover units visible indicator
(2.2 KiB) Downloaded 129 times
rf900
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 339
Joined: Fri May 04, 2012 6:59 am

Re: Market Garden carry over campaign mode

Post by rf900 »

Back again, I think I understand the way to get carryover units into each mission with script:

Code: Select all

id=AddCarryoverUnit(16, 25+i, 5,0,i ) ;
giving the position in which to place it, the mission from where it is taking it, the side, and I guess the last (i) is the index for the array of CarryOverUnits. My question is how is that array filled?

Lets say I have 4 units that will be carried over, in what order are those included in the array? I want to be able to bring only some of the units from a mission not all of them.
pipfromslitherine
Site Admin
Site Admin
Posts: 9937
Joined: Wed Mar 23, 2005 10:35 pm

Re: Market Garden carry over campaign mode

Post by pipfromslitherine »

You can't really rely on the ordering of the units I don't think, they are probably consistent from run to run, but if units get changed then the order could alter. The array is created by the game automatically when it saves the carryover units into the save file.

There isn't currently any functionality to interogate the array. You could of course create the unit, then remove it if you don't want it, but that would mess up unit counts and so on as the unit is only 'hidden' rather than removed from the unit list etc. I'll add it to the task list.

Cheers

Pip
Post Reply

Return to “Battle Academy : Modders Corner ”