|
| 28 Feb 2014 06:05 PM |
how can I get a player's username from a player ID to grant them access to something? this is the most efficient thing I can come up with:
for i,v in pairs(game.Players:GetChildren()) do if v.userId == receiptInfo.PlayerId then playerUsername = v.Name grantAccessToSomething(playerUsername) end end |
|
|
| Report Abuse |
|
Am4uryXp
|
  |
| Joined: 04 Sep 2011 |
| Total Posts: 20550 |
|
|
| 28 Feb 2014 06:07 PM |
its not a function
no need to put ''end'' |
|
|
| Report Abuse |
|
|
| 28 Feb 2014 06:08 PM |
it's a loop yes, there is a need to put an end. |
|
|
| Report Abuse |
|