+ 2

How to model objects in a game of chess in java?

The board must be an object and the cells must be attributes or cells must be independent objects? The pieces must be objects or attributes of cells ?

13th Apr 2017, 1:00 PM
Anibal Lopes
1 Odpowiedź
+ 4
The board should be a class with the attribute cells. Like that you can create an object like: Board table= new Board(); int cells = table.cells;
13th Apr 2017, 2:07 PM
JRE
JRE - avatar