1
General / Efficient ways to create buttons
« on: June 24, 2024, 03:09:08 pm »
Hi, i`m new to sfml. Lately i was thinking about most efficient ways to create buttons, especially how to track clicks. I thought about two ways of making it. First: every button checks every tick is it hovered. If true then check for right mouse click event. Second is to check if my cursor is in zone of any button(or object).If true do something on click. So I`d like to know which of the ways better, or is there other efficient way before i move on