I have been working on a GUI for an intro and I was having trouble with making a script I needed to make it so that an image label involved in the intro becomes NOT transparent. When I put the script in and run it it doesn't work. All the positions of objects in the script are right as in all the things I said in order to go into were in correct orders. Here's what I have so far.
function playerEntered(Player) local LoadingMenu = script.Parent local SlideTime = math.random (2,4) local Intro = script.MainIntro local SlideOptions = script.Parent.Slides wait (math.random (2,3)) SlideOptions.Load10.ImageTransparency = 0 end game.Players.ChildAdded:connect(playerEntered)
(Thanks for helping if you do!)
EDIT: I don't think there is anything wrong with your script. If I were to guess it is with your actual image.
You can try adding these lines to see if it actually fixes anything:
These line sets the transparency to none.
SlideOptions.Load10.Transparency = 0 SlideOptions.Load10.ImageTransparency = 0
This sets the GUI above all else.
SlideOptions.Load10.ZIndex = 10
This makes sure that the GUI is visible.
SlideOptions.Load10.Visible = true
Transparency set at 0 means there is no transparency to it, whether it is a part or a GUI Image. If you want the to be completely transparent you need the transparency to be 1 or you can set the Image's visible bool value to false.
Final Code:
function playerEntered(Player) local LoadingMenu = script.Parent local SlideTime = math.random (2,4) local Intro = script.MainIntro local SlideOptions = script.Parent.Slides wait (math.random (2,3)) SlideOptions.Load10.ImageTransparency = 0 SlideOptions.Load10.Transparency = 0 SlideOptions.Load10.ImageTransparency = 0 SlideOptions.Load10.ZIndex = 10 SlideOptions.Load10.Visible = true end game.Players.ChildAdded:connect(playerEntered)