Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How to make a player with Instance.new("Player") in Roblox?

Hey there! Sorry to trouble you, but I have a question: How do you make a player with 'Instance.new("Player")' in Roblox? I am trying to parent it to the Players thingy to make it show up on the leaderboard to make it look like there is more players than there actually is. But, this happens: I have tried this:

local Player1 = Instance.new("Player")
Player1.Name = "Player1"
Player1.Parent = game.Players

but it says this:

The current identity (2) cannot create a Player (lacking permission 4)

Please help, and thank you.

2 comments

0

Thank you again, for any help!

0

you cant make a player instance

1 answer

Well, I believe you cannot create a Player Instance , meaning you can't just write Instance.new("Player") as it is lacking the permission to do so The current identity (2) cannot create a Player (lacking permission 4)

I believe what you wanted to make is a Character and not a Player.

In Roblox studio, if you wanted to make a Character , go to Plugins and you should see something called Create Rig . Click on that and boom that's your character. No need to use a script to create it.

But if you wanted to use a script to create it, insert a rig and put it in server storage and name it anything you like in this case i assume you're naming it "NPC", but you can name it however you like

local npc = game.ServerStorage.NPC --change it to your rig's name
local clonednpc = npc:Clone()
clonednpc.Parent = workspace

1 comment

0

I appreciate the help, but no, I am not trying to make a Character. I am trying to create a Player, parent it to the game.Players folder, and then make the rig.

This discussion is preserved as it was. New answers, comments, and votes are closed.