Dzsozi (h03) Posted April 28, 2014 Share Posted April 28, 2014 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
Martyz Posted April 28, 2014 Share Posted April 28, 2014 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
Dzsozi (h03) Posted April 28, 2014 Author Share Posted April 28, 2014 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
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now