How can i actually change the StarterPlayer folder for diferent players in real time?
I’m making a fighting game and i need to change the stuff such as StarterCharacter and starterplayer (which should be different for each character) before the match starts so they spawn with those.

For example one of the character have different footstep sounds, and since roblox uses a starterplayerscript called “RbxCharacterSounds” i need to have the starterplayer folder different for the player that picks that specific character, how would i be able to acheive this?
local players = game:GetService("Players")
players.PlayerAdded:Connect(function(player)
player.CharacterAdded:Connect(function(character)
if player.Name == "DevSersponge" then
-- do stuff
end
end)
end)
CharacterAdded fires every time a new character is spawned (when you join, die etc.), you can use this and check the name of the player who just had their character spawned to perform specific tasks for that player only.
i know, but the problem is you can’t really instance another starterplayer and changing the stuff on the server would actually change for everyone! (plus character added fires after the player respawns so it would be too late)
No it wouldn’t change for everyone, since you’re checking the name of the player beforehand. Are you trying to give specific players StarterCharacter models?
local players = game:GetService("Players")
local starterPlayer = game:GetService("StarterPlayer")
local repStorage = game:GetService("Players")
local starterChar = repStorage:WaitForChild("StarterCharacter")
players.PlayerAdded:Connect(function(player)
if player.Name == "" then --some username
local starterCharClone = starterChar:Clone()
starterCharClone.Parent = starterPlayer
end
end)
I think you’ve misinterpreted a little what i meant…
Okay so the problem is the following:
I’m not only giving players a startercharacter but also startercharacterscripts and starterplayerscripts, the thing is i have to do it in real time, there’s a character selection screen so by the time they are there their character isn’t defined yet so PlayerAdded wouldn’t really work because it fire as soon as the player joins the game. and yes it would change for everyone if i’d change it on the server even if i am checking for the name since starterplayer folder isn’t individual for every player as confirmed here:

this picture has been taken on the server sided studio.
So characteradded wont work because character is already there when it fires and playeradded wont work because that’s for when the player joins the game.
The idea is after everyone picks a character they’ll spawn with their choosen characters when the match begins and their respective characterscripts and playerscripts.
I don’t really know a solution for it unless changing starterplayer content on client replicates to the server for some reason and it isn’t documented on their api page.
Edit:i found a solution already.
1 Like
I thought you were just giving tools, accessories etc., which would have worked fine on a server script, since the backpack/character is exclusive to each player, but the 2nd script I provided would have to be a local script for it to work, yes.
and yes it would change for everyone if i’d change it on the server even if i am checking for the name
Hence this is a false statement.
i don’t undesrtand how what i said is a false statement considering changing stuff on the server does change for everyone as comprovated on the picture i sent as server replicates to all clients, here’s an example:
1st of all your script wouldn’t work client sidedly
Here’s a pic of a startercharacter added to starterplayer via client
as you can see my character didn’t change at all! (yes i respawned myself)
Of course again, empty on the server (obviously since changed via local scripts)

Now if it’s done via the server:
(client pic)
As you can see via the server it works and also changes for all clients (everyone) which is undesired, i am really trying not to delay every character spawn because as i can see now apparently i’d have to spawn everyone 1 by 1 as i change the starterplayer contents for every character spawn which wouldn’t really be nice.
2nd. on your script you forgot to remove old startercharacters on the starterplayer folder so it would have more than one if more than one player joined the game
3rd. backpack and character are exclusive to each player but not the StarterCharacter on the StarterPlayer folder, its global for everyone.
local players = game:GetService("Players")
players.PlayerAdded:Connect(function(player)
player.CharacterAdded:Connect(function(character)
if player.Name == "DevSersponge" then
local backpack = player:WaitForChild("Backpack")
local tool = Instance.new("Tool")
tool.Parent = backpack
-- do stuff
end
end)
end)
Run this in a server script, tell me if the other players receive a tool.