Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Check For Changes In A Raw Paste?

I'm trying to retrieve data from a pastebin I made, and I want it to constantly check if the contents of the paste changes and if it does print out the contents once!

while wait() do
	print(game:HttpGet('https://pastebin.com/raw/rBZ3eV3v')) -- only print if the contents inside the paste changes.
end

1 answer

Try repeatedly changing a stringvalue, then waiting for that string value to change using a .Changed event. This may cause lag, however. (Not sure)

local stringvalue = Instance.new("StringValue")
delay(.1,function()
	while wait() do
		stringvalue.Value = game:GetService("HttpService"):GetAsync('https://pastebin.com/raw/rBZ3eV3v')
	end
end)
stringvalue.Changed:Connect(function(newValue)
	print(newValue)
end)

-- below is a test
wait(3)

stringvalue.Value = "hello"

This discussion is preserved as it was. New answers, comments, and votes are closed.