looking for a layout
I'm currently making a tower defence game. Visually, this is going to be a "playingfield" where all the action happens and some buttons and textfields etc. below that to give the player some extra options. I'm curently developing the "editor mode" first because it is simpler because it hasn't got moving monsters and shooting tower. Also the game class itself will take in a whole level from the editor (or memory).
Currently, the editor class makes a 2d-array filled with squares and sends them their location in the grid and their size. Based on that, the squares (a seperate class) calculate which pixels they need to change color and draw a square there. This worked perfectly untill I needed a reset button. Using the borderlayout I added it to south, but it looked bad. So now my question is, can anyone suggest a good layout or help me find a good layout?
printscreen of the current situation:
Why not stick the functionality in a JMenuItem near the top of that frame (in a JMenuBar)? Or simply as a JButton in a JToolBar (also near the top of the JFrame)?
Originally Posted by imorio
Or, if you want the Reset button at the bottom, add it to a JPanel which has its default FlowLayout, then add that panel to the frame's SOUTH.
2 excellent idea's. I think I'm going to do both, put some functions in a menubar at the top and when the game itself is started display that in the bottem.