DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
|
| 25 Jan 2014 08:10 AM |
I am pretty new with this event.
p = script.Parent.Parent.Player.Value
for _, v in pairs(game.Players.LocalPlayer.Character:GetChildren()) do for i, q in pair(v.className:IsA("Tool")) do q:Clone().Parent = game.Workspace[p] end end |
|
|
| Report Abuse |
|
|
| |
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
| |
|
|
| 25 Jan 2014 09:29 AM |
| u cant clone.. then do aprent |
|
|
| Report Abuse |
|
|
| |
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
|
| 25 Jan 2014 09:55 AM |
| Doesn't make a difference. |
|
|
| Report Abuse |
|
|
wazap
|
  |
| Joined: 29 Jun 2007 |
| Total Posts: 23234 |
|
|
| 25 Jan 2014 09:58 AM |
for _, v in pairs(game.Players.LocalPlayer.Character:GetChildren()) do if (v:IsA("Tool")) then v:Clone().Parent = game.Workspace[p] end end |
|
|
| Report Abuse |
|
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
|
| 25 Jan 2014 10:12 AM |
@Waz
Does it find a Tool named Tool or does it find the classname?
Because it is not working. |
|
|
| Report Abuse |
|
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
| |
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
|
| 25 Jan 2014 10:24 AM |
Nobody helpful today?
@Waz thanks but it didn't work though |
|
|
| Report Abuse |
|
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
|
| 25 Jan 2014 10:31 AM |
| you got to be kidding me... |
|
|
| Report Abuse |
|
|
|
| 25 Jan 2014 10:44 AM |
p = script.Parent.Parent.Player.Value --Why not just use a object value
for _, Object in pairs (Game.Players.LocalPlayer.Character:GetChildren()) do --Might wanna make sure it has children if Object:IsA("Tool") then q:Clone().Parent = game.Workspace[p] end end |
|
|
| Report Abuse |
|
|
|
| 25 Jan 2014 10:45 AM |
Make sure it has a character* Also if that still doesn't work its a problem with your setup Output? |
|
|
| Report Abuse |
|
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
|
| 25 Jan 2014 11:04 AM |
Output is(when i pasted it in command bar):
12:02:25.455 - p = script.Parent.Parent.Player.Value
for _, Object in pai:1: attempt to index global 'script' (a nil value)
But there is no output itself when i click it. It doesn't add the value though and here is the script where it adds the value:
p = script.Parent.Text f = script.Parent.Parent
script.Parent.MouseButton1Down:connect(function(c) f.Visible = false f.Parent.Frame1.Visible = true f.Parent.Frame1.Player.Value = p end)
Here is the script of the playerlist:
sg = "List" root = "TextButton"
game.Players.PlayerAdded:connect(function(p) local f = game.Lighting:findFirstChild(sg) and game.Lighting[sg]:findFirstChild("Frame") if f then for i, v in pairs(f:children()) do if v.Name:sub(1, #root):lower() == root:lower() then if v.Text == "" then v.Text = p.Name for _, e in pairs(game.Players:GetPlayers()) do e.PlayerGui[sg][f.Name][v.Name].Text = p.Name end break end end end end end)
game.Players.PlayerRemoving:connect(function(p) local f = game.Lighting:findFirstChild(sg) and game.Lighting[sg]:findFirstChild("Frame") if f then for i, v in pairs(f:children()) do if v.Name:sub(1, #root):lower() == root:lower() then if v.Text == p.Name then v.Text = "" for _, e in pairs(game.Players:GetPlayers()) do e.PlayerGui[sg][f.Name][v.Name].Text = "" end break end end end end end)
|
|
|
| Report Abuse |
|
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
| |
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
| |
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
| |
|
|
| 25 Jan 2014 11:53 AM |
q:Clone() q.Parent = game.Workspace[p]
You don't just clone, then parent. |
|
|
| Report Abuse |
|
|
DailyTime
|
  |
| Joined: 09 Nov 2013 |
| Total Posts: 285 |
|
| |
|
|
| 25 Jan 2014 01:00 PM |
m:clone().Parent = Workspace -- EXAMPLE
^^ that is perfectly acceptable. ^^
#nerdsunited |
|
|
| Report Abuse |
|
|
|
| 25 Jan 2014 03:18 PM |
"Command bar" No duh it errored the command bar has no script.Parent |
|
|
| Report Abuse |
|
|