local function Y(Y)clonedLoadingScreen.Frame.Pattern:TweenPosition(UDim2.new(1,0,.5,0),"\079\117\116","\076\105\110\101\097\114",20,false,Y)end local function k(z)if z==Enum.TweenStatus.Completed then clonedLoadingScreen.Frame.Pattern.Position=UDim2.new(0,0,.5,0)Y(k)end end Y(k)skipButton.MouseButton1Down:Connect(function()hideLoadingScreen()end)frame.Visible=true local z=game:GetDescendants()local o=os.clock()for Y=1,#z,1 do local k=z[Y]ContentProvider:PreloadAsync({k})loadingPercentage.Text="\076\111\097\100\105\110\103 \101\120\112\101\114\105\101\110\099\101 - "..(Y..("\047"..#z))ResizeBar(Y/#z)end hideLoadingScreen()local g=os.clock()-o print(("\076\111\097\100\105\110\103 \099\111\109\112\108\101\116\101\044 \116\105\109\101\058 \037\046\050\102"):format(g))

local function imageTween(whenTweenCompleted)
	clonedLoadingScreen.Frame.Pattern:TweenPosition(UDim2.new(1, 0, 0.5, 0), "Out", "Linear", 20, false, whenTweenCompleted)
end
local function whenTweenCompleted(state)
	if state == Enum.TweenStatus.Completed then	
		clonedLoadingScreen.Frame.Pattern.Position = UDim2.new(0, 0, 0.5, 0)
		imageTween(whenTweenCompleted)
	end
end
imageTween(whenTweenCompleted)

skipButton.MouseButton1Down:Connect(function()
	hideLoadingScreen()
end)



frame.Visible = true

local Assets = game:GetDescendants()

local startTime = os.clock()

for i = 1, #Assets do
	local asset = Assets[i]
	ContentProvider:PreloadAsync({asset})
	loadingPercentage.Text = "Loading experience - " ..i.. "/" ..#Assets
	ResizeBar(i/#Assets)
end

hideLoadingScreen()

local deltaTime = os.clock() - startTime
print(("Loading complete, time: %.2f"):format(deltaTime))
