|
| 22 Feb 2013 07:24 AM |
| Hello,my title says everything i need a way to make each team have different weapons,just this |
|
|
| Report Abuse |
|
|
cart6157
|
  |
| Joined: 28 Feb 2009 |
| Total Posts: 2194 |
|
|
| 22 Feb 2013 07:42 AM |
| Here's the best way: Learn to script and stop requesting scripts on this forum. |
|
|
| Report Abuse |
|
|
|
| 22 Feb 2013 07:50 AM |
function teamFromColor(color) for _,t in pairs(game:GetService("Teams"):GetChildren()) do if t.TeamColor==color then return t end end return nil end
function onSpawned(plr) local tools = teamFromColor(plr.TeamColor):GetChildren() for _,c in pairs(tools) do c:Clone().Parent = plr.Backpack end end
function onChanged(prop,plr) if prop=="Character" then onSpawned(plr) end end
function onAdded(plr) plr.Changed:connect(function(prop) onChanged(prop,plr) end) end
game.Players.PlayerAdded:connect(onAdded)
Put this script in workspace and the tools in the teams that you want to have them. |
|
|
| Report Abuse |
|
|
|
| 22 Feb 2013 07:55 AM |
@PredationX thanks
@cart6157 shame on you,dumpy
|
|
|
| Report Abuse |
|
|