My current code is not working as it is supposed to, its purpose is fairly self-explanatory if you look at the code.
local ContentProvider = game:GetService("ContentProvider"):Preload("http://www.roblox.com/asset/?id=144904058") function WaitForLoad() repeat wait(1.5) until (ContentProvider.RequestQueueSize == 0) script.Parent.Text = "Access Mainframe" end
It seems as if your only problem is that you did not call the function. In order for the function to run you will need to call it like so:
local ContentProvider = game:GetService("ContentProvider"):Preload("http://www.roblox.com/asset/?id=144904058") function WaitForLoad() repeat wait(1.5) until (ContentProvider.RequestQueueSize == 0) script.Parent.Text = "Access Mainframe" end WaitForLoad() -- this calls the function when the script begins