Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Linked sword not being added to inventory?

Asked by 6 years ago
Edited 6 years ago

I have a gui with a slot and inside the slot is an imagge button and inside the button is a script and inside the script is a LinkedSword

Im trying to get it to where you click the button, it takes the sword out of the script and puts it in your inventory. But i cant.

here is my script

function onClick()
    local LinkedSword = script.LinkedSword:Clone()
    LinkedSword.Parent = game.Players.LocalPlayer.Backpack
end)
script.Parent.MouseButton1Click:connect(function()
0
It appears you have a typo on line 2 (you wrote LinkedSwprd instead of LinkedSword when cloning it). TheDeadlyPanther 2460 — 6y
0
fixed, still doesent work AndrewTheRoblox -6 — 6y
0
is this a localscript? rareheaddress 74 — 6y

Answer this question