Player has joined the game feature help

I want to add a feature to my game that lets every player know when someone has joined the game.

I tried following this YT video ([How to make a Player Joined Chat Message in ROBLOX Studio - YouTube) and put the scripts in the right places and wrote the code exactly the same but when I enter the game nothing pops up in chat telling me I joined the game.

I searched for this topic but couldn’t find anything using the scripts im using.

Here’s the code and screenshots.

(PlayerJoinedScript under ServerScriptService)

local PlayerJoinedEvent = game.ReplicatedStorage.PlayerJoinedEvent

game.Players.Player.Added:Connect(function(Player)
	PlayerJoinedEvent:FireAllClients(Player.Name)
end)

(PlayerJoinedScript under StarterPlayerScripts)

local PlayerJoinedEvent = game.ReplicatedStorage.PlayerJoinedEvent

PlayerJoinedEvent.OnClientEvent:Connect(function(Player)
	game:GetService("StarterGui"):SetCore("ChatMakeSystemMessage", {
		Text = Player.." has joined the game",
		Font = Enum.Font.SourceSansBold,
		TextSize = 24,
		Color = Color3.new(0,1,0)
  })
end)

Event

image

Could someone help me find the bug that’s causing my scripts not to work? I’ve been looking for around 20 minutes now and still don’t know what I did wrong.

1 Like
Text = Player.." has joined the game"

Replace that line with this:

Text = Player.Name.." has joined the game"

Its game.Players.PlayerAdded and not game.Players.Player.Added.

1 Like

Just tried this and when I join the game there’s still not message in chat.

Like @realmile said, Player.Added doesn’t exist, it should be PlayerAdded

Thank you, that was the bug I missed. The scripts now work perfectly.