✓ Accepted answer
For GUIs
fade = script.Parent
function fade()
for i = 1, 0, -0.05 do
wait()
fade.BackgroundTransparency = i
end
end
wait(3)
fade()
BackgroundTransparency is used for the transparency of the frame/textlabel/textbutton/textbox 's background. TextTransparency is the same thing, but doesn't change the background, it changes the text. Please specify if the thing you are fading in is a frame,textlabel ect. One last thing, while true do is used for repeating the script over and over. Remember, PUT THIS GUI SCRIPT IN A LOCALSCRIPT. Please accept if this helps!
For Parts/Bricks
game.Workspace.Part.Transparency = 1
wait(0.1)
game.Workspace.Part.Transparency = 0.9
wait(0.1)
game.Workspace.Part.Transparency = 0.8
wait(0.1)
game.Workspace.Part.Transparency = 0.7
wait(0.1)
game.Workspace.Part.Transparency = 0.6
wait(0.1)
game.Workspace.Part.Transparency = 0.5
wait(0.1)
game.Workspace.Part.Transparency = 0.4
wait(0.1)
game.Workspace.Part.Transparency = 0.3
wait(0.1)
game.Workspace.Part.Transparency = 0.2
wait(0.1)
game.Workspace.Part.Transparency = 0.1
wait(0.1)
This script should be in a regular script. This script is to fade out. To fade in, use:
game.Workspace.Part.Transparency = 0.1
wait(0.1)
game.Workspace.Part.Transparency = 0.2
wait(0.1)
game.Workspace.Part.Transparency = 0.3
wait(0.1)
game.Workspace.Part.Transparency = 0.4
wait(0.1)
game.Workspace.Part.Transparency = 0.5
wait(0.1)
game.Workspace.Part.Transparency = 0.6
wait(0.1)
game.Workspace.Part.Transparency = 0.7
wait(0.1)
game.Workspace.Part.Transparency = 0.8
wait(0.1)
game.Workspace.Part.Transparency = 0.9
wait(0.1)
game.Workspace.Part.Transparency = 1
Remember, you do not need multiple scripts for one gui/part. Just use one.
1 comment
If you give this a thumbs down, please post a comment on WHY you gave it a thumbs down, Thank you