Heres the code in question:
local collector = workspace.SushiCollector script.Parent.Touched:Connect(function(hit) if hit and hit.Parent and hit.Parent:FindFirstChild("SushiCollector") then local player = game.Players.LocalPlayer local leaderstats = player:FindFirstChild("leaderstats") if leaderstats then local MoneyValue = leaderstats:FindFirstChild("Money") if MoneyValue then MoneyValue = MoneyValue + 5 script.Parent:Destroy() end end end end)
You can use LocalPlayer only in a LocalScripts.
Its giving you that error, because on the server the LocalPlayer value does not exist.
For this to work on server you would have to get the path to the player.