Hello! I'm currently trying to figure out this problem i am having but i still can't find any solutions, and i'm wondering if anybody could help me figure this out.
So the problem is i wrote a Local script to clone the Classic Roblox Sword to the player's backpack, it clones perfectly fine but when i click nothing happens.
Here is the full script:
local character = script.Parent
local humanoid = character:WaitForChild("Humanoid")
local PG = game:GetService('Players').LocalPlayer:WaitForChild('PlayerGui')
local Player = game:GetService('Players').LocalPlayer
local RP = game:GetService('ReplicatedStorage')
function onSeated(isSeated, seat)
if isSeated then
PG.ScreenGui.Frame.Visible = true
PG.ScreenGui.Frame.Frame.Size = UDim2.new(0, 0, 1, 0)
wait(0.5)
PG.ScreenGui.Frame.Frame.Size = UDim2.new(0, 100, 1, 0)
wait(0.5)
PG.ScreenGui.Frame.Frame.Size = UDim2.new(0, 200, 1, 0)
wait(0.5)
PG.ScreenGui.Frame.Frame.Size = UDim2.new(0, 300, 1, 0)
wait(0.5)
PG.ScreenGui.Frame.Frame.Size = UDim2.new(0, 400, 1, 0)
wait(0.5)
PG.ScreenGui.Frame.Frame.Size = UDim2.new(0, 500, 1, 0)
wait(0.5)
PG.ScreenGui.Frame.Frame.Size = UDim2.new(0, 600, 1, 0)
if PG.ScreenGui.Frame.Frame.Size == UDim2.new(0, 600, 1, 0)
then
humanoid.Jump = true
wait(0.1)
character.Head.CFrame = CFrame.new(workspace.EXIT.Position)
-- This is the cloning script --
local tool = RP.ClassicSword:Clone()
tool.Parent = Player:WaitForChild("Backpack")
-----------------------------------------------------------------
end
else
PG.ScreenGui.Frame.Visible = false
end
end
humanoid.Seated:Connect(onSeated)
(I'm pretty new at scripting lol don't judge.)
Anybody think they can help me?

1 comment
Your way better than me lol