(No errors) Loading screen stuck at 78.29046898638427%!

There are no errors

local RepFirst = game:GetService('ReplicatedFirst'); RepFirst:RemoveDefaultLoadingScreen()
local RepStorage = game:GetService('ReplicatedStorage')
local ContentProvider = game:GetService('ContentProvider')
local StarterGUI = game:GetService('StarterGui')

local Assets = game:GetDescendants()

local GUI = script.LoadingUI:Clone()

local Player = game.Players.LocalPlayer
local PlayerGui = Player:WaitForChild("PlayerGui")
GUI.Parent = PlayerGui
PlayerGui:SetTopbarTransparency(1)
StarterGUI:SetCoreGuiEnabled(Enum.CoreGuiType.Chat, false)
StarterGUI:SetCoreGuiEnabled(Enum.CoreGuiType.PlayerList, false)
StarterGUI:SetCoreGuiEnabled(Enum.CoreGuiType.EmotesMenu, false)
StarterGUI:SetCoreGuiEnabled(Enum.CoreGuiType.PlayerList, false)
StarterGUI:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, false)
if not game:IsLoaded() then game.Loaded:Wait() end


for i =1, #Assets do
	local Asset = Assets[i]

	ContentProvider:PreloadAsync(
		{Asset},
		function(asset: string,assetFetchStatus: Enum.AssetFetchStatus)
			print("Loading:",asset)
			print("Status:",assetFetchStatus.Name)
		end
	)
	
	local progress = i/#Assets
	GUI.Background.Loading.Progress.Size = UDim2.new(progress,0 , 1,0)
end

StarterGUI:SetCoreGuiEnabled(Enum.CoreGuiType.Chat, true)
StarterGUI:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, true)
GUI:Destroy()

Made the loading script using this:

Any help would be very much appriecated :smiley:

3 Likes

First off, don’t load the entire game.
Second, u can just do

StarterGUI:SetCoreGuiEnabled(Enum.CoreGuiType.All, false)

and save time

Now for the loading being stuck it might be one of your assets struggling to load.

1 Like

Ok how would i know which one? :sweat_smile:

just make it print the assets each time its pre loading and try to find it.

1 Like

Why would i not load the entire game :sweat_smile:

How would i know which asset it preloading stopped?

for i =1, #Assets do
	local Asset = Assets[i]

	ContentProvider:PreloadAsync(
		{Asset},
		function(asset: string,assetFetchStatus: Enum.AssetFetchStatus)
			--print("Loading:",asset)
			--print("Status:",assetFetchStatus.Name)
		end
	)
	
	print(Asset)
	local progress = i/#Assets
	GUI.Background.Loading.Progress.Size = UDim2.new(progress,0 , 1,0)
end

the last asset is “Players”

tested in roblox no change

still players :rage:

if the asset is players, skip it by not preloading it…
it’s not that hard

1 Like

Why would you preload the entire game and not just workspace? (still a bad idea to preload the entire workspace too)

2 Likes

i didnt knew i just followed the tutorial :sad: :rage: :smiling_imp:

works thank you so much for the help :smiling_imp:

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.