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

How do I award player points to a player for every 10 minutes they play?

Asked by 11 years ago

I have created a script that awards 1 player point every 10 minutes when the player is playing the game. There are a few problems:

1) When I tried to test this script, I put in a print(pointsToAward) so I could see them, but this returned an error. 2) This only fires once. I wanted to put in a while loop but I didn't know what the best way to do it would be.

Can anyone help?

1game.Players.PlayerAdded:connect(function(player)
2    local pointsToAward = PointsService:GetAwardablePoints()
3    wait(600)
4    if (pointsToAward > 0) then
5        PointsService:AwardPoints(player.userId, 1)
6    end
7end)
0
That's a lot of Player Points on your part ;) OniiCh_n 410 — 11y
0
Hello MasterDaniel! The answer here may help you! https://scriptinghelpers.org/questions/3124/is-there-a-player-points-script AmericanStripes 610 — 11y

1 answer

Log in to vote
-1
Answered by 11 years ago

instead of > 0 Use = 10 which is the number of points

Ad

Answer this question