Existence_YT

[RSP] Making a Loading Screen - LoadingClient

Mar 7th, 2021
840
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local UI = script.Parent
  2. local MainFrame = UI.MainFrame
  3. local Bar = MainFrame.BarHolder.Bar
  4.  
  5. UI.Parent = game.Players.LocalPlayer.PlayerGui
  6. game.ReplicatedFirst:RemoveDefaultLoadingScreen()
  7. game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.All, false)
  8. local objects = game:GetDescendants()
  9. local totalObjects = #objects
  10. for i, v in pairs(objects) do
  11.     Bar.Size = UDim2.new(i/totalObjects, 0, 1, 0)
  12.     game:GetService("ContentProvider"):PreloadAsync({v})
  13. end
  14. game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.All, true)
  15. game.Debris:AddItem(script.Parent, 0.6)
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×