How to make ImageLabel visible when hovering over TextButton?

First of all, for advice on scripting, I like to use the roblox documentation for learning about certain things, as well as the developer forum! Roblox Creator Documentation

An example: The other day, I was learning about :Lerp Which allows an Object to move a certain amount of % from position 1 to position 2. I started by looking on the Documentation page, and found this: CFrame:Lerp Docs. , but for me that didn’t contain enough information for me to use it, so I used these posts: How to Use Lerp post, Lerp isn’t executing properly Post and a couple others to fill in and be able to use it myself. Though this is an example.

Anyways back to what this topic is about. You can do this by something like this:

local textbutton:TextButton = nil -- replace 'nil' with the pathway to the button
local textlabel:TextLabel = nil -- replace 'nil' with the pathway to the label

textbutton.MouseEnter:Connect(function()
	if textlabel.Visible == false then
		textlabel.Visible = true

	end
end)

textbutton.MouseLeave:Connect(function()
	if textlabel.Visible == true then
		textlabel.Visible = false

	end
end)
3 Likes