Firing :FireClient() Too Early

I’m creating a round based game. When I start the round I set all the player’s spawn points, then use :LoadCharacter() to spawn them in. The problem with this method is that I have local scripts in the StarterCharacterScripts that listen for the .OnClientEvent, but it loads after the server fires the remote.

What would be the best set up for this? Should I have the scripts in the StarterPlayer and update a character variable when the character respawns? Should I fire a remote event telling the server that the local script has loaded?

Don’t have local scripts in StarterCharacterScripts that listen for the firing of a RemoteEvent, put them in StarterPlayerScripts. If you just store a reference to the LocalPlayer and fetch the Character when you need it, you won’t need a variable holding a reference to the character.

1 Like

Have a LocalScript in StarterPlayer and use game.Players.LocalPlayer.CharacterAdded to update your character variable.