I've got a script that kicks players if they aren't a member of a certain group, it does work, but it doesn't update. For instance, if a player tries to join and they aren't in the group, they will get kicked, but then if they join the group and try to play, it wont allow them in the game unless a new server has started. Any idea why?
local GroupIds = {3038719}
game.Players.PlayerAdded:connect(function(player)
for _,v in pairs(GroupIds) do
if player:IsInGroup(v) then
print("Player is in the group")
return false
else
print("Kicking the player that isnt in the group..")
player:Kick("You are not in the Cybertale Games group! Please join it so that you can play! (Link in desc)")
end
end
end)
Thanks for reading

2 comments
Try the script with line 6 removed.
Does the same thing :c