So, I ran into a bit of an issue. I am extremely new to coding in lua. And I am trying to make a fade-out when you click on the "start!" or "play." button.
-- Variables --
MainMenu = game.Workspace.StarterGui.MainMenu
Transparency = MainMenu.cfg.Transparency
Play = MainMenu.d3.gui.Background.TextButton
Title = Play.parent.Title
BG = Title.parent
Blank = MainMenu.parent.Blank.frame
Clicked = false
-- Script --
if Play.Mouse1Click then
Clicked = true
end
if Clicked == true then
Play.BackgroundTransparency = Transparency.Value
Title.TextTransparency = Transparency.Value
BG.TextTransparency = Transparency.Value
if Transparency.Value ~= 1 then
Transparency.Value + 0.1 -- Error Right Here!
wait(0.1)
end
end
