I am trying to make a hide and seek game. I am trying to make it so when the seeker leaves the game or gets disconnected, then the round is over and the contestants is 0. But for some reason when I add the hashtag its underlined red. Here is the code:

function playerLeaving(player)
		if player.Name == seeker.Name then
			#contestants = 0
			end
		end
	end
	
	game.Players.PlayerRemoving:Connect(playerLeaving)

2 comments

0

is there a contestants variable anywhere?

0

Yes, but I didn't include the whole script. Here is the link to the same question but with the full script: https://scriptinghelpers.org/questions/122135/why-is-the-in-contestants-underlined-red