So far I have made the script so it clones the GUI into the players starterGUI, however, I wan't the gui text to fade away after a couple seconds. This is what I have;
`local Gui = game.Lighting.Gui1 function GiveGui(Player) if Player.PlayerGui:FindFirstChild(Gui.Name)~=nil then return end Gui:Clone().Parent=Player.PlayerGui end script.Parent.Touched:connect(function(hit) local Player=game.Players:GetPlayerFromCharacter(hit.Parent) if Player==nil then return end GiveGui(Player) end)`
I want to add a function that calls the gui transparency specifically to the text. and slowly and seemily fades away, however i cant do this, could anyone help me?
game.StarterGUI.GUI.Frame.Text.Transparency = 0.9 wait(--INSERT LEGNTH HERE) game.StarterGUI.GUI.Frame.Text.Transparency = 0.8
Correct me if I am wrong. As I am a novice myself.
I'm not quite sure about this, but I'm almost sure this would work if not be close to the right idea.
Put a localscript inside the frame and set this as the script
wait(3) --causes the script to wait 3 seconds before starting the fading frame = script.Parent for i = 1, 50 do wait(1/20) frame.TextTransparency = frame.TextTransparency + .02 end
This would cause the text to fade away over a period of 2.5 seconds after being visible for 3 seconds. To speed it up, set the wait to wait() or from 1/30-1/21, to slow it down set the wait anywhere from 1/19-1(I recommend you don't slow it down, otherwise it will take a very long time to disappear).