Team change command

Get some cool tips about how to tweak your UT graphic, gameplay, and much more!
Post Reply
Mochu
Novice
Posts: 20
Joined: Tue Jan 19, 2010 10:37 am
Personal rank: noob

Team change command

Post by Mochu »

Is there any team change command in ut99 like "change team" in ut3 ? i don't want to manually change team every time in my player setup. I'm asking because i can't find any info online.
User avatar
EvilGrins
Godlike
Posts: 9668
Joined: Thu Jun 30, 2011 8:12 pm
Personal rank: God of Fudge
Location: Palo Alto, CA
Contact:

Re: Team change command

Post by EvilGrins »

I asked the same awhile ago · viewtopic.php?f=12&t=3313 · but the answers I got didn't seem to work.
http://unreal-games.livejournal.com/
Image
medor wrote:Replace Skaarj with EvilGrins :mrgreen:
Smilies · viewtopic.php?f=8&t=13758
User avatar
Barbie
Godlike
Posts: 2792
Joined: Fri Sep 25, 2015 9:01 pm
Location: moved without proper hashing

Re: Team change command

Post by Barbie »

Whow, didn't know that: !r, !b, !g, !y works - it is done by NexGen Mutator:
Spoiler

Code: Select all

/***************************************************************************************************
 *
 *  $DESCRIPTION  Handles a potential command message.
 *  $PARAM        sender     PlayerPawn that has send the message in question.
 *  $PARAM        msg        Message send by the player, which could be a command.
 *  $REQUIRE      sender != none
 *  $RETURN       True if the specified message is a command, false if not.
 *
 **************************************************************************************************/
function bool handleMsgCommand(PlayerPawn sender, string msg) {
	local string cmd;
	local bool bIsCommand;
	local int index;
	
	cmd = class'NexgenUtil'.static.trim(msg);
	bIsCommand = true;
	switch (cmd) {
		// Team commands.
		case "!r": case "!red":     mutate(CMD_Prefix @ CMD_SwitchTeam @ 0, sender); break;
		case "!b": case "!blue":    mutate(CMD_Prefix @ CMD_SwitchTeam @ 1, sender); break;
		case "!g": case "!green":   mutate(CMD_Prefix @ CMD_SwitchTeam @ 2, sender); break;
		case "!y": case "!yellow": case "!gold":   mutate(CMD_Prefix @ CMD_SwitchTeam @ 3, sender); break;
		case "!t": case "!team":   case "!teams":  mutate(CMD_Prefix @ CMD_BalanceTeams,   sender); break;
		
		// Game commands.
		case "!p": case "!play":    mutate(CMD_Prefix @ CMD_Play,           sender); break;
		case "!s": case "!spec":    mutate(CMD_Prefix @ CMD_Spectate,       sender); break;
		case "!l": case "!start":   mutate(CMD_Prefix @ CMD_StartGame,      sender); break;
		case "!quit": case "!exit": mutate(CMD_Prefix @ CMD_Exit,           sender); break;
		case "!leave": case "!bye": mutate(CMD_Prefix @ CMD_Disconnect,     sender); break; 
		
		// GUI commands.
		case "!o": case "!open":    mutate(CMD_Prefix @ CMD_Open,           sender); break;
		case "!v": case "!vote":    mutate(CMD_Prefix @ CMD_OpenVote,       sender); break;
		
		// Not a command.
		default: bIsCommand = false;
	}
	
	// Allow plugins to handle commands.
	index = 0;
	while (!bIsCommand && index < arrayCount(plugins) && plugins[index] != none) {
		bIsCommand = plugins[index].handleMsgCommand(sender, msg);
		index++;
	}
	
	return bIsCommand;
}
"Multiple exclamation marks," he went on, shaking his head, "are a sure sign of a diseased mind." --Terry Pratchett
User avatar
EvilGrins
Godlike
Posts: 9668
Joined: Thu Jun 30, 2011 8:12 pm
Personal rank: God of Fudge
Location: Palo Alto, CA
Contact:

Re: Team change command

Post by EvilGrins »

Oh... that explains it.
Barbie wrote:it is done by NexGen Mutator
I was looking for something general, that didn't require something extra added.

I don't have NexGen.
http://unreal-games.livejournal.com/
Image
medor wrote:Replace Skaarj with EvilGrins :mrgreen:
Smilies · viewtopic.php?f=8&t=13758
Aldebaran
Masterful
Posts: 672
Joined: Thu Jan 28, 2016 7:30 pm

Re: Team change command

Post by Aldebaran »

You can set a keybind in the User.ini file like:

Code: Select all

KEY=NWClientExit|mutate nsc setteam 1
By pressing the KEY ingame you change in this case to team blue.
But it only works on server that have Nexgen Controller installed. Many server have it.
Post Reply