public TempMap(BasicMap map) { this.map = map; blocked = new boolean[map.getWidthInTiles()][map.getHeightInTiles()]; triad = new Triad<Integer, Integer, GameObject>(map.getWidthInTiles() * map.getHeightInTiles()); for (int x = 0; x < map.getWidthInTiles(); x++) { for (int y = 0; y < map.getHeightInTiles(); y++) { blocked[x][y] = map.blocked(x, y); } } }
public void clear() { for (int x = 0; x < map.getWidthInTiles(); x++) { for (int y = 0; y < map.getHeightInTiles(); y++) { blocked[x][y] = map.blocked(x, y); } } triad.clear(); }