So I need ways of getting LocalPlayer in a cloned Server-Side Script. I originally intended on using
game.Players.PlayerAdded:connect(function(player)
but because it's cloned, PlayerAdded doesnt seem to function correctly. Any other ways of getting the LocalPlayer on a server-side script?
For context, and if it helps:
game.Players.PlayerAdded:connect(function(player)
script.Parent.Touched:connect(function(hit)
if hit.Parent.Name == "Pickaxe" then
player.Backpack.Copper.Value = player.Backpack.Copper.Value + 1
script.Parent:Destroy()
end
end)
end)
Any help is much appreciated as always.

3 comments
ServerScripts aren't associated to a Client (player) in any way as they work on the Server. Can you tell me a bit about why you're cloning a ServerScript and I might be able to point you in the right direction
So it's a mining game, and there's a randomizer picker script that clones a certain ore if it is chosen. The above script is in all the ores.
You can't. The script doesn't know what player you want. It does not read your mind.