Adding Map class
Signed-off-by: Anthony Debucquoy <debucquoy.anthony@gmail.com>
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
package school_project;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
public class Map extends Shape{
|
||||
private ArrayList<Piece> pieces;
|
||||
|
||||
public Map(boolean[][] matrix) {
|
||||
super(matrix);
|
||||
}
|
||||
|
||||
public Map() {
|
||||
super();
|
||||
}
|
||||
|
||||
// TODO: 2/27/23 Tests for Map
|
||||
public void AddShape(Piece piece){
|
||||
pieces.add(piece);
|
||||
}
|
||||
}
|
||||
@@ -2,6 +2,7 @@ package school_project;
|
||||
|
||||
public class Piece extends Shape{
|
||||
|
||||
private int x,y; // Position in the Map Object
|
||||
public Piece() {
|
||||
super();
|
||||
}
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
package school_project;
|
||||
|
||||
Reference in New Issue
Block a user