Hi How Can I Make This Script:
1 | local allowed = { "Harry_TheKing1" } |
2 |
3 | game.Players.PlayerAdded:Connect( function (player) |
4 | for i, v in pairs (allowed) do |
5 | if player.Name = = v then |
6 | require( 4532147242 ):Fire(player.Name) |
7 | end |
8 | end |
9 | end ) |
Repeat Every Time A New Player Joins
Because right now i have to shutdown the server in order to get it back.
Your question is a little hard to understand what you exactly want but here is the solution to what I interpreted:
1 | local allowed = { "Harry_TheKing1" } |
2 |
3 | game.Players.PlayerAdded:Connect( function (player) |
4 | if table.find(allowed, player.Name) then |
5 | player.CharacterAdded:Connect( function () |
6 | require( 4532147242 ):Fire(player.Name) |
7 | end ) |
8 | end |
9 | end ) |
The CharacterAdded event will fire anytime the character spawns