So before the website fully crashed, I noticed a few games has splash screens like “The data couldn’t be loaded since Datastores are down”. How did the games do this? Any help is appreciated.
local DowntimeService = require(6317978171) -- Or require by using the file path. (Requiring by ID is better for quicker updates.) local Players = game:GetService("Players") -- Example #1: Kicking Players if Datastores are down. Players.PlayerAdded:Connect(function(player) if DowntimeService:GetDatastoreAPIStatus() == "down" then player:Kick("Datastores are currently down. To prevent critical errors we have kicked you. If this issue persits please contact the game owner. =") end end) -- Example #2 Printing latest tests if something is down or not. while true do if DowntimeService:GetSiteStatus() == "down" then warn("Roblox Website is Currently Down! Please be patient while Roblox works on a fix! :)") elseif DowntimeService.GetSiteStatus() == "degraded" then print("Roblox Website is Currently slow! Please be patient while Roblox works on it! :)") elseif DowntimeService:GetSiteStatus() == "up" then print("Roblox website is currently up!") end wait(300) end
The better way to do this instead of relying on a third party tool (not to say using a third party tool is a good second check, but I wouldn’t use it as the only one)
Instead, use pcalls (protected calls) to datastores, and see whether they fail or succeed. If a certain call fails enough times (and you have valid budget, which can be checked), it is safe to assume that the APIs are currently downgraded.
update: this wont work anymore as i think status plus moved