I was having some fun making a quick game, when I came across a problem, I can't award player points to players when they touch a part. It is supposed to award them 1 Player Point. Everything else works except the Player Point part. (I tested the script without the player point part, it worked fine)
User = game.Players:GetPlayers()
bux2 = game.Lighting.BUX:Clone()
script.Parent.Touched:connect(function()
local PointsService = game:GetService("PointsService")
PointsService:AwardPoints(User.userId, 1)
game.Workspace.ROBUX.Value = game.Workspace.ROBUX.Value + 1
bux2.Parent = workspace
script.Parent:Destroy()
end)
This is a one player game so the variable won't give it to thousands of people

5 comments
Got this from this output: "Processing PointsService:AwardPoints error: HTTP 403 (HTTP/1.1 403 Forbidden). userId = 37515669" It's in test mode so, it should be working.
You answered it better than I did (mine was short because apparently this site hates mobile devices). But you removed line 6 of his code.
Grenade, you can only award points from roblox game servers
Yeah, that's why I said it worked. Because it was at the end of the script.
And it since it is at the end of the script, that means nothing above was wrong, because it was the only thing in the output.