0

I've been working on a Rubix cube and it's going good so far. Graphics were not necessary but I gave WinBGIm (a 'newer' graphics.h) a try since I'm still an amateur. It's going good, runs great in console and made a layer of graphics over it and drew all the shapes.

This is what I have right now:

enter image description here

All is well until I try to move onto mouse operations and I realize I have no way to detect if the mouse clicks a polygon (the arrows). WinBGIm itself doesn't have something like this. How do you think I can do this? It's a simple question if anyone has ever used WinBGIm. I'll add any extra info needed.

genpfault
  • 51,148
  • 11
  • 85
  • 139
MegamanEXE
  • 351
  • 1
  • 3
  • 12
  • Is it important you can click only on the *triangle*? Surely it's easier, and enough, to check if one clicks inside its bounding rectangle? – Jongware Dec 08 '13 at 21:18
  • .. if you insist on using actual triangles, try any of the methods in [How to determine a point in a triangle?](http://stackoverflow.com/questions/2049582/how-to-determine-a-point-in-a-triangle). Beware that the *order* of your triangle points is *very* important. – Jongware Dec 08 '13 at 21:54

0 Answers0