|
| 10 Aug 2012 04:15 AM |
I'm starting to be a little crazy because I can't get this to do anything, before i could make it change one person to Pastel Brown, now i can't do it with anyone (No output)
function Changeteam() local pl = game.Players:GetChildren() for i=1, #pl do pl.TeamColor = BrickColor.new("Pastel brown") |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2012 04:48 AM |
assuming you didn't post the entire script...
function Changeteam() local pl = game.Players:GetChildren() for i=1, #pl do pl[i].TeamColor = BrickColor.new("Pastel brown") |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2012 04:50 AM |
| I have tried that once and it didn't work, but i guess i'm going to try again. |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2012 04:53 AM |
| An yes, this is just a function from my script. so i have something to trigger it. |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2012 04:59 AM |
function Changeteam() local pl = game.Players:GetChildren() for i=1, #pl do pl[i].TeamColor = BrickColor.new("Pastel brown") end end
;3 |
|
|
| Report Abuse |
|
|
Gyration
|
  |
| Joined: 06 Aug 2012 |
| Total Posts: 9 |
|
|
| 10 Aug 2012 05:00 AM |
> nickbricknick464
The ends were kind of assumed. |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2012 05:01 AM |
| Thanks, until now it works in Solo, like it did last time i tried. |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2012 05:22 AM |
A function does not run until its called.
function changeteam() -- starts the function. (content here) end changeteam() -- calls the function.
Thats why a onTouched function always has script.parent.Touched:connect(onTouched)
Else that function doesnt run.
|
|
|
| Report Abuse |
|
|
|
| 10 Aug 2012 05:28 AM |
| I also said as nr. 4 or something, that i have some thing to call it, this is just a FUNCTION from my script |
|
|
| Report Abuse |
|
|
|
| 10 Aug 2012 06:27 AM |
Are you sure it's being called?
Print something in the function so you know that it is so. |
|
|
| Report Abuse |
|
|