How to make white screen?

-- script


	local ta = game:GetService("TweenService")
	local tweeninfo = TweenInfo.new(1,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut,0,false,0)
	local properties = {

		BackgroundTransparency = 0

	}

	local create = ta:Create(game.StarterGui.ScreenGui.White_screen,tweeninfo,properties)



	create:Play()

I have a white screen does not appear

1 Like

Please give more context. If you want to make a white screen with a GUI, you should just create a screenGUI, and put a frame inside of it with scale set to {(1,0),(1,0)}.

1 Like

I set the SCALE in my game itself, the white screen does not appear in the current server

1 Like

If this is in LocalScript then,

local playerGui = game.Players.LocalPlayer.PlayerGui
local ta = game:GetService("TweenService")
local tweeninfo = TweenInfo.new(1,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut,0,false,0)
local properties = {
	BackgroundTransparency = 0
}
local create = ta:Create(playerGui.ScreenGui.White_screen,tweeninfo,properties)
create:Play()

I don’t have a local script what to do?

Make a local script inside the “ScreenGui” that is inside the StarterGui, I also recommend you change the ScreenGui’s name to something like “Interface”.

Inside that local script is where you want your code, and since the localscript will be inside the gui you are editing, you can do “script.Parent.White_screen” to access that White_screen frame.

Taking Zachary’s code from before, it becomes:

-- // variables // --
local TweenService = game:GetService("TweenService")

local WhitescreenFrame = script.Parent:WaitForChild("White_screen") -- wait for it to be there

-- you don't need to give all parameters for TweenInfo.new
local tweeninfo = TweenInfo.new(1, Enum.EasingStyle.Sine, Enum.EasingDirection.InOut)

-- // do the actual tweening // --
local backgroundFade = TweenService:Create(WhitescreenFrame, tweeninfo, {
	BackgroundTransparency = 0, -- change properties inside this table
})
backgroundFade:Play()

You can remove the comments if you understand it :+1:

local screen = script.Parent

local ts = game:GetService("TweenService")
local tweeninfo = TweenInfo.new(1, Enum.EasingStyle.Sine, Enum.EasingDirection.InOut, 0, false, 0)
local properties = {
	BackgroundTransparency = 0
}

local create = ts:Create(screen, tweeninfo, properties)
create:Play()

This is a local script, place it inside the “screen” GuiObject.