Event only fires once

I have an event in the player.CharacterAppearanceLoaded function.

It only fires once. I cannot figure out why.

SERVER:

local players = game:GetService("Players")
local event = script:WaitForChild("Event").Value


game.Players.PlayerAdded:Connect(function(player)

	print("Player Added")




	player.CharacterAdded:Connect(function(character)

		print("Character Added")





		character.Humanoid.Died:Connect(function()

			print("Humanoid Died")

		end)
	end)




	player.CharacterAppearanceLoaded:Connect(function(character)

		print("Apperance Loaded")
		
		event:FireClient(player)

	end)
end)




players.PlayerRemoving:Connect(function(player)

	print("Player Removing")

end)

CLIENT:

local event = script:WaitForChild("Event").Value

event.OnClientEvent:Connect(function()
	
	print("Event Received")
	
end)

Does anyone know why?

event once.rbxl (54.9 KB)

Put the appearanceloaded inside CharacterAdded

1 Like

It does work there, but I need it where it is.

1 Like

Why do you need it there, there really isn’t another way

1 Like

Why do you say there no other way?

1 Like

Because the event CharacterAppearenceLoaded only fires once (When the character’s outfit loads). So the Remote you made will only Fire once since the function executes every time the event CharacterAppearenceLoaded is fired (You connected the function to the event), and it only fires one time. And the function Fires the Remote you made. The method :FireClient also Fires a Remote once. I hope i clarified everything.

Because there isn’t, why exactly do you need it there? The only difference is that it works

1 Like

Just move your LocalScript to StarterPlayerScripts. The StarterCharacterScript probably connects the event after you :FireClient, so it doesn’t recieve it.

@Empereans I have no clue what you’re talking about, .CharacterAppearanceLoaded is a perfectly valid event.

@f8003199martins .CharacterAppearanceLoaded fires every time the character’s appearance loads, not just once.

4 Likes

Yes, I see now.

My LocalScript was not picking up the event because it was deleted when the character died.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.