local function f(f)if f and(f.Parent and f.Parent:FindFirstChild("\072\117\109\097\110\111\105\100"))then local F=PlayersService:GetPlayerFromCharacter(f.Parent)if F and not JustTouched[F]then JustTouched[F]=time()if GamePassService:PlayerHasPass(F,GamePassIdObject.Value)then TeleportToOtherSide(F.Character,f)end end end end
-- When a player with the game pass touches the door, teleport them to the other side
local function OnTouched(otherPart)
	if otherPart and otherPart.Parent and otherPart.Parent:FindFirstChild("Humanoid") then
		local player = PlayersService:GetPlayerFromCharacter(otherPart.Parent)
		if player and not JustTouched[player] then
			JustTouched[player] = time()
			if GamePassService:PlayerHasPass(player, GamePassIdObject.Value) then
				TeleportToOtherSide(player.Character, otherPart)
			end
		end
	end
end
