Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

leaderstats is not a valid member of Player. How to fix??

Asked by 5 years ago
  1. local repStorage = game:GetService("ReplicatedStorage")
  2. local remote = repStorage:FindFirstChild("CoinClick")
  3. local button = script.Parent
  4. local debounce = false
  5. button.MouseButton1Click:Connect(function()
    1. if not debounce then
    2. debounce = true
    3. local playerPoint = game.Players.LocalPlayer.leaderstats.Coins
    4. remote:FireServer(playerPoint)
    5. wait(0.01)
    6. debounce = false
    7. end
  6. end)

I am getting a error and idk how to fix this if anyone knows please help me really need to fix this problem.

  • leaderstats is not a valid member of Player
  • Stack Begin
  • Script 'Players.l3gendrasp.PlayerGui.Button.TextButton.LocalScript', Line 11
  • Stack End
0
Please. Put script in special code block. And Roblox Studio can't find stats Diltz_3 75 — 5y
0
what do i do with this l3gendrasp -5 — 5y

Answer this question