Unique Boundaries for each game mode? [Solved]

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
modmaster13
General
General
Posts: 777
Joined: Wed Aug 18, 2010 4:23 pm
Games I'm Playing :: COD SWBF
xbox live or psn: KrypticcElementt
Location: Twitter @_KrypticElement
Contact:

Unique Boundaries for each game mode? [Solved]

Post by modmaster13 »

Hey everyone, I have two questions.

1) Is it possible to make a boundary specific to 1 game mode only?

2) Can I set up the boundary via a path (instead of setting it up in the boundary section of ZE)? I have a path called "CTFBound" in my path section of my CTF layer in ZE.


I'm looking to have 3 different boundaries, one unique boundary for each game mode.
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Unique Boundaries for each game mode?

Post by Marth8880 »

modmaster13 wrote:1) Is it possible to make a boundary specific to 1 game mode only?
You might be able to do it by removing the boundary section from the world REQ file and putting it in the game mode's MRQ file (which is basically a REQ file) - I know this is how Pandemic set up unique planning for different game modes in a single map. With that said, you'll need to manually rename the BND file to the correct name whenever you want to make changes to it.
modmaster13 wrote:2) Can I set up the boundary via a path (instead of setting it up in the boundary section of ZE)? I have a path called "CTFBound" in my path section of my CTF layer in ZE.
Probably. If you look at kas2.bnd, you'll notice that it references 2 path names, "boundary1" and "boundary2":

Code: Select all

Boundary()
{
	Path("boundary1");
	Path("boundary2");
}
Both of these paths can be found in kas2.pth:
Hidden/Spoiler:
[code]Path("boundary1")
{
Data(0);
PathType(0);
PathSpeedType(0);
PathTime(0.000000);
OffsetPath(0);
SplineType("Hermite");

Properties(0)
{
}

Nodes(12)
{
Node()
{
Position(236.830490, 33.685246, 91.398972);
Knot(0.000000);
Data(1);
Time(1.000000);
PauseTime(0.000000);
Rotation(1.000000, 0.000000, 0.000000, 0.000000);
Properties(0)
{
}
}

...

}

}

Path("boundary2")
{
Data(0);
PathType(0);
PathSpeedType(0);
PathTime(0.000000);
OffsetPath(0);
SplineType("Hermite");

Properties(0)
{
}

Nodes(12)
{
Node()
{
Position(287.077423, 31.466921, -61.837532);
Knot(0.000000);
Data(1);
Time(1.000000);
PauseTime(0.000000);
Rotation(1.000000, 0.000000, 0.000000, 0.000000);
Properties(0)
{
}
}

...

}

}[/code]
Much like setting up a billboard tree path, the direction in which the path is created (clockwise vs. counterclockwise) is important - although I can't remember which one is actually correct, so you'll have to do a few tests and figure that out yourself.

Finally, it should be noted that boundaries must always be named "boundary", followed by a number if there are multiple boundary paths.
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3284
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: Unique Boundaries for each game mode?

Post by AceMastermind »

modmaster13 wrote:1) Is it possible to make a boundary specific to 1 game mode only?

2) Can I set up the boundary via a path (instead of setting it up in the boundary section of ZE)? I have a path called "CTFBound" in my path section of my CTF layer in ZE.

I'm looking to have 3 different boundaries, one unique boundary for each game mode.
Paths and boundaries serve a different purpose, if you want a boundary just use the Boundary tab in ZE, easy enough.
If you want a different boundary for each game mode just add a boundary to the specific layer for each game mode.
Boundary names are arbitrary by the way, you can name them anything you want.

https://sites.google.com/site/swbf2modt ... a-boundary
https://sites.google.com/site/swbf2modt ... _gamemodes
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Unique Boundaries for each game mode?

Post by Marth8880 »

AceMastermind wrote:Paths and boundaries serve a different purpose, if you want a boundary just use the Boundary tab in ZE, easy enough.
Problem is sometimes you need more precise boundaries.
AceMastermind wrote:If you want a different boundary for each game mode just add a boundary to the specific layer for each game mode.
Are you sure that boundaries are bound to layers? If they are, great, that makes it way simpler 8D
AceMastermind wrote:Boundary names are arbitrary by the way, you can name them anything you want.
I don't think so. I'd have to check, but I don't recall being able to use just any name in any of the recent maps I've worked on - and I tried with each one of them.
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3284
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: Unique Boundaries for each game mode?

Post by AceMastermind »

Marth8880 wrote:Problem is sometimes you need more precise boundaries.
What kind of precision are you looking for in boundaries? :)
You can create as many as you need to get precise, but it sounds like you're using boundaries for the wrong thing.
If you're looking to keep the player confined to a specific area then you should use collision or death/damage regions etc.
Marth8880 wrote:Are you sure that boundaries are bound to layers?
Not a 100%, but that is a benefit of using layers in SWBF2 modding, so I see no reason it shouldn't work.
It should only take you a few minutes to test if you already have different game modes ready.
Marth8880 wrote:I don't think so. ... I don't recall being able to use just any name
I performed these experiments years ago and the names can be anything you want. I'm not sure why you're experiencing problems.
The boundary name for the one on this page when the screenshot was taken was named "ace". :)
https://sites.google.com/site/swbf2modt ... a-boundary
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Unique Boundaries for each game mode?

Post by Marth8880 »

AceMastermind wrote:What kind of precision are you looking for in boundaries?
It's a rare occasion, but sometimes I need 90-degree angles in the boundaries.
AceMastermind wrote:If you're looking to keep the player confined to a specific area then you should use collision or death/damage regions etc.
I personally despise invisible collision in most cases, and death/damage regions (except in pits etc.) penalize the player for exploring, whereas boundaries at least provide time for the player to take a step back before being penalized. :P
AceMastermind wrote:but that is a benefit of using layers in SWBF2 modding
Indeed 8D

Image

(among many others)
modmaster13
General
General
Posts: 777
Joined: Wed Aug 18, 2010 4:23 pm
Games I'm Playing :: COD SWBF
xbox live or psn: KrypticcElementt
Location: Twitter @_KrypticElement
Contact:

Re: Unique Boundaries for each game mode?

Post by modmaster13 »

Hey guys, thanks for all the help, so I tried adding a boundary to my map that is only for 1-Flag CTF (The CTF specific boundary is located in the CTF Layer). Here is what it looks like in ZE:
Hidden/Spoiler:
Image
And here's what happens when I go ingame. The boundary isn't there, and I'm able to go explore outside of it:
Hidden/Spoiler:
Image
Any ideas of where I could go from here?
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Unique Boundaries for each game mode?

Post by Marth8880 »

Refer to my initial reply. ;)
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3284
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: Unique Boundaries for each game mode?

Post by AceMastermind »

modmaster13 wrote:The boundary isn't there, and I'm able to go explore outside of it ... Any ideas of where I could go from here?
You don't still have a boundary in the base layer do you?
modmaster13
General
General
Posts: 777
Joined: Wed Aug 18, 2010 4:23 pm
Games I'm Playing :: COD SWBF
xbox live or psn: KrypticcElementt
Location: Twitter @_KrypticElement
Contact:

Re: Unique Boundaries for each game mode?

Post by modmaster13 »

Update: I have the layer "Design" in ZE completely empty except for my boundary that I want for Conquest. The "Design" layer only loads with conquest, and it's not a common layer.
Hidden/Spoiler:
Image
I made a new layer called "obj boundary" that holds the boundary I want for all game modes except for Conquest. It is not a common layer.
Hidden/Spoiler:
Image
Here is my world REQ file:
Hidden/Spoiler:
ucft
{
REQN
{
"class"

}

REQN
{
"config"
}

REQN
{
"texture"
"RhenVar1_map"
}

REQN
{
"texture"
"platform=ps2"
}

REQN
{
"texture"
"platform=xbox"
}

REQN
{
"texture"
"platform=pc"

}


REQN
{
"path"
"RhenVar1"
}
REQN
{
"congraph"
"RhenVar1"
}
REQN
{
"envfx"
"RhenVar1"
}
REQN
{
"world"
"RhenVar1"
"RhenVar1_SoundRegions"
"RhenVar1_SoundSpaces"
"RhenVar1_SoundRegionEnv"
"RhenVar1_Collision"
"RhenVar1_gcw_tur"
"RhenVar1_stuff"
}
REQN
{
"prop"
"RhenVar1"
}
REQN
{
"class"
}
REQN
{
"config"
"flyerspray"
"walkerstomp"
"bigwalkerstomp"
"hailfire_wake"
}
REQN
{
"lvl"
"RhenVar1_conquest"
"RhenVar1_ctf"
"RhenVar1_hunt"
"RhenVar1_celebs"
"RhenVar1_2flagctf"
"RhenVar1_tdm"
}
}
Here is my world BND file:
Hidden/Spoiler:
Boundary()
{
Path("boundary");
Path("boundary2");
}
Here is the MRQ for my 1-Flag CTF game mode (that I want "boundary2" in):
Hidden/Spoiler:
ucft
{
REQN
{
"congraph"
"RhenVar1_ctf"
}
REQN
{
"world"
"RhenVar1_ctf"
"RhenVar1_obj boundary"
}
REQN
{
"boundary2"
"RhenVar1"
}
}
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3284
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: Unique Boundaries for each game mode?

Post by AceMastermind »

modmaster13 wrote: Here is the MRQ for my 1-Flag CTF game mode (that I want "boundary2" in):

Code: Select all

ucft
{
	REQN
	{
		"congraph"
		"RhenVar1_ctf"
	}
	REQN
	{
		"world"
		"RhenVar1_ctf"
		"RhenVar1_obj boundary"
	}
	REQN
	{
		"boundary2"
		"RhenVar1"
	}
}
A couple of things I see here, you shouldn't use spaces in names like you did with "RhenVar1_obj boundary", instead use an underscore so it is "RhenVar1_obj_boundary".
Also, "boundary2" just above "RhenVar1" should just be "boundary", this refers to the bnd file, it is a subsection header not a boundary name.
"RhenVar1" means this is the name of your bnd file storing your boundary names, so it is looking for "RhenVar1.bnd".
Maybe I will reinstall the game just to test for working boundaries in custom layers so we can at least put that to rest. :)
modmaster13
General
General
Posts: 777
Joined: Wed Aug 18, 2010 4:23 pm
Games I'm Playing :: COD SWBF
xbox live or psn: KrypticcElementt
Location: Twitter @_KrypticElement
Contact:

Re: Unique Boundaries for each game mode?

Post by modmaster13 »

AceMastermind wrote: A couple of things I see here, you shouldn't use spaces in names like you did with "RhenVar1_obj boundary", instead use an underscore so it is "RhenVar1_obj_boundary".
Also, "boundary2" just above "RhenVar1" should just be "boundary", this refers to the bnd file, it is a subsection header not a boundary name.
"RhenVar1" means this is the name of your bnd file storing your boundary names, so it is looking for "RhenVar1.bnd".
Maybe I will reinstall the game just to test for working boundaries in custom layers so we can at least put that to rest. :)
So I edited my 1-Flag CTF MRQ to what you said, here it is:
Hidden/Spoiler:
ucft
{
REQN
{
"congraph"
"RhenVar1_ctf"
}
REQN
{
"world"
"RhenVar1_ctf"
"RhenVar1_obj boundary"
}
REQN
{
"boundary"
"RhenVar1"
}
}
And my layer in ZE is called "obj boundary", there's no "_". Does there still need to be an "_" in between "obj" and "boundary" in the MRQ file? I added one in there even though there isn't an "_" in the layer name, and the boundary still didn't show up in game
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Unique Boundaries for each game mode?

Post by Marth8880 »

You need to rename the layer itself in ZE so that there's no spaces in the name. After you've done that, click the "Configure" button under "Game Modes", click "Update World REQs and Mode MRQs", browse to your world's main REQ file, and double-click it to save the changes. (also don't forget to save your world of cause)
modmaster13
General
General
Posts: 777
Joined: Wed Aug 18, 2010 4:23 pm
Games I'm Playing :: COD SWBF
xbox live or psn: KrypticcElementt
Location: Twitter @_KrypticElement
Contact:

Re: Unique Boundaries for each game mode?

Post by modmaster13 »

Marth8880 wrote:You need to rename the layer itself in ZE so that there's no spaces in the name. After you've done that, click the "Configure" button under "Game Modes", click "Update World REQs and Mode MRQs", browse to your world's main REQ file, and double-click it to save the changes. (also don't forget to save your world of cause)
Okay. I renamed the layer to "obj_boundary" in ZE. Updated the REQ and MRQ's:
Hidden/Spoiler:
Image
Rhn1.REQ:
Hidden/Spoiler:
ucft
{
REQN
{
"class"

}

REQN
{
"config"
}

REQN
{
"texture"
"RhenVar1_map"
}

REQN
{
"texture"
"platform=ps2"
}

REQN
{
"texture"
"platform=xbox"
}

REQN
{
"texture"
"platform=pc"

}


REQN
{
"path"
"RhenVar1"
}
REQN
{
"congraph"
"RhenVar1"
}
REQN
{
"envfx"
"RhenVar1"
}
REQN
{
"world"
"RhenVar1"
"RhenVar1_SoundRegions"
"RhenVar1_SoundSpaces"
"RhenVar1_SoundRegionEnv"
"RhenVar1_Collision"
"RhenVar1_gcw_tur"
"RhenVar1_stuff"
}
REQN
{
"prop"
"RhenVar1"
}
REQN
{
"class"
}
REQN
{
"config"
"flyerspray"
"walkerstomp"
"bigwalkerstomp"
"hailfire_wake"
}
REQN
{
"lvl"
"RhenVar1_conquest"
"RhenVar1_ctf"
"RhenVar1_hunt"
"RhenVar1_celebs"
"RhenVar1_2flagctf"
"RhenVar1_tdm"
}
}
RhenVar1_ctf:
Hidden/Spoiler:
ucft
{
REQN
{
"congraph"
"RhenVar1_ctf"
}
REQN
{
"world"
"RhenVar1_ctf"
"RhenVar1_obj_boundary"
}
REQN
{
"boundary"
"RhenVar1"
}
}
RhenVar1.BND:
Hidden/Spoiler:
Boundary()
{
Path("boundary");
Path("boundary2");
}
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Unique Boundaries for each game mode?

Post by Marth8880 »

ok does it work
modmaster13
General
General
Posts: 777
Joined: Wed Aug 18, 2010 4:23 pm
Games I'm Playing :: COD SWBF
xbox live or psn: KrypticcElementt
Location: Twitter @_KrypticElement
Contact:

Re: Unique Boundaries for each game mode?

Post by modmaster13 »

Marth8880 wrote:ok does it work
It does not (sorry I don't know how I forgot to mention that)
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3284
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: Unique Boundaries for each game mode?

Post by AceMastermind »

Do any of your boundaries work? If not maybe you should focus on getting one to work first from the base layer, then move it to an existing CTF layer and finally worry about the other last. :)
modmaster13
General
General
Posts: 777
Joined: Wed Aug 18, 2010 4:23 pm
Games I'm Playing :: COD SWBF
xbox live or psn: KrypticcElementt
Location: Twitter @_KrypticElement
Contact:

Re: Unique Boundaries for each game mode?

Post by modmaster13 »

I just did some ingame testing, and both boundaries work, except the two boundaries work like they work like they do on Kashyyyk, where they both merge and work with each other. My second boundary for the objective game modes only extends the original boundary path.

The boundary I want for Conquest only is in the "conquest" layer:
Hidden/Spoiler:
Image
and the objective boundary is still in the "obj_boundary" layer:
Hidden/Spoiler:
Image
Both of those layers I just mentioned are not common layers.

Here's my current world REQ file:
Hidden/Spoiler:
ucft
{
REQN
{
"class"

}

REQN
{
"config"
}

REQN
{
"texture"
"RhenVar1_map"
}

REQN
{
"texture"
"platform=ps2"
}

REQN
{
"texture"
"platform=xbox"
}

REQN
{
"texture"
"platform=pc"

}


REQN
{
"path"
"RhenVar1"
}
REQN
{
"congraph"
"RhenVar1"
}
REQN
{
"envfx"
"RhenVar1"
}
REQN
{
"world"
"RhenVar1"
"RhenVar1_SoundRegions"
"RhenVar1_SoundSpaces"
"RhenVar1_SoundRegionEnv"
"RhenVar1_Collision"
"RhenVar1_gcw_tur"
"RhenVar1_stuff"
}
REQN
{
"prop"
"RhenVar1"
}
REQN
{
"class"
}
REQN
{
"config"
"flyerspray"
"walkerstomp"
"bigwalkerstomp"
"hailfire_wake"
}
REQN
{
"lvl"
"RhenVar1_conquest"
"RhenVar1_ctf"
"RhenVar1_hunt"
"RhenVar1_celebs"
"RhenVar1_2flagctf"
"RhenVar1_tdm"
"RhenVar1_obj_boundary"
}
}
Here's my RhenVar1_conquest.MRQ:
Hidden/Spoiler:
ucft
{
REQN
{
"congraph"
"RhenVar1_conquest"
}
REQN
{
"world"
"RhenVar1_conquest"
}
REQN
{
"boundary"
"RhenVar1"
}
}
RhenVar1_ctf.MRQ:
Hidden/Spoiler:
ucft
{
REQN
{
"congraph"
"RhenVar1_ctf"
}
REQN
{
"world"
"RhenVar1_ctf"
"RhenVar1_obj_boundary"
}
REQN
{
"boundary"
"RhenVar1"
}
}
The most frustrating thing about this is that there are two different boundaries for Rhen Var Harbor on the Xbox DLC version of the map, so you'd think if it's possible to do it on the Xbox you can do it on the PC, right?
Hidden/Spoiler:
Image
I just want to get this to work lol :cpu:
User avatar
AceMastermind
Gametoast Staff
Gametoast Staff
Posts: 3284
Joined: Mon Aug 21, 2006 6:23 am
Contact:

Re: Unique Boundaries for each game mode?

Post by AceMastermind »

I can't really follow what you've done until now but I would think you'd need 2 bnd files if you want a unique one for CTF and another for all other game modes.
If "boundary2" is only for CTF maybe that should be the only one listed in RhenVar1.BND.
So say you rename RhenVar1.bnd to "RhenVar1_a.bnd" with this content:

Code: Select all

Boundary()
{
Path("boundary2");
}
then you create a RhenVar1_b.bnd file for the boundary in other game modes with this content:

Code: Select all

Boundary()
{
Path("boundary");
}
the RhenVar1_ctf.MRQ would have this in it calling for the renamed bnd file:

Code: Select all

REQN
{
"boundary"
"RhenVar1_a"
}
and your other mrq file would have this in it:

Code: Select all

REQN
{
"boundary"
"RhenVar1_b"
}
I'm just thinking out loud here because I can't test any of this until I get the game reinstalled. :)
modmaster13
General
General
Posts: 777
Joined: Wed Aug 18, 2010 4:23 pm
Games I'm Playing :: COD SWBF
xbox live or psn: KrypticcElementt
Location: Twitter @_KrypticElement
Contact:

Re: Unique Boundaries for each game mode?

Post by modmaster13 »

YES! That worked! Thank you so much, I really appreciate the help you guys! Making two different BND files and calling for them specifically in MRQ's is the way to go.
Post Reply