PDA

View Full Version : probably easy to do but i cant: tdm with teamplayerstarts



legacy-YAWA YLF
09-05-2003, 08:54 AM
how can i have teamplayerstarts for a TDM game?

i looked in the .uc's but im no coder so i dont really know what to do/look for

can anyone explain it to me or just send such little mod to me plzzz ( bennievl@hotmail.com )

tia :)

legacy-[SGC]-Dominion
09-06-2003, 08:14 AM
Player start properties -> Player start -> Team number

Set this to 0 or 1 or higher if you have more than 2 teams

0=Red
1=Blue

legacy-YAWA YLF
09-06-2003, 10:20 AM
Originally posted by [SGC]-Dominion
Player start properties -> Player start -> Team number

Set this to 0 or 1 or higher if you have more than 2 teams

0=Red
1=Blue

i know that
but that doesnt work in tdm :/

legacy-[SGC]-Dominion
09-06-2003, 12:34 PM
Sorry I assumed it would be the same as the CTF map I am working on :/


[Edit]

This guy seems to have cracked it HERE (http://ina-community.com/forums/showthread.php?threadid=307651)

legacy-YAWA YLF
09-06-2003, 02:04 PM
Originally posted by [SGC]-Dominion
Sorry I assumed it would be the same as the CTF map I am working on :/


[Edit]

This guy seems to have cracked it HERE (http://ina-community.com/forums/showthread.php?threadid=307651)

thx but i already pmed him a few days ago :D
no answer :(

legacy-Mr Evil
09-06-2003, 04:07 PM
The bit which causes players to spawn at their own team's PlayerStarts is this function, in TeamGame.uc:

function float RatePlayerStart(NavigationPoint N, byte Team, Controller Player)
{
local PlayerStart P;

P = PlayerStart(N);
if ( P == None )
return -10000000;
if ( bSpawnInTeamArea && (Team != P.TeamNumber) )
return -9000000;

return Super.RatePlayerStart(N,Team,Player);
}
The interesting bit is that it will only prevent spawning at a different team's PlayerStart if the variable 'bSpawnInTeamArea' is set to 'true'. You should be able to set that via a mutator, somthing like this:

class MutTeamStart extends Mutator;

function PostBeginPlay()
{
if(Level.Game.IsA('TeamGame')
TeamGame(Level.Game).bSpawnInTeamArea = true;
}

defaultproperties
{
FriendlyName="Team Start"
Description="Team area spawning in TDM."
}

legacy-YAWA YLF
09-07-2003, 05:31 PM
Originally posted by Mr Evil
The bit which causes players to spawn at their own team's PlayerStarts is this function, in TeamGame.uc:

function float RatePlayerStart(NavigationPoint N, byte Team, Controller Player)
{
local PlayerStart P;

P = PlayerStart(N);
if ( P == None )
return -10000000;
if ( bSpawnInTeamArea && (Team != P.TeamNumber) )
return -9000000;

return Super.RatePlayerStart(N,Team,Player);
}
The interesting bit is that it will only prevent spawning at a different team's PlayerStart if the variable 'bSpawnInTeamArea' is set to 'true'. You should be able to set that via a mutator, somthing like this:

class MutTeamStart extends Mutator;

function PostBeginPlay()
{
if(Level.Game.IsA('TeamGame')
TeamGame(Level.Game).bSpawnInTeamArea = true;
}

defaultproperties
{
FriendlyName="Team Start"
Description="Team area spawning in TDM."
}

thx :)

but im doing something wrong i think
i compile it, no errors but it wont show up in the mutator screen :(

legacy-Mr Evil
09-07-2003, 06:28 PM
Originally posted by YAWA YLF
thx :)

but im doing something wrong i think
i compile it, no errors but it wont show up in the mutator screen :(
You have probably not made an int file. You can make one in any plain text editor, such as Notepad. Put these lines in it and save it with the name 'YourPackage.int' (replacing 'YourPackage' with the name you gave the compiled u file):

[Public]
Object=(Class=Class,MetaClass=Engine.Mutator,Name= YourPackage.MutTeamStart,Description="A descriptive description.")

You can find more information on that sort of thing on the Wiki: http://wiki.beyondunreal.com/wiki

legacy-YAWA YLF
09-08-2003, 12:01 PM
yeah thx i forgot that :)

it works now ty :):up:

legacy-YAWA YLF
09-08-2003, 12:06 PM
oh one more thing

how do you distribute it best/easiest?