Posted December 21, 20168 yr Hi, I want to detect if a mouse hovers over a gui element and when it does, it will show some text. How do I do this? I was looking into the Gui classes but I didn't find anything. Thanks. Creator of the Master Chef Mod and many more to come. If I helped you, please click the 'thank you' button.
December 22, 20168 yr If you know the X coordinate, Y coordinate, width, and height of your GUI element, it's a simple matter of a couple less than/greater than checks. You need to check that: mouse X >= element X mouse Y >= element Y mouse X <= element X + element Width mouse Y <= element Y + element Height Don't make mods if you don't know Java. Check out my website: http://shadowfacts.net Developer of many mods
December 22, 20168 yr Possibly an update method, perhaps a draw? Currently updating my Mod to 1.10.2 https://bitbucket.org/hugo_the_dwarf/riseoftristram2016/src?at=master
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.