Hiya all. I have a script here that is placed inside a part called PointsAwarder and when the part is stepped on, it awards points. I can't get it to work, and I was hoping someone could help out. This is the current script that is placed inside the part
Points_To_Give = 100 -- Player Points that will be given.
script.Parent.Touched:connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") and game:GetService("PointsService"):GetAwardablePoints() > Points_To_Give then
local P = game.Players:GetPlayerFromCharacter(hit.Parent)
game:GetService("PointsService"):AwardPoints(P.userId, Points_To_Give)
end
end
end)
Output: 14:13:18.518 - Workspace.PointsAwarder.Script:9: ')' expected (to close '(' at line 3) near 'end'
Thanks!
