IdentifiersPlus
Introduction
Usernames are a big problem when it comes to trying to ban, kick, or message a player. Which is why this API uses unique numbers to assign each player, and it’s impossible to get the same ID as someone else while in the same server which makes it great for moderation.
You don’t need to memorize their username, you just need to memorize a 1-4 digit number.
For example, It can if you’re manually trying to ban someone and their name is something like IlIlIlIlIlIlIlIlIl or X3834Sjkewj. Or even if someone tries to trick you by naming themselves allAbcido3 or otherskjsdf.
All you need to read is IlIlIlIlIlIlIlIlIl [432] which you can use to find them easily without having to try to type their username. Difference between this and Roblox UserIds are that Roblox UserIds look like this: 1370939403 which just makes it almost impossible to remember.
Getting Started
IdentifiersPlus is really easy to use, and there’s not many functions to have to learn.
To get started, all you need to do is drag the ModuleScript into your ReplicatedStorage, and require it from a script.
Here are some features which you could use.
Find a player’s ID
This code will get the ID of the player and print it into the output.
local replicatedStorage = game:GetService("ReplicatedStorage")
local identifiersPlus = require(replicatedStorage.IdentifiersPlus)
local id = identifiersPlus.GetPlayerID(game.Players.LocalPlayer)
print(id)
Create and remove a PlayerID for a player
This code creates/removes a new ID for a player (remove the pre-made script inside the ModuleScript before doing this.)
local replicatedStorage = game:GetService("ReplicatedStorage")
local identifiersPlus = require(replicatedStorage.IdentifiersPlus)
local id = identifiersPlus.AddPlayer(game.Players.LocalPlayer)
local replicatedStorage = game:GetService("ReplicatedStorage")
local identifiersPlus = require(replicatedStorage.IdentifiersPlus)
local id = identifiersPlus.RemovePlayer(game.Players.LocalPlayer)
Find a player / ID from their username
This code will find the player / ID from a string and return it. This works even if you don’t put in the full username. The multiple variable is used as a way to check if there’s multiple players with that name, returns true or false. If there’s multiple players with that name it returns a random player / player’s ID.
local replicatedStorage = game:GetService("ReplicatedStorage")
local identifiersPlus = require(replicatedStorage.IdentifiersPlus)
local plr, multiple = indentifiersPlus.FindPlayerFromString("rix") -- searches for players starting with "rixx"
if multiple then
print("Multiple players starting with the same start.")
end
print(plr)
local replicatedStorage = game:GetService("ReplicatedStorage")
local identifiersPlus = require(replicatedStorage.IdentifiersPlus)
local id, multiple = indentifiersPlus.FindIDFromString("rix") -- searches for players starting with "rixx"
if multiple then
print("Multiple players starting with the same start.")
end
print(id)
You could also create a script to display their ID above their heads so it’s easy to see other’s IDs.
Here’s an example:
local PlayerIDs = require(replicatedStorage.IdentifiersPlus)
local plrs = game:GetService("Players")
local tag = script.ID
plrs.PlayerAdded:Connect(function(plr)
plr.CharacterAppearanceLoaded:Connect(function(char)
local plrID = PlayerIDs.GetPlayerID(plr)
local newTag = tag:Clone()
newTag.PlayerName.Text = plr.Name.." ["..plrID.."]"
newTag.Parent = char:WaitForChild("HumanoidRootPart")
end)
end)
Files:
IdentifiersPlus.rbxm (1.8 KB)
Hope you like it! This is my first resource, sorry if some things are confusing.