Skip to main content
gamedev.net
🔒 Locked

2D Picking

Started by X5-Programmer 2 replies 400+ views
Original Post
X5-Programmer
X5-Programmer
hi, I have make an 2D menu to a game and i need to know how to make a 2d pickmode so i can select buttons on the screens and so on... if someone of you can help me plz post me some links to totorials or examples there i can find something that can help. //x5
-[ thx ]-
Damocles
Damocles
It all depends how complex your menu is, If it''s a few simple buttons, then when the mouse is pressed simply check if the coordinates are in the rectangles of one of the buttons.

If it''s more complex, you might want to develop a button class that is responsible for reacting to mouse input and checking it''s own boundaries againt mouse actions.
------------------------------------------[New Delta Games] | [Sliders]
X5-Programmer
X5-Programmer
Its not that complex so i go on the mouse coords then
-[ thx ]-

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.