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

Help with gui Image property?

Basically I am wanting an image to be replaced with a different image when moused over, this is my code.

gui = script.Parent
gui.Image = "rbxassetid://154570980"

gui.MouseEnter:connect(function()
	gui.Image = "rbxassetid://154570976"
end)

gui.MouseLeave:connect(function()
	gui.Image = "rbxassetid://154570980"
end)

Output: 21:44:38.599 - Content failed because Input string was not in a correct format. 21:44:38.600 - Image failed to load: rbxassetid://15457_ovr.png: Request failed

An alternative I can think of is to have two images and make on visible when moused over and one not then vice versa.

Any help? What is the correct input for the "Image" property?

1 comment

0

UPDATE: That exact code just randomly started working??? The error completely disappeared (same server about 30 seconds later). Perhaps the image wasn't loaded in?

1 answer

✓ Accepted answer

Can't see any problem on your script. Everything seems right.

1 comment

0

Really sorry about that, the image just wasn't loaded yet.

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