Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local partsWithId = {}
- local awaitRef = {}
- local root = {
- ID = 0;
- Type = "ScreenGui";
- Properties = {
- Name = "LoadScreen";
- ResetOnSpawn = false;
- };
- Children = {
- {
- ID = 1;
- Type = "Frame";
- Properties = {
- Name = "BackGround";
- Size = UDim2.new(1,0,1,0);
- ZIndex = 10;
- BorderSizePixel = 0;
- BackgroundColor3 = Color3.new(3/85,16/255,32/255);
- };
- Children = {
- {
- ID = 2;
- Type = "TextLabel";
- Properties = {
- FontSize = Enum.FontSize.Size60;
- BackgroundTransparency = 1;
- TextColor3 = Color3.new(83/255,142/255,254/255);
- TextSize = 60;
- Text = "Loading Skoot.XX...";
- TextWrapped = true;
- Size = UDim2.new(0,700,0,100);
- AnchorPoint = Vector2.new(0.5,1);
- Font = Enum.Font.Cartoon;
- Name = "Text";
- Position = UDim2.new(0.5,0,0.99000000953674,0);
- BackgroundColor3 = Color3.new(1,1,1);
- ZIndex = 10;
- TextScaled = true;
- TextWrap = true;
- };
- Children = {
- {
- ID = 3;
- Type = "LocalScript";
- Properties = {};
- Children = {};
- };
- };
- };
- {
- ID = 4;
- Type = "ImageLabel";
- Properties = {
- ImageColor3 = Color3.new(83/255,142/255,254/255);
- ScaleType = Enum.ScaleType.Fit;
- BackgroundTransparency = 1;
- AnchorPoint = Vector2.new(0.5,0.5);
- Image = "rbxassetid://1764649752";
- Name = "LoadIcon";
- Position = UDim2.new(0.5,0,0.40000000596046,0);
- Size = UDim2.new(0.40000000596046,0,0.40000000596046,0);
- ZIndex = 10;
- BorderSizePixel = 0;
- BackgroundColor3 = Color3.new(3/85,16/255,32/255);
- };
- Children = {
- {
- ID = 5;
- Type = "LocalScript";
- Properties = {};
- Children = {};
- };
- };
- };
- };
- };
- {
- ID = 6;
- Type = "LocalScript";
- Properties = {
- Name = "MainScript";
- };
- Children = {};
- };
- {
- ID = 7;
- Type = "Frame";
- Properties = {
- Name = "TopBar";
- Size = UDim2.new(1,0,0,-40);
- ZIndex = 10;
- BorderSizePixel = 0;
- BackgroundColor3 = Color3.new(3/85,16/255,32/255);
- };
- Children = {};
- };
- };
- };
- local function Scan(item, parent)
- local obj = Instance.new(item.Type)
- if (item.ID) then
- local awaiting = awaitRef[item.ID]
- if (awaiting) then
- awaiting[1][awaiting[2]] = obj
- awaitRef[item.ID] = nil
- else
- partsWithId[item.ID] = obj
- end
- end
- for p,v in pairs(item.Properties) do
- if (type(v) == "string") then
- local id = tonumber(v:match("^_R:(%w+)_$"))
- if (id) then
- if (partsWithId[id]) then
- v = partsWithId[id]
- else
- awaitRef[id] = {obj, p}
- v = nil
- end
- end
- end
- obj[p] = v
- end
- for _,c in pairs(item.Children) do
- Scan(c, obj)
- end
- obj.Parent = parent
- return obj
- end
- return function() return Scan(root, nil) end
Advertisement
Add Comment
Please, Sign In to add comment