local Sword = game.ServerStorage:WaitForChild("Tool")
function onAdded(player)
print(player.Name .. " has joined the game! :D")
Sword:Clone()
Sword.Parent = player:WaitForChild("Backpack")
end
game.Players.PlayerAdded:connect(onAdded)
For some reason you cant name it tool, so name it something like Sword or AK47 and also its a good practice to use :WaitForChild, it will yeild(wait/stop) the script until that object is not nil and it will prevent errors, another good practice is using functions, it makes it so you dont half to copy and paste code over and over instead you can just call the function.
1 comment
You are not parenting the cloned tool you are parenting the actual tool so this will only work once, try doing Tool:Clone().Parent = player.Backpack