0

I'm have an idea for a really cool looking UI for the main menu of a game I'm working on. The menu will be a perfect circle centered in the middle of the frame. The circle is divided into 6 equal segments. I attached a poorly made example picture to try and illustrate the concept. Basically just wondering what is the best method for drawing this shape? My first idea was to create an array of points that store each intersection and then just draw lines between them. Also, I sucked at trig so any advice for how to get exact measurements would be very helpful.

I'm trying to incorporate this idea within the creation of this menu. Any thoughts on how to pull it all together? Draw arc with 2 points and center of the circle

example of menu

Community
  • 1
  • 1
mbreen
  • 558
  • 3
  • 9
  • 20
  • Trig would come in very handy here. Hint: Each sixth of the circle is in 2*pi/6 steps, and the radius of the inner circle is between 0 and 0.25. – Makoto Apr 15 '12 at 15:27
  • Is there any particular reason you want to draw this on the fly rather than using pre-made images? – jonmorgan Apr 15 '12 at 15:29
  • you want everything to be equal right? I would draw six arcs at 60 degrees each (using Graphics fillArc) and then draw a circle in the middle. – twain249 Apr 15 '12 at 15:30
  • @twain249 not a bad idea, only "issue" is that it would be nice to store each "segment" so I can change the color and maybe (for coolness effect) have the segment pop out from the circle a little when hovered on. – mbreen Apr 15 '12 at 15:36
  • @mbreen you could create separate `Components` for all the segments and then use the individual's container's `Graphics` and then you can register `Listeners` for the various `Components` to do some manipulation. – twain249 Apr 15 '12 at 15:43
  • I uploaded a new picture that is a little better than the first one. Any more ideas? – mbreen Apr 15 '12 at 16:03