draw4free logo

object oriented chess design


you are here: main > tutorial > chess > object oriented chess design

 

To keep good object oriented design we need to create tree structure for picture layers. Chess consists of pawns, queens, knights, rooks, bishops, kings and naturally the board.

new picture button
For new picture click on the New Button in the left menu.
default Unknown layer in drawing tree
In the right drawing tree structure click on the default Unknown name. Instead Unknown write "chess" to the field and press Enter.
layer popup menu
Click again on the name "chess", but this time with the right mouse button. Popup menu will show up. Click on the "Insert" and enter "board". Continue doing this two steps and add pawn, knight, ... to the structure.
object oriented layer structure for chess

You should end up with this tree.

 

In real life its better to create each piece alone, save it and at the end create chess layer and add all pieces to drawing.