Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do you make a frame become visible when a cursor moves over it?

How do you make a script, where if you move a cursor over a GUI button, then it will make the frame become visible?? And when you move it off of the button, then it wont be visible.

1 comment

0

Also do you know how to make it fade when it goes visible and not visible??

2 answers

Make sure the button's or Frame's active property is set to "active". Then the code should be:

local frame = script.Parent
frame.MouseEnter:connect(function()
frame.Visible = true
end)
frame.MouseLeave:connect(function()
frame.Visible = false
end)

I'm pretty sure this should work, PM me @Mowblow on roblox if it does not.

Use the 'MouseEnter' and 'MouseLeave' events for the button/label. With the fading, you can just do a loop to change the transparency in the function. Comment if you'd like an example, I didn't put a script just in case you wanted to make the script by yourself :)

This discussion is preserved as it was. New answers, comments, and votes are closed.