Jump to content

onClientMouseEnter problem


Recommended Posts

Hello guys! Today I was trying to make image buttons with guiStaticImageLoadImage and onClientMouseEnter, but the image doesn't changes. Can somebody help me please?

  
... 
  
skinHover = guiCreateButton(0.0, 0.339, 1.0, 0.0725, "", true, tabCreationOne) 
guiSetAlpha(skinHover, 0.75) 
addEventHandler ( "onClientMouseEnter", skinHover, skinH, false ) 
  
... 
  
function skinH () 
    guiStaticImageLoadImage(skinHover, "creation/skin.png" ) 
end  

Link to comment

guiStaticImageLoadImage first parameter - theElement: The static image element to be changed.

Your skinHover element is not static image, it's button. You should create an image instead of skinHover button OR remove the button and create an image instead of it in skinH function.

Link to comment
guiStaticImageLoadImage first parameter - theElement: The static image element to be changed.

Your skinHover element is not static image, it's button. You should create an image instead of skinHover button OR remove the button and create an image instead of it in skinH function.

Oh, I see, it's my bad, there was another line where's the image defined, but I forgot about this line lol Now It's solved! Thank you!

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...