So here's an example of what I made
local p = game.Players.NumPlayers
while true do
if p > 0 then
--This is where my code is
end
wait()
end
But instead of going through an entire loop it stops when the player count is at 0 and never checks if it changed.
