Like @SOTR654 said MouseButton1Click doesn’t give anything so instead use this script
local player = game:GetService("Players").LocalPlayer
script.Parent.MouseButton1Click:Connect(function()
local stats = player:WaitForChild("Stats")
print(stats.Exp)
end)
It does not return a player, and second is you cannot print an instance say instance.Value for values
Use this script:
local player = game.Players.LocalPlayer
script.Parent.MouseButton1Click:Connect(function()
if player then
local stats = player.Stats
print(stats.Exp.Value)
end
end)
Make sure that’s LocalScript.
Use instead print(stats.exp.Value)
Because MouseButton1Click doesn’t return the player.
Delete the player from function.
Use instead local player = game.Players.LocalPlayer