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

Can Anyone help me with Player Id?

Asked by 10 years ago

How do you know a players id, and how do you get the last 3 numbers (always different) Can anyone help me ? Thanks. I did not put the code here because im not sure how to do it in itself if anyone can give me hints or anything please help?

2 answers

Log in to vote
1
Answered by
TofuBytes 500 Moderation Voter
10 years ago

There are many ways you can retrieve the player's userId. Here's a short script that prints the userId when they join the server. Also to note, it is impossible to get just the last three numbers of a userId.

game.Players.PlayerAdded:connect(function(player) --When a player joins they create this function called 'player'
      print("User ID: " ..player.userId) --We indicated the userId with '.userId' inside 'player'.
end)
0
Thanks! Helped a lot! PlatinumLocks 50 — 10y
Ad
Log in to vote
-1
Answered by 10 years ago

You can find a players ID in address bar at the top of a web page.

Example: if my profile is "www.roblox.com/User.aspx?ID=40375902" then my player ID is "40375902"

~topgeartrain

Answer this question