Hello. I am making a script that checks to see if you have a gamePass and if you do the NumberValue's(which is the parent of this LOCAL SCRIPT) changes to 3.

game.Players.PlayerAdded:connect(function(player)
local pass = 182358984

function Auth(player)
	return game:GetService('GamePassService'):PlayerHasPass(player.userId, pass)
end

if Auth() then -- I need this here so that it doesn't take another 25 seconds for it to work
	script.Parent.Value = 3
else
	script.Parent.Value = 1
end

while wait(25) do
	if Auth() then
		script.Parent.Value = 3
	else
		script.Parent.Value = 1
	end
end
end)

The value doesn't change and there are no errors in the output. Thanks for the help. :D