Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Create ScreenGui
- local screenGui = Instance.new("ScreenGui")
- screenGui.IgnoreGuiInset = true -- Make sure it fits the screen exactly
- screenGui.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui")
- -- Create black background that will fade with the text
- local background = Instance.new("Frame")
- background.Size = UDim2.new(1, 0, 1, 0) -- Fullscreen
- background.Position = UDim2.new(0, 0, 0, 0)
- background.BackgroundColor3 = Color3.new(0, 0, 0) -- Black color
- background.BackgroundTransparency = 1 -- Start fully transparent
- background.Parent = screenGui
- -- Create TextLabel for Loading...
- local loadingLabel = Instance.new("TextLabel")
- loadingLabel.Size = UDim2.new(0.3, 0, 0.1, 0)
- loadingLabel.Position = UDim2.new(0.35, 0, 0.45, 0)
- loadingLabel.BackgroundTransparency = 1
- loadingLabel.Text = "Loading..."
- loadingLabel.TextColor3 = Color3.new(1, 1, 1) -- White text
- loadingLabel.TextTransparency = 1 -- Start fully transparent
- loadingLabel.Font = Enum.Font.GothamSemibold -- Closest match to Windows 11 font
- loadingLabel.TextScaled = true
- loadingLabel.Parent = screenGui
- -- Create ParticleEmitter for snow-like particles
- local particleEmitter = Instance.new("ParticleEmitter")
- particleEmitter.Parent = background
- particleEmitter.Texture = "rbxassetid://1183005672" -- Snow particle texture (replaceable)
- particleEmitter.Size = NumberSequence.new(0.1, 0.2)
- particleEmitter.Color = ColorSequence.new(Color3.new(1, 1, 1)) -- White particles
- particleEmitter.Transparency = NumberSequence.new(0.3, 1) -- Fade out particles as they fall
- particleEmitter.Lifetime = NumberRange.new(2, 4)
- particleEmitter.Rate = 50
- particleEmitter.VelocitySpread = 180 -- Spread of snow-like particles
- particleEmitter.Speed = NumberRange.new(1, 2)
- particleEmitter.Acceleration = Vector3.new(0, -10, 0) -- Falling down effect
- particleEmitter.Enabled = false -- Start disabled
- -- Function to fade in and out the text and background
- local function fadeInAndOut()
- -- Enable particles during fade
- particleEmitter.Enabled = true
- -- Fade in background and text
- for i = 1, 0, -0.1 do
- background.BackgroundTransparency = i
- loadingLabel.TextTransparency = i
- wait(0.05) -- 0.5s fade-in duration
- end
- wait(2) -- Display for 2 seconds
- -- Fade out background and text
- for i = 0, 1, 0.1 do
- background.BackgroundTransparency = i
- loadingLabel.TextTransparency = i
- wait(0.05) -- 0.5s fade-out duration
- end
- -- Disable particles after fade out
- particleEmitter.Enabled = false
- end
- -- Start the fade in/out effect with particles
- fadeInAndOut()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement