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

I need help with Player Points please?

Asked by 10 years ago

Example on my game:

Noob buys 1000 cash for 10 ROBUX, the server gets 1 Point. I want noob to automatically get that point when he successfully bought the cash, since 1R$ counts as the point. I can't figure out a working script, even though I checked the caps, spelling etc. Could someone please assist me on this?

0
It makes our life easier if you paste the script somewhere. Bebee2 195 — 10y

1 answer

Log in to vote
0
Answered by
lomo0987 250 Moderation Voter
10 years ago

This might not work correctly depending on how you set it up.

local PointsService = Game:GetService("PointsService") -- Put this at the top of the script where they receive the currency

--PointsService:AwardPoints(user.userId, 1)  <-- Place that after the line of code where they receive the currency. Edit the 1 to how ever many points you want to award them. Also the "user.userId" might be wrong, if you have the player defined with the function, replace 'user' with however the player is defined.

I believe this should work, if not I am sure someone will fix it.

0
Thanks. I will wait to see if another person comes up with an answer, I can then decide the proper answer. fahmisack123 385 — 10y
0
You should see if that works first. lomo0987 250 — 10y
0
I got replies on the ROBLOX Forum saying "user is undefined" So I'm trying to get this thing fixed. I'll tell you the fixed script through a PM if you want. fahmisack123 385 — 10y
Ad

Answer this question