Hello everyone, at the end of next week I need a Battleship game, but I'm stuck with making a 2d grid. I have to make something like the photo, but i don't even know how to begin on it. In the grid it are all nice squares and they are all nice ligned out, How did they do that?
Fix the sizes of all those squares. Try a grid layout. There are lots of layouts, which you can find about in the Java Tutorials.
Campbell Ritchie
Sheriff
Joined: Oct 13, 2005
Posts: 32611
4
posted
0
Use gradient painting for that colour shading. Draw multiple lines at right angles to each other. (This suggestion is instead of the layout and many squares, not in addition.)