generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Certain Team Change Script

Previous Thread :: Next Thread 
ScaryLiamb752 is not online. ScaryLiamb752
Joined: 09 Dec 2011
Total Posts: 173
13 Apr 2012 09:53 PM
I need help... Is there such things? If there is, please put the script coding down here. Or a model...

- Thanks ScaryLiamb752
Report Abuse
KnightmareXD is not online. KnightmareXD
Joined: 14 Jul 2009
Total Posts: 11189
13 Apr 2012 09:54 PM
There could be.

† KMXD †
Report Abuse
ScaryLiamb752 is not online. ScaryLiamb752
Joined: 09 Dec 2011
Total Posts: 173
14 Apr 2012 01:02 AM
I was thinking of script like: The person who enters in the game, is in 1 team. But then the person gets changed to another team automatically.
Report Abuse
shred1894 is not online. shred1894
Joined: 30 Aug 2009
Total Posts: 6515
14 Apr 2012 02:06 AM
I have done that for some of my group places.
S-1894>()
Report Abuse
Phellem is not online. Phellem
Joined: 04 Aug 2011
Total Posts: 1984
14 Apr 2012 03:28 AM
game.Players.PlayerAdded:connect(function(plyr)
if plyr.Name == "" then
plyr.TeamColor = game.Teams[""].TeamColor
end
end)


etc....
Report Abuse
ScaryLiamb752 is not online. ScaryLiamb752
Joined: 09 Dec 2011
Total Posts: 173
14 Apr 2012 06:05 PM
I'll try it...
Report Abuse
ScaryLiamb752 is not online. ScaryLiamb752
Joined: 09 Dec 2011
Total Posts: 173
14 Apr 2012 06:18 PM
@Phellem
Ok, I tried your script, It didn't really work. Could you put notes in it. To make it much easier...
Report Abuse
Phellem is not online. Phellem
Joined: 04 Aug 2011
Total Posts: 1984
14 Apr 2012 07:53 PM
I didn't give you the full code...
I would never do such thing.

I gave you those lines so you can fill in the blanks and modified it.
Report Abuse
ScaryLiamb752 is not online. ScaryLiamb752
Joined: 09 Dec 2011
Total Posts: 173
15 Apr 2012 05:25 AM
I know, I did fill it in... Still didn't work.
Report Abuse
Phellem is not online. Phellem
Joined: 04 Aug 2011
Total Posts: 1984
15 Apr 2012 04:05 PM
Show me what you put.
Report Abuse
ScaryLiamb752 is not online. ScaryLiamb752
Joined: 09 Dec 2011
Total Posts: 173
15 Apr 2012 11:15 PM
game.Players.PlayerAdded:connect(function(plyr)
if plyr.Name == "ScaryLiamb752","Player" then
plyr.TeamColor = game.Teams["ScaryLiamb752/EpicallyBoy"].TeamColor
end
end)

The line "plyr.TeamColor = game.Teams["ScaryLiamb752/EpicallyBoy"].TeamColor" I think is wrong :\
Report Abuse
Phellem is not online. Phellem
Joined: 04 Aug 2011
Total Posts: 1984
16 Apr 2012 12:21 PM
isAdmin = {["ScaryLiamb752"]=true,["EpicallyBoy"]=true}

game.Players.PlayerAdded:connect(function(plyr)
if plyr.Name:lower() == isAdmin[player.Name]:lower() then
plyr.TeamColor = game.Teams["ScaryLiamb752/EpicallyBoy"].TeamColor
end
end)
Report Abuse
Phellem is not online. Phellem
Joined: 04 Aug 2011
Total Posts: 1984
16 Apr 2012 12:22 PM
Forgot to put the source where I got the table from:

http://wiki.roblox.com/index.php/How_To:_Admin_Commands
Report Abuse
thek00lkid is not online. thek00lkid
Joined: 18 Jun 2011
Total Posts: 2778
16 Apr 2012 01:40 PM
game.Players.Whoever.TeamColor = BrickColor.new("Bright orange")
Report Abuse
Epicallyboy is not online. Epicallyboy
Joined: 23 Feb 2012
Total Posts: 3
18 Apr 2012 02:45 AM
ScaryLiamb752 here for now, OK. Ill test it out...
Report Abuse
Epicallyboy is not online. Epicallyboy
Joined: 23 Feb 2012
Total Posts: 3
18 Apr 2012 05:19 AM
It still didn't work.
:\
Report Abuse
Phellem is not online. Phellem
Joined: 04 Aug 2011
Total Posts: 1984
18 Apr 2012 10:02 PM
It worked for me.
Is there a team named "ScaryLiamb752/EpicallyBoy"?

Please learn to code... it would surely be useful.
Report Abuse
Phellem is not online. Phellem
Joined: 04 Aug 2011
Total Posts: 1984
18 Apr 2012 10:20 PM
My mistake.
Try this:

local isAdmin = {"ScaryLiamb752","EpicallyBoy"}

function findPlayer(name)
for _, v in ipairs(isAdmin) do
if v:lower() == name:lower() then
return v
end
end
end

game.Players.PlayerAdded:connect(function(plyr)
local user = findPlayer(plyr.Name)
if user then
plyr.TeamColor = game.Teams["ScaryLiamb752/EpicallyBoy"].TeamColor
end
end)
Report Abuse
epicpatrick123 is not online. epicpatrick123
Joined: 08 Sep 2010
Total Posts: 15039
18 Apr 2012 10:57 PM
as thek00lkid said,

game.Players.Whoever.TeamColor = BrickColor.new("Bright orange")

or you could make it a team change gui,

script.Parent.MouseButton1Down:connect(function()
game.Players.LocalPlayer.TeamColor = BrickColor.new("Bright red")
end)

or some commands allow you to team change onchatted.
Report Abuse
ScaryLiamb752 is not online. ScaryLiamb752
Joined: 09 Dec 2011
Total Posts: 173
20 Apr 2012 02:34 AM
^
|

Read the title...
Report Abuse
epicpatrick123 is not online. epicpatrick123
Joined: 08 Sep 2010
Total Posts: 15039
20 Apr 2012 07:38 AM
make a team for every player allowed in the server and make none of them auto assignable but neutral i think
Report Abuse
Phellem is not online. Phellem
Joined: 04 Aug 2011
Total Posts: 1984
20 Apr 2012 10:53 PM
^
you be confuse, dude
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image