I am new to scripting and I need player points. Please can somebody help me make a PP script? (So like a marketplace GUI)
Let's get something right here. First off, Player Points are generated when ROBUX are spent on Dev. Products or Game Passes. Each Game has a budget. To award even a single point, you need to make sure you have a point available in the game...
The service is called PointsService
and we use :GetAwardablePoints()
to check how much we have
print(game:GetService("PointsService"):GetAwardablePoints() --Output = How many points available
To award them, we use :AwardPoints(userId,Amount)
. In the first section of the bracket, we state the userId, in the second section, we state the number of points we want to give away.
game:GetService("PointsService"):AwardPoints(25698326,1) --We give 1 Point to the userId 25698326
You can also get the number of Points a player has from your game or ALL Games.
To check through your game only, use :GetGamePointBalance(userId)
All we need in the brackets is the userId of the player
print(game:GetService("PointsService"):GetGamePointBalance(5896325) --Returns the number of points that user 5896325 has earnt in your game
If you want to check how to get the number of points from ALL Games, use :GetPointBalance(userId)
. Again, we only need the userId of the player
print(game:GetService("PointsService"):GetPointBalance(2358623) --Returns the number of points the player has across ALL ROBLOX games.
NOTE: PLAYER POINTS CAN ONLY WORK ON NORMAL SCRIPTS AND MUST BE IN A LIVE SERVER AND NOT IN STUDIO TO WORK.