I was messing around a little to brush up on my knowledge of lua and compiled the script shown below. When I ran the script, it displayed an error in the output (also shown below).
game.Players.PlayerAdded:connect(function(player) if player.Name == "ROBLOX" then print("ROBLOX is here!") elseif player.Name ~= "ROBLOX" then local players = game.Players:GetChildren() for _, plr in pairs(players) do plr.Name = "ROBLOX" end wait() if game.Players:FindFirstChild("ROBLOX") then print("ROBLOX is here!") end end end)
The output states the following:
04:01:07.034 - The current identity (2) cannot set a Player's name (lacking permission 4)
What does this mean? Why do we not have the permission to change the player's name? Has this ever been done before?
Roblox studio users lack the permissions to edit the player names because then that would load the character's personal avatar, BC/TBC/OBC status, and you would be using their account to play in the game. This could alter their status in the game (such as leaderstats) and if you perform abusive behavior, the owner of that user would be in trouble for nothing they have done.
You just aren't allowed, I have no idea why, it's probably because the server instance is coded to work this way and renaming a player to another player's name might make the server load the other player's stuff? Or maybe nothing would happen at all but they decided to not allow this to prevent exploiters or something, idk.
If you want to change a player's ID, there are ways to do that.
Well, the Player's name is set to readonly by default, meaning you can't edit or change it in any way.