|
| 02 Feb 2014 03:35 PM |
Okay. This is the script in the GUI. button = script.Parent
function clicked() torso = button.Parent.Parent.Parent.Character.Torso destination = script.Parent.Configuration.TeleportDestination.Value torso.CFrame = CFrame.new(destination,torso.CFrame.lookVector) local swordModel = game:GetService("InsertService"):LoadAsset(125013769) swordModel:Clone().Parent = player.Backpack end
script.Parent.MouseButton1Click:connect(function(a) clicked() end) What am I doing wrong? It isn't giving you a sword. |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2014 04:09 PM |
u failed on clone. you didnt told what player is
player = button.Parent.Parent.Parent SW = swordModel:Clone() SW.Parent = player.Backpack |
|
|
| Report Abuse |
|
|
| |
|
|
| 02 Feb 2014 05:46 PM |
is becouse you got copied the part i puted to you tu replace the part of your script, the actual script is here:
button = script.Parent
function clicked() torso = button.Parent.Parent.Parent.Character.Torso destination = script.Parent.Configuration.TeleportDestination.Value torso.CFrame = CFrame.new(destination,torso.CFrame.lookVector) local swordModel = game:GetService("InsertService"):LoadAsset(125013769) player = button.Parent.Parent.Parent SW = swordModel:Clone() SW.Parent = player.Backpack end
script.Parent.MouseButton1Click:connect(function(a) clicked() end) |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2014 07:36 PM |
| Sword still doesn't appear in my backpack. |
|
|
| Report Abuse |
|
|
|
| 02 Feb 2014 07:36 PM |
| And yes I added that little chunk of code into my script, so it was exactly how your script is above. |
|
|
| Report Abuse |
|
|