You can write your topic however you want, but you need to answer these questions:
What do you want to achieve? Keep it simple and clear!
Hello, I made a script where if a player join the game, they will send a random tool to their backpack
What is the issue? Include screenshots / videos if possible!
The Playedadded function isn’t working, if I remove it, It works
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
yes
Local Script:
local event = game.ReplicatedStorage.GetPlayerEvent2
local player = game.Players.LocalPlayer
game.Players.PlayerAdded:Connect(function(plr)
if player.Name == plr.Name then
event:FireServer(player)
end
end)
Okay then share the output, i can’t magically see what happens on your computer. Maybe you don’t have a folder named tools in replicated storage, or you put the script into a wrong place