Posted March 2, 20223 yr I have made a button that have a circle texture (by overriding GuiButton), but the hitbox stays rectangular. Any ways I can change it?
March 2, 20223 yr Author I mean for ordinary rectangular buttons I can do this hovered = (mouseX >= x) && (mouseY >= y) && (mouseX < x + width) && (mouseY < y + height); But then since then 'width' of a circle button is 'changing' along the 'height', how can I detect whether it is hovered/clicked. Please give me some ideas
March 2, 20223 yr do you know what the distance (in pixels) is between (mouseX, mouseY) and (somethingX, somethingY)?
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.