Posting a custom scenario

Post Reply
HolyTerra
Corporal - 5 cm Pak 38
Corporal - 5 cm Pak 38
Posts: 32
Joined: Fri Jan 27, 2017 11:23 pm

Posting a custom scenario

Post by HolyTerra »

I made a scenario and I can play it on my own computer just fine, but I am missing how to post it online. Is there a way for me and a friend to play against one another in scenarios I created on the editor? If so can someone explain it, I can not seem to find this anywhere.

I have created the file in my multiplayer folder, and I can select the scenario in the advanced tab but it still just gives me the skirmish instead of my custom map and units. The other player has the file too. I feel like I am missing some really obvious part.
Mophead
Corporal - Strongpoint
Corporal - Strongpoint
Posts: 59
Joined: Sun Jan 29, 2017 7:23 pm

Re: Posting a custom scenario

Post by Mophead »

You made a custom multiplayer map, and are trying to setup a multiplayer match?

I'm just not sure, it sounds like you have custom singleplayer campaign and are trying to setup skirmish match. Skirmish has its own map generation, Pip released that code for increased armies.

If you have a custom multiplayer map and can set it up online and play it hotseat - play both sides, then I think you both should be able to connect. If you create the match can the opponent see & select it? If all that is good and you are getting a skirmish map then there is something, the custom multiplayer scenario has a .bam file, correct?

*Edit: did you add the scenario name to the Campaign.txt?

Code: Select all

[CustomName]
If it isn't listed, it might not load and defaults to skirmish random map.
HolyTerra
Corporal - 5 cm Pak 38
Corporal - 5 cm Pak 38
Posts: 32
Joined: Fri Jan 27, 2017 11:23 pm

Re: Posting a custom scenario

Post by HolyTerra »

Mophead wrote:You made a custom multiplayer map, and are trying to setup a multiplayer match?
Yes, I want to play on a map of my own creation with a friend. Like the Prime or Bloodmist scenarios where you have the same map every time and the same troops to chose from every time. I made this map in the multi player folder and saved it.
Mophead wrote: I'm just not sure, it sounds like you have custom singleplayer campaign and are trying to setup skirmish match. Skirmish has its own map generation, Pip released that code for increased armies.
This is what is seems like to me, except I made it in the multi player folder. I go through the create game button in the multi player screen, chose create skirmish and then chose the advanced tab and then chose the 'Use default settings' button at the bottom of that to access the campaign/scenario. All this does is add the campagin name to the bottom of the mission/skirmish read out before clicking the accept button. I assumed and hoped it would show the name of the map in the same box where it shows Acid Hills and Bloodmist etc but it dosnt. It just offers me a skirmish with the name of the scenario attatched to the bottom of it.
Mophead wrote: If you have a custom multiplayer map and can set it up online and play it hotseat - play both sides, then I think you both should be able to connect. If you create the match can the opponent see & select it? If all that is good and you are getting a skirmish map then there is something, the custom multiplayer scenario has a .bam file, correct?
Yes, it has a .bam file. I had a friend who had the same scenario in their multi player folder select the game, but he and I only got served up a random map that had nothing to do with the scenario.


Mophead wrote: *Edit: did you add the scenario name to the Campaign.txt?

Code: Select all

[CustomName]
If it isn't listed, it might not load and defaults to skirmish random map.
I just did this, I got very excited thinking this must be the step I missed. I put the scenario name inside brackets like you have there, and it made my game crash, the error message said something like I was using a Hard Chunk in the line where it was. I took out the brackets and the game will start but back to where I started without the game giving me the scenario but a random map instead.
Mophead
Corporal - Strongpoint
Corporal - Strongpoint
Posts: 59
Joined: Sun Jan 29, 2017 7:23 pm

Re: Posting a custom scenario

Post by Mophead »

HolyTerra wrote:
Mophead wrote: If you have a custom multiplayer map and can set it up online and play it hotseat - play both sides, then I think you both should be able to connect. If you create the match can the opponent see & select it? If all that is good and you are getting a skirmish map then there is something, the custom multiplayer scenario has a .bam file, correct?
Yes, it has a .bam file. I had a friend who had the same scenario in their multi player folder select the game, but he and I only got served up a random map that had nothing to do with the scenario.


Mophead wrote: *Edit: did you add the scenario name to the Campaign.txt?

Code: Select all

[CustomName]
If it isn't listed, it might not load and defaults to skirmish random map.
I just did this, I got very excited thinking this must be the step I missed. I put the scenario name inside brackets like you have there, and it made my game crash, the error message said something like I was using a Hard Chunk in the line where it was. I took out the brackets and the game will start but back to where I started without the game giving me the scenario but a random map instead.
The name in the brackets for [CustomName] comes from the Scenario.BAM file, exact same case- upper/lower?

Have you tried to open the map in the editor - not sure if you made it as a multiplayer map or cut & pasted it into the folder.

Did you make the map in, and are playing in, v.1.0.10?

I had a custom map that worked in hotseat, never tested it remotely. I'm trying to remember if I did anything else different from a single-player map.
Mophead
Corporal - Strongpoint
Corporal - Strongpoint
Posts: 59
Joined: Sun Jan 29, 2017 7:23 pm

Re: Posting a custom scenario

Post by Mophead »

#1 don't get frustrated and take a break if it is getting to you. It can work, I've had my share of confusions. Here is my custom multiplayer tree:

Code: Select all

MULTICUSTOM
|
|---ArmyList.txt
|
|---CAMPAIGN.txt
|
|---Sanctus_Valid_Names.txt
|
|---Text1.txt
|
|---Text3.txt
|
|---Text9.txt
|
|-----DATA
	|
	|-----SCRIPTS
		|
		|---CombatTools.BSF
	|
	|-----BATTLE
		|
		|-----UNITTEXTURES
		|
		|-----SCRIPTS
			|
			|---AbilityHelpers.BSF
|
|-----SCENARIOS
	|
	|---SCENARIO.BAM
	|
	|---SCENARIO.BSF
Text9.txt

Code: Select all

IDS_SCENARIO_YourScenarioName, "Your Scenario Name",
I'm not sure if the AbilityHelpers & CombatTools .bsf files are needed, they work with/for a custom army. I also have:
Sanctus_Ork_Abilities.txt
Sanctus_Valid_Names.txt
Sanctus_Wolves_Abilities.txt
..in the Custom Multiplayer Campaign fodler (with the ArmyList & Text# .txt files), I don't think you need them unless you are changing that stuff up or adding units.

The Scenario.bsf, I'm not sure if you need it - victory conditions set in the editor will function without the .bsf file. The elimination victory condition is default but included here anyway:

Code: Select all

include "CombatTools.BSF"
include "Functions.BSF"
include "ScenarioTools.BSF"
include "Tools.BSF"
include "AbilityHelpers.BSF"


FUNCTION StartTurn(1)
{

}


FUNCTION Tick(side)
{
	if (GetUniversalVar("TerrainSmoothing") != 1)
	{
		SetMapTerrainSmoothing(4, 0);
		SetUniversalVar("TerrainSmoothing", 1);
	}
}



FUNCTION DrawScenarioUI()
{

}


FUNCTION VictoryConditions()
{
	int i;
	int id ;
	int counter ;
// Count units to see if a side is destroyed
// Just count wolves to see if they have lost.  

	counter = 0 ;
	for(i=0; i<GetUnitCount(0); i++)
	{
		id = GetUnitID(0, i) ;
		if(GetUnitDead(id) == 0)
		{
			counter ++ ;
		}
	}
	
	if(counter == 0 )
	{
		EndBattle(1);
	}
	for(i=0; i<GetUnitCount(1); i++)
	{
		id = GetUnitID(0, i) ;
		if(GetUnitDead(id) == 0)
		{
			counter ++ ;
		}
	}
	
	if(counter == 0 )
	{
		EndBattle(1);
	}

}

FUNCTION PreBattleSetup()
{
	SetUniversalVar("TerrainSmoothing", 0);
	
}
It could just be that Text9.txt file, if you have the other two Text#.txt files already. If not that, the AbilityHelpers and CombatTools could be required. For the unit-modding, I had also removed the "#" in both of those .bsf files.
Its something like: FromFileGetFile(#Sanctus_Squad_Names), becomes FromFileGetFile(Sanctus_Squad_Names).
HolyTerra
Corporal - 5 cm Pak 38
Corporal - 5 cm Pak 38
Posts: 32
Joined: Fri Jan 27, 2017 11:23 pm

Re: Posting a custom scenario

Post by HolyTerra »

I think your answer is a little beyond where I am at. I started over with an empty campaign folder created in the multi player folder. I made the simplest of maps with troops on it.

Then I went in to the campaign text document and added your line exactly,
IDS_SCENARIO_YourScenarioName, "Your Scenario Name",

Of corse I replaced the two incidents of 'Your scenario with the name copied from my .bam file. I played posted it online and again went through skirmish to get to the advanced tab and then the default tab to get the secnario name and was able to accept the game but again it gave me a random map with random forces.

I am not trying to make custom troops or any exceptions to the rules of the game, I just want the map I made with the troops choices I left on the map to chose from to be the ones you pick from. If thats -all- I am trying to do and campaign folder is called 'TESTCAMPAIGN' and my scenario is 'Test Scenario.bam' what exactly should I have in my currently empty campaign text document?
pipfromslitherine
Site Admin
Site Admin
Posts: 9701
Joined: Wed Mar 23, 2005 10:35 pm

Re: Posting a custom scenario

Post by pipfromslitherine »

The most common issue with crashing CAMPAIGN.TXT files is if you are using spaces in your filenames (which you shouldn't). Try renaming the files and chunk name and you should see your mission listed in the MP setup dialog.

Cheers

Pip
follow me on Twitter here
HolyTerra
Corporal - 5 cm Pak 38
Corporal - 5 cm Pak 38
Posts: 32
Joined: Fri Jan 27, 2017 11:23 pm

Re: Posting a custom scenario

Post by HolyTerra »

pipfromslitherine wrote:The most common issue with crashing CAMPAIGN.TXT files is if you are using spaces in your filenames (which you shouldn't). Try renaming the files and chunk name and you should see your mission listed in the MP setup dialog.
This was it. I made this change and saw the scenario name in the list with the others. Thanks to both of you for the help.
Post Reply

Return to “Sanctus Reach Mods and Scenario Design”