From bcc904a9d3a4077a0e419cb5913923deaa8f8dec Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 2 Feb 2024 17:23:26 -0500 Subject: [PATCH 01/67] Added a text file File represents all files we will put and use to fully implement the StarBattle puzzle later. --- .../rpi/legup/puzzle/starbattle/allfiles.txt | 230 ++++++++++++++++++ 1 file changed, 230 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt b/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt new file mode 100644 index 000000000..7f006191a --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt @@ -0,0 +1,230 @@ +//StarBattle.java + +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.model.Puzzle; +import edu.rpi.legup.model.gameboard.Board; + +public class StarBattle extends Puzzle { + public StarBattle() { + super(); + this.name = "StarBattle"; + + this.importer = new StarBattleImporter(this); + this.exporter = new StarBattleExporter(this); + + this.factory = new StarBattleCellFactory(); + } + + @Override + public void initializeView() { + } + + @Override + public Board generatePuzzle(int difficulty) { + return null; + } + + @Override + public boolean isBoardComplete(Board board) { + return true; + } + + @Override + public void onBoardChange(Board board) { + } +} + +//StarBattleBoard.java + +package edu.rpi.legup.puzzle.lightup; + +import edu.rpi.legup.model.gameboard.GridBoard; +import edu.rpi.legup.model.gameboard.PuzzleElement; + +import java.awt.*; +import java.util.HashSet; +import java.util.Set; + +public class StarBattleBoard extends GridBoard { + + private int size; + private vector group_sizes; + + /** + * StarBattleBoard Constructor - create a new Star Battle board + * + * @param size size of one side of the star battle board + */ + + public StarBattleBoard(int size) { + super(size, size); + group_sizes = vector(size); + } + + @Override + public StarBattleCell getCell(int x, int y) { + return (StarBattleCell) super.getCell(x, y); + } + + +} + +//StarBattleCell.java + +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.model.gameboard.GridCell; + +import java.awt.*; +import java.util.HashSet; +import java.util.Set; + +public class StarBattleCell extends GridCell { + private int groupIndex; + private int max; + + /** + * SudokuCell Constructor - creates a new Sudoku cell to hold the puzzleElement + * + * @param valueInt value of the star battle cell denoting its state + * @param location location of the cell on the board + * @param size size of the sudoku cell + */ + public StarBattleCell(int value, Point location, int groupIndex, int size) { + super(value, location); + this.groupIndex = groupIndex; + this.max = size; + } + + @Override + public void setType(Element e, MouseEvent m) { + switch (e.getElementID()) { + case "SBUP-PLAC-0001": + this.data = -4; + break; + case "SBUP-UNPL-0002": + this.data = -1; + break; + case "SBUP-UNPL-0003": + this.data = -2; + break; + case "SBUP-UNPL-0001"://Not sure how button events work + switch (m.getButton()){ + case MouseEvent.BUTTON1: + if (this.data < 0 || this.data > 3) { + this.data = 0; + } + else { + this.data = this.data + 1; + } + break; + case MouseEvent.BUTTON3: + if (this.data > 0) { + this.data = this.data - 1; + } + else { + this.data = 3;//Unsure + } + break; + } + break; + } + } + + public LightUpCellType getType() { + switch (data) { + case -3: + return LightUpCellType.UNKNOWN; + case -2: + return LightUpCellType.STAR; + case -1: + return LightUpCellType.BLACK; + default: + if (data >= 0) { + return StarBattleCellType.WHITE; + } + } + return null; + } + + /** + * Gets the region index of the cell + * + * @return group index of the cell + */ + public int getGroupIndex() { + return groupIndex; + } + + /** + * Gets the size of the cell + * + * @return size of the cell + */ + + public int getMax() { + return max; + } + +} + +//StarBattleCellController.java + +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.controller.ElementController; +import edu.rpi.legup.model.gameboard.PuzzleElement; + +import java.awt.event.MouseEvent; + +public class StarBattleCellController extends ElementController { + @Override + public void changeCell(MouseEvent e, PuzzleElement data) { + StarBattleCell cell = (StarBattleCell) data; + if (e.getButton() == MouseEvent.BUTTON1) { + if (e.isControlDown()) { + this.boardView.getSelectionPopupMenu().show(boardView, this.boardView.getCanvas().getX() + e.getX(), this.boardView.getCanvas().getY() + e.getY()); + } + else { + if (cell.getData() == 0) { + data.setData(-3); + } + else { + data.setData(cell.getData() + 1); + } + } + } + else { + if (e.getButton() == MouseEvent.BUTTON3) { + if (cell.getData() == -3) { + data.setData(0); + } + else { + data.setData(cell.getData() - 1); + } + } + } + } +} + +//StarBattleCellFactory.java + + + +//StarBattleCellType.java +package edu.rpi.legup.puzzle.starbattle; + +public enum StarBattleType { + UNKNOWN(-3), STAR(-2), BLACK(-1), WHITE(0); + + public int value; + + StarBattleCell(int value) { + this.value = value; + } +} + +//StarBattleExporter.java +//StarBattleImporter.java +//StarBattleView.java \ No newline at end of file From 9fa0e0205a7f744b9597135202290e1363339593 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 9 Feb 2024 17:45:28 -0500 Subject: [PATCH 02/67] Imported the black and star tiles ID probably needs to be changed in the future, and more assets on the way. --- .../puzzle/starbattle/elements/BlackTile.java | 9 +++++++++ .../puzzle/starbattle/elements/StarTile.java | 9 +++++++++ .../edu/rpi/legup/images/starbattle/black.gif | Bin 0 -> 856 bytes .../edu/rpi/legup/images/starbattle/star.gif | Bin 0 -> 545 bytes 4 files changed, 18 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/elements/BlackTile.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/black.gif create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/star.gif diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/BlackTile.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/BlackTile.java new file mode 100644 index 000000000..fd74774a7 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/BlackTile.java @@ -0,0 +1,9 @@ +package edu.rpi.legup.puzzle.starbattle.elements; + +import edu.rpi.legup.model.elements.NonPlaceableElement; + +public class BlackTile extends NonPlaceableElement { + public BlackTile() { + super("STBL-PLAC-0002", "Black Tile", "The black tile", "edu/rpi/legup/images/lightup/black.gif"); + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java new file mode 100644 index 000000000..2510869eb --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java @@ -0,0 +1,9 @@ +package edu.rpi.legup.puzzle.starbattle.elements; + +import edu.rpi.legup.model.elements.NonPlaceableElement; + +public class StarTile extends NonPlaceableElement { + public StarTile() { + super("LTUP-PLAC-0001", "Star Tile", "The star tile", "edu/rpi/legup/images/starbattle/star.gif"); + } +} diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/black.gif b/src/main/resources/edu/rpi/legup/images/starbattle/black.gif new file mode 100644 index 0000000000000000000000000000000000000000..13381a7179c2af7ad23ef064b743d3e479b56070 GIT binary patch literal 856 zcmZ?wbhEHbRA5kG_|Cv^;=~DtQ7{?;BQ*pRf3kqRt^*=Ld4hq%l;J<8jK_ur2b(#B zwPH?eSa`TyK-p`K$HqlRyCsaX?wr`T_;|m9bC-Px$+et)0R7gwB)k~;OQ4|O8-%S#Q6f(WuN(@LbxC6?>z|bQh@)#H)BSjf;3uWXn zP!c6GWTuoTBMJi~86e~tQXYG0-#TsIx!*bRl~udbx7OP0zy9m7zdk*dz8=T--vKPZ zNZe}5ye)&{8DLYd0Dk7cjT39^h^+_)Av2;~qv~I+oyO zH;_68qf-gSS5A~<6}DyFAzZ*gyu-&-wh#DP0#*UeVHPIj6985Df-zYUfr3d@-r_ah z<1to;v1D)nd-JVpIkQjs`y%Q0XIp&7Vq88Gu{7JF`N8ys&8EnBIreozzwXyvjSvlDruB;5x!$Xnyj1X!07h$Pn6jcYf6SBM5q!d&djqZoq_nZLnHO!*stxbz$k z^O6OVs+_<8W@9oUnLlJW2AgrJxN#Uiu)EO55S(udFjW7z7Y*E=w)sI0G84zJJpYbF zwzLI!nx2AqGGew**VH(+^=R_>j2PR-CF)OWzawq%uDa$G`gogyQMoI%|H<=lr(y6R jw|ThRX3<*4@9h2yt8`HryKo;Y00000NkvXXu0mjflb`cS literal 0 HcmV?d00001 From 17d26d73444b353a1ea31abde928c754020f754d Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Sat, 10 Feb 2024 14:53:11 -0500 Subject: [PATCH 03/67] Added UnknownTile Also fixed the descriptions of the black and star tile, not sure if we need another asset. --- .../puzzle/starbattle/elements/BlackTile.java | 2 +- .../puzzle/starbattle/elements/StarTile.java | 2 +- .../puzzle/starbattle/elements/UnknownTile.java | 9 +++++++++ .../edu/rpi/legup/images/starbattle/empty.gif | Bin 0 -> 857 bytes 4 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/empty.gif diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/BlackTile.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/BlackTile.java index fd74774a7..2601bd351 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/BlackTile.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/BlackTile.java @@ -4,6 +4,6 @@ public class BlackTile extends NonPlaceableElement { public BlackTile() { - super("STBL-PLAC-0002", "Black Tile", "The black tile", "edu/rpi/legup/images/lightup/black.gif"); + super("STBL-PLAC-0002", "Black Tile", "The black tile that shows where you cannot place a star", "edu/rpi/legup/images/lightup/black.gif"); } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java index 2510869eb..19ba7baed 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java @@ -4,6 +4,6 @@ public class StarTile extends NonPlaceableElement { public StarTile() { - super("LTUP-PLAC-0001", "Star Tile", "The star tile", "edu/rpi/legup/images/starbattle/star.gif"); + super("LTUP-PLAC-0001", "Star Tile", "The star tile, the token of the game.", "edu/rpi/legup/images/starbattle/star.gif"); } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java new file mode 100644 index 000000000..192a95357 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java @@ -0,0 +1,9 @@ +package edu.rpi.legup.puzzle.starbattle.elements; + +import edu.rpi.legup.model.elements.NonPlaceableElement; + +public class UnknownTile extends NonPlaceableElement { + public UnknownTile() { + super("LTUP-PLAC-0001", "Unknown Tile", "An empty tile", "edu/rpi/legup/images/starbattle/star.gif"); + } +} diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/empty.gif b/src/main/resources/edu/rpi/legup/images/starbattle/empty.gif new file mode 100644 index 0000000000000000000000000000000000000000..38b91d0a2b9c6599eb19d14466db047a86d2ea97 GIT binary patch literal 857 zcmZ?wbhEHbRA5kG_|Cxa|Nno6Q7{?;BQ*qcKpqF>1qKc~21X7Uj|~eBHggDT#hlo% z@Nm0;vez7sjf;+UOBiR}IkEBaF$M+Z0v^pz$tNbN+pdZ^xoPR?=?2NC=6GICbzrat E0QgHHq5uE@ literal 0 HcmV?d00001 From 8955343d8bbdac96fa80cb31480b1784a58c1db5 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 13 Feb 2024 16:32:48 -0500 Subject: [PATCH 04/67] Create StarBattleCellType.java Created StarBattleCellType.java file --- .../legup/puzzle/starbattle/StarBattleCellType.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java new file mode 100644 index 000000000..0548a6b38 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java @@ -0,0 +1,12 @@ +//StarBattleCellType.java +package edu.rpi.legup.puzzle.starbattle; + +public enum StarBattleType { + UNKNOWN(-3), STAR(-2), BLACK(-1); + + public int value; + + StarBattleCell(int value) { + this.value = value; + } +} \ No newline at end of file From 1ad2347247d53afe83646401416f5ee4e3ecd735 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 13 Feb 2024 16:37:59 -0500 Subject: [PATCH 05/67] Update StarBattleCellType.java Fixed StarBattleCellType typos --- .../edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java index 0548a6b38..8fb3338f7 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java @@ -1,12 +1,12 @@ //StarBattleCellType.java package edu.rpi.legup.puzzle.starbattle; -public enum StarBattleType { +public enum StarBattleCellType { UNKNOWN(-3), STAR(-2), BLACK(-1); public int value; - StarBattleCell(int value) { + StarBattleCellType(int value) { this.value = value; } } \ No newline at end of file From 12b7a4358c042c863ea0a03792cd790207244d18 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Tue, 13 Feb 2024 16:41:30 -0500 Subject: [PATCH 06/67] Added StarBattle.java Also changed the IDs for our assets --- .../legup/puzzle/starbattle/StarBattle.java | 33 +++++++++++++++++++ .../puzzle/starbattle/StarBattleCell.java | 0 .../puzzle/starbattle/elements/StarTile.java | 2 +- .../starbattle/elements/UnknownTile.java | 2 +- 4 files changed, 35 insertions(+), 2 deletions(-) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java new file mode 100644 index 000000000..e9e18b92a --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java @@ -0,0 +1,33 @@ +package edu.rpi.legup.puzzle.starbattle; +import edu.rpi.legup.model.Puzzle; +import edu.rpi.legup.model.gameboard.Board; + +public class StarBattle extends Puzzle { + public StarBattle() { + super(); + //this.name = "StarBattle"; + + //this.importer = new StarBattleImporter(this); + //this.exporter = new StarBattleExporter(this); + + //this.factory = new StarBattleCellFactory(); + } + + @Override + public void initializeView() { + } + + @Override + public Board generatePuzzle(int difficulty) { + return null; + } + + @Override + public boolean isBoardComplete(Board board) { + return true; + } + + @Override + public void onBoardChange(Board board) { + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java new file mode 100644 index 000000000..e69de29bb diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java index 19ba7baed..d42cc0010 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/StarTile.java @@ -4,6 +4,6 @@ public class StarTile extends NonPlaceableElement { public StarTile() { - super("LTUP-PLAC-0001", "Star Tile", "The star tile, the token of the game.", "edu/rpi/legup/images/starbattle/star.gif"); + super("STBL-PLAC-0001", "Star Tile", "The star tile, the token of the game.", "edu/rpi/legup/images/starbattle/star.gif"); } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java index 192a95357..3e1cbca26 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java @@ -4,6 +4,6 @@ public class UnknownTile extends NonPlaceableElement { public UnknownTile() { - super("LTUP-PLAC-0001", "Unknown Tile", "An empty tile", "edu/rpi/legup/images/starbattle/star.gif"); + super("STBL-PLAC-0001", "Unknown Tile", "An empty tile", "edu/rpi/legup/images/starbattle/star.gif"); } } From 24450fd99b358f5dfb06d76933c21ad49e13d0bd Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Wed, 14 Feb 2024 16:31:13 -0500 Subject: [PATCH 07/67] Added White Tile and finished starter code for Cell Only Board needs to be added to get the basic puzzle running. --- .../puzzle/starbattle/StarBattleCell.java | 85 ++++++++++++++++++ .../puzzle/starbattle/StarBattleCellType.java | 2 +- .../starbattle/elements/UnknownTile.java | 2 +- .../puzzle/starbattle/elements/WhiteTile.java | 10 +++ .../edu/rpi/legup/images/starbattle/white.gif | Bin 0 -> 9700 bytes 5 files changed, 97 insertions(+), 2 deletions(-) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/elements/WhiteTile.java create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/white.gif diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java index e69de29bb..22d74dd7f 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java @@ -0,0 +1,85 @@ +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.model.elements.Element; +import edu.rpi.legup.model.gameboard.GridCell; + +import java.awt.*; +import java.awt.event.MouseEvent; + +public class StarBattleCell extends GridCell { + private int groupIndex; + private int max; + + /** + * StarBattleCell Constructor - creates a new StarBattle cell to hold the puzzleElement + * + * @param valueInt value of the star battle cell denoting its state + * @param location location of the cell on the board + * @param size size of the star battle cell + */ + public StarBattleCell(int value, Point location, int groupIndex, int size) { + super(value, location); + this.groupIndex = groupIndex; + this.max = size; + } + + @Override + public void setType(Element e, MouseEvent m) { + switch (e.getElementID()) { + case "STBL-PLAC-0001": + this.data = -3; + break; + case "STBL-PLAC-0002": + this.data = -2; + break; + case "STBL-PLAC-0003": + this.data = -1; + break; + + case "STBL-UNPL-0001"://Not sure how button events work + switch (m.getButton()){ + case MouseEvent.BUTTON1: + if (this.data > 0 || this.data < -3) { + this.data = -3; + } + else { + this.data = this.data + 1; + } + break; + case MouseEvent.BUTTON3: + if (this.data > -4) { + this.data = this.data - 1; + } + else { + this.data = -1;//Unsure + } + break; + } + break; + } + } + + public StarBattleCellType getType() { + switch (data) { + case -3: + return StarBattleCellType.UNKNOWN; + case -2: + return StarBattleCellType.STAR; + case -1: + return StarBattleCellType.BLACK; + default: + if (data >= 0) { + return StarBattleCellType.UNKNOWN; + } + } + return null; + } + + public StarBattleCell copy() { + StarBattleCell copy = new StarBattleCell(data, (Point) location.clone(), groupIndex, max); + copy.setIndex(index); + copy.setModifiable(isModifiable); + copy.setGiven(isGiven); + return copy; + } +} \ No newline at end of file diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java index 8fb3338f7..f3524034e 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java @@ -2,7 +2,7 @@ package edu.rpi.legup.puzzle.starbattle; public enum StarBattleCellType { - UNKNOWN(-3), STAR(-2), BLACK(-1); + WHITE(-3), STAR(-2), BLACK(-1), UNKNOWN(0); public int value; diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java index 3e1cbca26..c2459f642 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/UnknownTile.java @@ -4,6 +4,6 @@ public class UnknownTile extends NonPlaceableElement { public UnknownTile() { - super("STBL-PLAC-0001", "Unknown Tile", "An empty tile", "edu/rpi/legup/images/starbattle/star.gif"); + super("STBL-UNPL-0001", "Unknown Tile", "An empty tile", "edu/rpi/legup/images/starbattle/star.gif"); } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/WhiteTile.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/WhiteTile.java new file mode 100644 index 000000000..a064c1fad --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/elements/WhiteTile.java @@ -0,0 +1,10 @@ +package edu.rpi.legup.puzzle.starbattle.elements; + +import edu.rpi.legup.model.elements.PlaceableElement; + +public class WhiteTile extends PlaceableElement { + public WhiteTile() { + super("STBL-PLAC-0001", "White Tile", "The white tile", "edu/rpi/legup/images/starbattle/white.gif"); + } +} + diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/white.gif b/src/main/resources/edu/rpi/legup/images/starbattle/white.gif new file mode 100644 index 0000000000000000000000000000000000000000..fc2c683eb7860f47d4322fe0e73b0508099a89de GIT binary patch literal 9700 zcmeHLc{G&m`yXUY*@a4DN~m|3jbSpD>_yqiTFlB|W|$df2ni+9B3ZI!iP9olg(zhy zDN6P%@ghW)tVww zXp@<#p*8RiUi}I10as=~zzhh)6C7Y`&$7m`!QKoync_tPv;4hDU=oKy27x%86-TLs ze<}-qYgCyNh~HqkEkeZRK05JFdf0YdrPz)DpXpj#VF86Cn*La;%ZlH;h$t0N87TfDHCCNg0#+}qI&uY?JDbd)8rSCUgNfSlsq3f<6qSd-f&(ymiE zC+hBE%9nX6bNo~jHRU1K^ip2yT~+jpxmk&BKhBr!L2L~U??Gtg!9+U+he>h)RY6ua zKH720cx&)3d8!z*DD!-~j^#q{B4^h(_f!Ekn@1$PsCRt2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leBoard.java --- .../puzzle/starbattle/StarBattleBoard.java | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java new file mode 100644 index 000000000..300695111 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java @@ -0,0 +1,21 @@ +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.model.gameboard.GridBoard; +import edu.rpi.legup.model.gameboard.PuzzleElement; + +public class StarBattleBoard extends GridBoard { + public StarBattleBoard(int width, int height) { + super(width, height); + } + + public StarBattleBoard(int size) { + super(size, size); + } + + @Override + public StarBattleCell getCell(int x, int y) { + return (StarBattleCell) super.getCell(x,y); + } +} + + From f3b23833821404742f88b8dd073e01b5fe25ab0d Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 16 Feb 2024 16:36:02 -0500 Subject: [PATCH 09/67] Added getRow, getCol, and potential group implementation for later. All StarBattle boards should be square, so I deleted the width height constructor. I also added size for returning a row, col, for future rules. --- .../puzzle/starbattle/StarBattleBoard.java | 34 +++++++++++++++++-- .../rpi/legup/puzzle/starbattle/allfiles.txt | 10 +++--- 2 files changed, 36 insertions(+), 8 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java index 300695111..a32197fa7 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java @@ -1,21 +1,49 @@ package edu.rpi.legup.puzzle.starbattle; +import java.util.*; + import edu.rpi.legup.model.gameboard.GridBoard; import edu.rpi.legup.model.gameboard.PuzzleElement; public class StarBattleBoard extends GridBoard { - public StarBattleBoard(int width, int height) { - super(width, height); - } + + private int size; + //private ArrayList groupSizes; public StarBattleBoard(int size) { super(size, size); + this.size = size; } @Override public StarBattleCell getCell(int x, int y) { return (StarBattleCell) super.getCell(x,y); } + + /* + public StarBattleCell getCell(int groupIndex, int x, int y) { + return getCell(x + (groupIndex % groupSize) * groupSize, y + (groupIndex / groupSize) * groupSize); + }*/ + + public int getSize() { + return size; + } + + public Set getRow(int rowNum) { + Set row = new HashSet<>(); + for (int i = 0; i < size; i++) { + row.add(getCell(i, rowNum)); + } + return row; + } + + public Set getCol(int colNum) { + Set column = new HashSet<>(); + for (int i = 0; i < size; i++) { + column.add(getCell(colNum, i)); + } + return column; + } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt b/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt index 7f006191a..1b1824f21 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt @@ -101,14 +101,14 @@ public class StarBattleCell extends GridCell { public void setType(Element e, MouseEvent m) { switch (e.getElementID()) { case "SBUP-PLAC-0001": - this.data = -4; + this.data = -3; break; - case "SBUP-UNPL-0002": - this.data = -1; - break; - case "SBUP-UNPL-0003": + case "SBUP-PLAC-0002": this.data = -2; break; + case "SBUP-PLAC-0003": + this.data = -1; + break; case "SBUP-UNPL-0001"://Not sure how button events work switch (m.getButton()){ case MouseEvent.BUTTON1: From f6e11dcc1eed36b44a4bae8aead8da03f4e53496 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 23 Feb 2024 11:49:24 -0500 Subject: [PATCH 10/67] Update allfiles.txt Fixed some temporary documentation to reference star battle instead of sudoku. --- src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt b/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt index 1b1824f21..7970eadbf 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt @@ -85,11 +85,11 @@ public class StarBattleCell extends GridCell { private int max; /** - * SudokuCell Constructor - creates a new Sudoku cell to hold the puzzleElement + * StarBattleCell Constructor - creates a new StarBattle cell to hold the puzzleElement * * @param valueInt value of the star battle cell denoting its state * @param location location of the cell on the board - * @param size size of the sudoku cell + * @param size size of the star battle cell */ public StarBattleCell(int value, Point location, int groupIndex, int size) { super(value, location); From 9c3daa796877a9ade90c6a3cba0378ad09faca1f Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 23 Feb 2024 15:29:26 -0500 Subject: [PATCH 11/67] Direct Rule Classes Created skeletons of classes for direct rules. --- .../starbattle/rules/BlackoutDirectRule.java | 49 +++++++++++++++++++ .../rules/FinishWithStarsDirectRule.java | 47 ++++++++++++++++++ .../RegionsWithinRowsColumnsDirectRule.java | 46 +++++++++++++++++ .../RowsColumnsWithinRegionsDirectRule.java | 46 +++++++++++++++++ .../rules/SurroundStarDirectRule.java | 48 ++++++++++++++++++ 5 files changed, 236 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsColumnsDirectRule.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsColumnsWithinRegionsDirectRule.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java new file mode 100644 index 000000000..3c89b0800 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java @@ -0,0 +1,49 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.DirectRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +public class BlackoutDirectRule extends DirectRule { + + public BlackoutDirectRule() { + super("STBL-BASC-0001", + "Blackout", + "If a row, column, or region has enough stars, its unknown spaces are black.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the child node logically follows from the parent node + * at the specific puzzleElement index using this rule + * + * @param transition transition to check + * @param puzzleElement equivalent puzzleElement + * @return null if the child node logically follow from the parent node at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + + return null; + } + + /** + * Creates a transition {@link Board} that has this rule applied to it using the {@link TreeNode}. + * + * @param node tree node used to create default transition board + * @return default board or null if this rule cannot be applied to this tree node + */ + @Override + public Board getDefaultBoard(TreeNode node) { + + return null; + } +} + + diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java new file mode 100644 index 000000000..d2711eced --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java @@ -0,0 +1,47 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.DirectRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +public class FinishWithStarsDirectRule extends DirectRule { + + public FinishWithStarsDirectRule() { + super("STBL-BASC-0002", + "Finish With Stars", + "Unknown spaces must be stars if there are just enough in a row, column, or region to satisfy the puzzle number.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the child node logically follows from the parent node + * at the specific puzzleElement index using this rule + * + * @param transition transition to check + * @param puzzleElement equivalent puzzleElement + * @return null if the child node logically follow from the parent node at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + + return null; + } + + /** + * Creates a transition {@link Board} that has this rule applied to it using the {@link TreeNode}. + * + * @param node tree node used to create default transition board + * @return default board or null if this rule cannot be applied to this tree node + */ + @Override + public Board getDefaultBoard(TreeNode node) { + + return null; + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsColumnsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsColumnsDirectRule.java new file mode 100644 index 000000000..81645a2ad --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsColumnsDirectRule.java @@ -0,0 +1,46 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.DirectRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +public class RegionsWithinRowsColumnsDirectRule extends DirectRule { + public RegionsWithinRowsColumnsDirectRule() { + super("STBL-BASC-0003", + "Regions Within Rows/Columns", + "If a number of regions is fully contained by an equal number of rows or columns, spaces of other regions in those rows or columns must be black.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the child node logically follows from the parent node + * at the specific puzzleElement index using this rule + * + * @param transition transition to check + * @param puzzleElement equivalent puzzleElement + * @return null if the child node logically follow from the parent node at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + + return null; + } + + /** + * Creates a transition {@link Board} that has this rule applied to it using the {@link TreeNode}. + * + * @param node tree node used to create default transition board + * @return default board or null if this rule cannot be applied to this tree node + */ + @Override + public Board getDefaultBoard(TreeNode node) { + + return null; + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsColumnsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsColumnsWithinRegionsDirectRule.java new file mode 100644 index 000000000..53a7b27ee --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsColumnsWithinRegionsDirectRule.java @@ -0,0 +1,46 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.DirectRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +public class RowsColumnsWithinRegionsDirectRule extends DirectRule { + public RowsColumnsWithinRegionsDirectRule() { + super("STBL-BASC-0004", + "Rows/Columns Within Regions", + "If a number of rows or columns is fully contained by an equal number of regions, spaces of other rows or columns, respectively, in those regions must be black.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the child node logically follows from the parent node + * at the specific puzzleElement index using this rule + * + * @param transition transition to check + * @param puzzleElement equivalent puzzleElement + * @return null if the child node logically follow from the parent node at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + + return null; + } + + /** + * Creates a transition {@link Board} that has this rule applied to it using the {@link TreeNode}. + * + * @param node tree node used to create default transition board + * @return default board or null if this rule cannot be applied to this tree node + */ + @Override + public Board getDefaultBoard(TreeNode node) { + + return null; + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java new file mode 100644 index 000000000..932ef7ddd --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java @@ -0,0 +1,48 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.DirectRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +public class SurroundStarDirectRule extends DirectRule { + + public SurroundStarDirectRule() { + super("STBL-BASC-0005", + "Surround Star", + "Any space adjacent to a star must be black.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the child node logically follows from the parent node + * at the specific puzzleElement index using this rule + * + * @param transition transition to check + * @param puzzleElement equivalent puzzleElement + * @return null if the child node logically follow from the parent node at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + + return null; + } + + /** + * Creates a transition {@link Board} that has this rule applied to it using the {@link TreeNode}. + * + * @param node tree node used to create default transition board + * @return default board or null if this rule cannot be applied to this tree node + */ + @Override + public Board getDefaultBoard(TreeNode node) { + + return null; + } +} + From cda9403b1f9bb82880db422e7e18128b3bd53ba4 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 23 Feb 2024 16:01:39 -0500 Subject: [PATCH 12/67] Added javadoc to cell --- .../java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java index 22d74dd7f..2e89649e2 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java @@ -15,6 +15,7 @@ public class StarBattleCell extends GridCell { * * @param valueInt value of the star battle cell denoting its state * @param location location of the cell on the board + * @param groupIndex indicates what group # the cell is in. * @param size size of the star battle cell */ public StarBattleCell(int value, Point location, int groupIndex, int size) { From 0fb71deb5b70bd388e02b2eaa3b3658a81f19fb7 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 23 Feb 2024 16:24:04 -0500 Subject: [PATCH 13/67] Adding barebones Contradiction Rules Files Might have to separate the too few and too many rules into 3 files, for row, column, and region. --- .../rules/ClashingOrbitContradictionRule | 33 +++++++++++++++++++ .../rules/TooFewStarsContradictionRule | 33 +++++++++++++++++++ .../rules/TooManyStarsContradictionRule | 33 +++++++++++++++++++ 3 files changed, 99 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule new file mode 100644 index 000000000..2eb584ea1 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule @@ -0,0 +1,33 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.ContradictionRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +public class ClashingOrbitContradictionRule extends ContradictionRule { + + public ClashingOrbitContradictionRule() { + super("STBL-CONT-0003", + "Clashing Orbit", + "No two stars can be adjacent to each other.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the transition has a contradiction at the specific puzzleElement index using this rule + * + * @param board board to check contradiction + * @param puzzleElement equivalent puzzleElement + * @return null if the transition contains a contradiction at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { + return super.getNoContradictionMessage(); + } +} \ No newline at end of file diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule new file mode 100644 index 000000000..a063b2b6b --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule @@ -0,0 +1,33 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.ContradictionRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +public class TooFewStarsContradictionRule extends ContradictionRule { + + public TooFewStarsContradictionRule() { + super("STBL-CONT-0002", + "Too Few Stars", + "There are too few stars in this region/row/column and there are not enough places to put the remaining stars.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the transition has a contradiction at the specific puzzleElement index using this rule + * + * @param board board to check contradiction + * @param puzzleElement equivalent puzzleElement + * @return null if the transition contains a contradiction at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { + return super.getNoContradictionMessage(); + } +} \ No newline at end of file diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule new file mode 100644 index 000000000..56cd71ba7 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule @@ -0,0 +1,33 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.ContradictionRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +public class TooManyStarsContradictionRule extends ContradictionRule { + + public TooManyStarsContradictionRule() { + super("STBL-CONT-0001", + "Too Many Stars", + "There are too many stars in this region/row/column.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the transition has a contradiction at the specific puzzleElement index using this rule + * + * @param board board to check contradiction + * @param puzzleElement equivalent puzzleElement + * @return null if the transition contains a contradiction at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { + return super.getNoContradictionMessage(); + } +} \ No newline at end of file From cef9d476d8ba74a82112c47b1186a5375a12fb02 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 23 Feb 2024 18:06:34 -0500 Subject: [PATCH 14/67] Added the Element and Board Controller Hopefully we can upload puzzles now that regions are done. --- .../legup/puzzle/starbattle/StarBattle.java | 2 + .../starbattle/StarBattleController.java | 36 +++++++++++++++ .../starbattle/StarBattleElementView.java | 46 +++++++++++++++++++ .../puzzle/starbattle/StarBattleView.java | 0 4 files changed, 84 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleElementView.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java index e9e18b92a..78800916e 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java @@ -15,6 +15,8 @@ public StarBattle() { @Override public void initializeView() { + boardView = new StarBattleView((StarBattleBoard) currentBoard); + addBoardListener(boardView); } @Override diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java new file mode 100644 index 000000000..f7a094397 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java @@ -0,0 +1,36 @@ +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.controller.ElementController; +import edu.rpi.legup.model.gameboard.PuzzleElement; + +import java.awt.event.MouseEvent; + +public class StarBattleController extends ElementController { + @Override + public void changeCell(MouseEvent e, PuzzleElement data) { + StarBattleCell cell = (StarBattleCell) data; + if (e.getButton() == MouseEvent.BUTTON1) { + if (e.isControlDown()) { + this.boardView.getSelectionPopupMenu().show(boardView, this.boardView.getCanvas().getX() + e.getX(), this.boardView.getCanvas().getY() + e.getY()); + } + else { + if (cell.getData() == 0) { + data.setData(-3); + } + else { + data.setData(cell.getData() + 1); + } + } + } + else { + if (e.getButton() == MouseEvent.BUTTON3) { + if (cell.getData() == -3) { + data.setData(0); + } + else { + data.setData(cell.getData() - 1); + } + } + } + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleElementView.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleElementView.java new file mode 100644 index 000000000..a88773a06 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleElementView.java @@ -0,0 +1,46 @@ +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.ui.boardview.GridElementView; + +import java.awt.*; + +public class StarBattleElementView extends GridElementView { + + public StarBattleElementView(StarBattleCell cell) { + super(cell); + } + + @Override + public StarBattleCell getPuzzleElement() { + return (StarBattleCell) super.getPuzzleElement(); + } + + @Override + public void drawElement(Graphics2D graphics2D) { + StarBattleCell cell = (StarBattleCell) puzzleElement; + StarBattleCellType type = cell.getType(); + if (type == StarBattleCellType.STAR) { + graphics2D.setColor(Color.LIGHT_GRAY); + graphics2D.fillRect(location.x, location.y, size.width, size.height); + graphics2D.drawImage(StarBattleView.STAR, location.x, location.y, size.width, size.height, Color.WHITE, null); + graphics2D.setColor(Color.BLACK); + graphics2D.drawRect(location.x, location.y, size.width, size.height); + } else if (type == StarBattleCellType.BLACK) { + graphics2D.setStroke(new BasicStroke(1)); + graphics2D.setColor(Color.BLACK); + graphics2D.fillRect(location.x, location.y, size.width, size.height); + } else if (type == StarBattleCellType.WHITE) { + graphics2D.setStroke(new BasicStroke(1)); + graphics2D.setColor(Color.WHITE); + graphics2D.fillRect(location.x, location.y, size.width, size.height); + graphics2D.setColor(Color.BLACK); + graphics2D.drawRect(location.x, location.y, size.width, size.height); + } else if (type == StarBattleCellType.UNKNOWN) { + graphics2D.setStroke(new BasicStroke(1)); + graphics2D.setColor(Color.LIGHT_GRAY); + graphics2D.fillRect(location.x, location.y, size.width, size.height); + graphics2D.setColor(Color.BLACK); + graphics2D.drawRect(location.x, location.y, size.width, size.height); + } + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java new file mode 100644 index 000000000..e69de29bb From 973f041a5ec3fd67d40406a5d6c39c7be7655267 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 23 Feb 2024 20:19:39 -0500 Subject: [PATCH 15/67] Added View file --- .../puzzle/starbattle/StarBattleView.java | 55 +++++++++++++++++++ 1 file changed, 55 insertions(+) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java index e69de29bb..b79b7743a 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java @@ -0,0 +1,55 @@ +package edu.rpi.legup.puzzle.starbattle; + +import java.io.IOException; + +import javax.imageio.ImageIO; + +import org.apache.logging.log4j.LogManager; +import org.apache.logging.log4j.Logger; + +import edu.rpi.legup.puzzle.nurikabe.NurikabeBoard; +import edu.rpi.legup.puzzle.nurikabe.NurikabeView; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleController; +import edu.rpi.legup.puzzle.starbattle.StarBattleElementView; +import edu.rpi.legup.puzzle.starbattle.StarBattleView; +import edu.rpi.legup.ui.boardview.GridBoardView; + +import edu.rpi.legup.controller.BoardController; +import edu.rpi.legup.model.gameboard.CaseBoard; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.ui.boardview.ElementView; +import java.awt.*; +import java.util.ArrayList; + +public class StarBattleView extends GridBoardView { + private final static Logger LOGGER = LogManager.getLogger(StarBattleView.class.getName()); + + static Image STAR; + + static { + try { + STAR = ImageIO.read(ClassLoader.getSystemResourceAsStream("edu/rpi/legup/images/starbattle/star.png")); + } + catch (IOException e) { + LOGGER.error("Failed to open StarBattle images"); + } + } + + public StarBattleView(StarBattleBoard board) { + super(new BoardController(), new StarBattleController(), board.getDimension()); + + for (PuzzleElement puzzleElement : board.getPuzzleElements()) { + StarBattleCell cell = (StarBattleCell) puzzleElement; + Point loc = cell.getLocation(); + StarBattleElementView elementView = new StarBattleElementView(cell); + elementView.setIndex(cell.getIndex()); + elementView.setSize(elementSize); + elementView.setLocation(new Point(loc.x * elementSize.width, loc.y * elementSize.height)); + elementViews.add(elementView); + } + } + + +} From 3fe6695c1ed01db14c2dcc7ef2a26d8aa3484ff8 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 27 Feb 2024 16:50:04 -0500 Subject: [PATCH 16/67] Create StarOrEmptyCaseRule.java Created skeleton of class for Star or Empty case rule. --- .../starbattle/rules/StarOrEmptyCaseRule.java | 78 +++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java new file mode 100644 index 000000000..a30823faa --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java @@ -0,0 +1,78 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.rules.CaseRule; +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.CaseBoard; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +import java.util.ArrayList; + +public class StarOrEmptyCaseRule extends CaseRule { + + public StarOrEmptyCaseRule() { + super("STBL-CASE-0002", + "Star or Empty", + "Each unknown space is either a star or empty.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the {@link TreeTransition} logically follows from the parent node using this rule. This method is + * the one that should overridden in child classes. + * + * @param transition transition to check + * @return null if the child node logically follow from the parent node, otherwise error message + */ + @Override + public String checkRuleRaw(TreeTransition transition) { + //TODO: implement this + return null; + } + + @Override + public CaseBoard getCaseBoard(Board board) { + StarBattleBoard starBattleBoard = (StarBattleBoard) board.copy(); + CaseBoard caseBoard = new CaseBoard(starBattleBoard, this); + starBattleBoard.setModifiable(false); + for (PuzzleElement element : starBattleBoard.getPuzzleElements()) { + if (((StarBattleCell) element).getType() == StarBattleCellType.UNKNOWN) { + caseBoard.addPickableElement(element); + } + } + return caseBoard; + } + + /** + * Gets the possible cases at a specific location based on this case rule + * + * @param board the current board state + * @param puzzleElement equivalent puzzleElement + * @return a list of elements the specified could be + */ + @Override + public ArrayList getCases(Board board, PuzzleElement puzzleElement) { + ArrayList cases = new ArrayList<>(); + Board case1 = board.copy(); + PuzzleElement data1 = case1.getPuzzleElement(puzzleElement); + data1.setData(StarBattleCellType.STAR); + case1.addModifiedData(data1); + cases.add(case1); + + Board case2 = board.copy(); + PuzzleElement data2 = case2.getPuzzleElement(puzzleElement); + data2.setData(StarBattleCellType.BLACK); + case2.addModifiedData(data2); + cases.add(case2); + + return cases; + } + + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + return null; + } +} From e677a6eec68aa48ebe8fe121923f979b227baf2f Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Tue, 27 Feb 2024 16:50:36 -0500 Subject: [PATCH 17/67] Adding Region files --- .../rpi/legup/model/gameboard/GridRegion.java | 53 +++++++++++++++++++ .../puzzle/starbattle/StarBattleRegion.java | 9 ++++ 2 files changed, 62 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/model/gameboard/GridRegion.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java diff --git a/src/main/java/edu/rpi/legup/model/gameboard/GridRegion.java b/src/main/java/edu/rpi/legup/model/gameboard/GridRegion.java new file mode 100644 index 000000000..6718ab6f4 --- /dev/null +++ b/src/main/java/edu/rpi/legup/model/gameboard/GridRegion.java @@ -0,0 +1,53 @@ +package edu.rpi.legup.model.gameboard; + +import java.util.ArrayList; +import java.util.List; + +public abstract class GridRegion { + + protected List regionCells; + + /** + * Region Constructor + */ + public GridRegion() { + this.regionCells = new ArrayList<>(); + } + + /** + * Adds the cell to the region + * @param cell cell to be added to the region + */ + public void addCell(T cell) { + regionCells.add(cell); + } + + /** + * Removes the cell from the region + * @param cell cell to be remove from the region + */ + public void removeCell(T cell) { + regionCells.remove(cell); + } + + /** + * Returns the list of cells in the region + * @return list of cells in region + */ + public List getCells() { + return regionCells; + } + + /** + * Returns the number of cells in the region + * @return number of cells in the region + */ + public int getSize(){ + return regionCells.size(); + } + + /* + public void colorRegion(){} + */ + +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java new file mode 100644 index 000000000..68a25bc3b --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java @@ -0,0 +1,9 @@ +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.model.gameboard.GridRegion; + +public class StarBattleRegion extends GridRegion{ + public StarBattleRegion() { + super(); + } +} From 23df2a15c08736e4902b1093a9e6eb92084c2ef7 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Tue, 27 Feb 2024 17:26:50 -0500 Subject: [PATCH 18/67] Added the first XML puzzle file to be read later. --- .../6x6 Star Battle 1star Normal.xml | 68 +++++++++++++++++++ 1 file changed, 68 insertions(+) create mode 100644 puzzles files/starbattle/6x6 Star Battle 1star Normal.xml diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal.xml b/puzzles files/starbattle/6x6 Star Battle 1star Normal.xml new file mode 100644 index 000000000..4d9f8b631 --- /dev/null +++ b/puzzles files/starbattle/6x6 Star Battle 1star Normal.xml @@ -0,0 +1,68 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From 47337b7e5457b5991be30616b38e618ae0ffaa3e Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 27 Feb 2024 17:31:09 -0500 Subject: [PATCH 19/67] Implement Surround Star Direct Rule Wrote an implementation for checkRuleRawAt for Surround Star Direct Rule. --- ...le => ClashingOrbitContradictionRule.java} | 0 .../rules/SurroundStarDirectRule.java | 19 +++++++++++++++++++ 2 files changed, 19 insertions(+) rename src/main/java/edu/rpi/legup/puzzle/starbattle/rules/{ClashingOrbitContradictionRule => ClashingOrbitContradictionRule.java} (100%) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java similarity index 100% rename from src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule rename to src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java index 932ef7ddd..33f148e94 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java @@ -2,9 +2,13 @@ import edu.rpi.legup.model.gameboard.Board; import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.ContradictionRule; import edu.rpi.legup.model.rules.DirectRule; import edu.rpi.legup.model.tree.TreeNode; import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.nurikabe.NurikabeBoard; +import edu.rpi.legup.puzzle.nurikabe.NurikabeType; +import edu.rpi.legup.puzzle.nurikabe.rules.NoNumberContradictionRule; import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; import edu.rpi.legup.puzzle.starbattle.StarBattleCell; import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; @@ -29,7 +33,22 @@ public SurroundStarDirectRule() { */ @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + StarBattleBoard board = (StarBattleBoard) transition.getBoard(); + StarBattleBoard origBoard = (StarBattleBoard) transition.getParents().get(0).getBoard(); + ContradictionRule contraRule = new ClashingOrbitContradictionRule(); + StarBattleCell cell = (StarBattleCell) board.getPuzzleElement(puzzleElement); + + if (cell.getType() != StarBattleCellType.BLACK) { + return "Only black cells are allowed for this rule!"; + } + + StarBattleBoard modified = (StarBattleBoard) origBoard.copy(); + //TODO: please for the love of god make a copy method for star battle board because this isn't actually going to work otherwise + modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.STAR); + if (contraRule.checkContradictionAt(modified, puzzleElement) != null) { + return "Black cells must be placed adjacent to a star!"; + } return null; } From 024aa4f94e6b083ed008f7369713e7259519fcdc Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 27 Feb 2024 17:32:33 -0500 Subject: [PATCH 20/67] Changed files to java instead of text. --- ...ewStarsContradictionRule => TooFewStarsContradictionRule.java} | 0 ...yStarsContradictionRule => TooManyStarsContradictionRule.java} | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename src/main/java/edu/rpi/legup/puzzle/starbattle/rules/{TooFewStarsContradictionRule => TooFewStarsContradictionRule.java} (100%) rename src/main/java/edu/rpi/legup/puzzle/starbattle/rules/{TooManyStarsContradictionRule => TooManyStarsContradictionRule.java} (100%) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java similarity index 100% rename from src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule rename to src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java similarity index 100% rename from src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule rename to src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java From 2d9dc038b9b14e029acf4e48a5d62bcc3ac7bb4b Mon Sep 17 00:00:00 2001 From: Sarah Date: Tue, 27 Feb 2024 18:47:58 -0500 Subject: [PATCH 21/67] created add star case rule and reference sheet to keep track of the rules --- .../starbattle/rules/AddStarCaseRule.java | 57 +++++++++++++++++++ .../rules/starbattle_reference_sheet.txt | 15 +++++ 2 files changed, 72 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/AddStarCaseRule.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/AddStarCaseRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/AddStarCaseRule.java new file mode 100644 index 000000000..d945f5be9 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/AddStarCaseRule.java @@ -0,0 +1,57 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.CaseBoard; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.CaseRule; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.lightup.LightUpBoard; +import edu.rpi.legup.puzzle.lightup.LightUpCell; +import edu.rpi.legup.puzzle.starbattle.*; + +import java.awt.*; +import java.util.*; +import java.util.List; + +public class AddStarCaseRule extends CaseRule { + public AddStarCaseRule() { + super("STBL-CASE-0001", + "Add Star", + "Different ways a region's star number can be satisfied", + ""); + } + + @Override + public CaseBoard getCaseBoard(Board board) { + StarBattleBoard starbattleBoard = (StarBattleBoard) board.copy(); + CaseBoard caseBoard = new CaseBoard(starbattleBoard, this); + + return caseBoard; + } + + /** + * Gets the possible cases at a specific location based on this case rule + * + * @param board the current board state + * @param puzzleElement the cell to determine the possible cases for + * @return a list of elements the specified spot could be + */ + @Override + public List getCases(Board board, PuzzleElement puzzleElement) { + StarBattleBoard starbattleBoard = (StarBattleBoard) board; + // take selected spot, check if there are any stars in that row, column, and region + + // do we want all possible cases, that seems like a lot + return null; + } + + @Override + public String checkRuleRaw(TreeTransition transition) { + return null; + } + + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + return null; + } +} \ No newline at end of file diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt new file mode 100644 index 000000000..70e81bb73 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt @@ -0,0 +1,15 @@ +Case Rules: +Add Star: STBL-CASE-0001 +Star or Empty: STBL-CASE-0002 + +Basic Rules: +Blackout: STBL-BASC-0001 +Finish With Stars: STBL-BASC-0002 +Regions Within Rows or Columns: STBL-BASC-0003 +Rows or Columns Within Regions: STBL-BASC-0004 +Surround Star: STBL-BASC-0005 + +Contradiction Rules: +Too Many Stars: STBL-CONT-0001 +Too Few Stars: STBL-CONT-0002 +Clashing Orbit: STBL-CONT-0003 \ No newline at end of file From 7f2406c99d01075d5e25afe5279c08d874a0608b Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Tue, 12 Mar 2024 16:34:56 -0400 Subject: [PATCH 22/67] New puzzle --- ....xml => 6x6 Star Battle 1star Normal1.xml} | 0 .../6x6 Star Battle 1star Normal2.xml | 68 +++++++++++++++++++ 2 files changed, 68 insertions(+) rename puzzles files/starbattle/{6x6 Star Battle 1star Normal.xml => 6x6 Star Battle 1star Normal1.xml} (100%) create mode 100644 puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal.xml b/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml similarity index 100% rename from puzzles files/starbattle/6x6 Star Battle 1star Normal.xml rename to puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml b/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml new file mode 100644 index 000000000..cd34805e5 --- /dev/null +++ b/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml @@ -0,0 +1,68 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From 555890adc30f1f658be9a45e6ae4cc2a2cae362a Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 12 Mar 2024 17:02:07 -0400 Subject: [PATCH 23/67] Add Regions to StarBattleBoard --- .../puzzle/starbattle/StarBattleBoard.java | 24 +++++++++++++++++++ .../puzzle/starbattle/StarBattleRegion.java | 8 +++++++ .../rules/SurroundStarDirectRule.java | 3 --- 3 files changed, 32 insertions(+), 3 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java index a32197fa7..143fbaca6 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java @@ -8,11 +8,13 @@ public class StarBattleBoard extends GridBoard { private int size; + protected List regions; //private ArrayList groupSizes; public StarBattleBoard(int size) { super(size, size); this.size = size; + this.regions = new ArrayList<>(); } @Override @@ -44,6 +46,28 @@ public Set getCol(int colNum) { } return column; } + + public StarBattleRegion getRegion(int index) { + if (index >= size) { + return null; + } + return regions.get(index); + } + + public StarBattleBoard copy() { + StarBattleBoard copy = new StarBattleBoard(size); + for (int x = 0; x < this.dimension.width; x++) { + for (int y = 0; y < this.dimension.height; y++) { + copy.setCell(x, y, getCell(x, y).copy()); + } + if (x < this.regions.size()) + copy.regions.add(this.getRegion(x).copy()); + } + for (PuzzleElement e : modifiedData) { + copy.getPuzzleElement(e).setModifiable(false); + } + return copy; + } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java index 68a25bc3b..ebae5ce86 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java @@ -6,4 +6,12 @@ public class StarBattleRegion extends GridRegion{ public StarBattleRegion() { super(); } + + public StarBattleRegion copy() { + StarBattleRegion copy = new StarBattleRegion(); + for (StarBattleCell c: regionCells) { + copy.addCell(c.copy()); + } + return copy; + } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java index 33f148e94..1565bff9d 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java @@ -6,9 +6,6 @@ import edu.rpi.legup.model.rules.DirectRule; import edu.rpi.legup.model.tree.TreeNode; import edu.rpi.legup.model.tree.TreeTransition; -import edu.rpi.legup.puzzle.nurikabe.NurikabeBoard; -import edu.rpi.legup.puzzle.nurikabe.NurikabeType; -import edu.rpi.legup.puzzle.nurikabe.rules.NoNumberContradictionRule; import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; import edu.rpi.legup.puzzle.starbattle.StarBattleCell; import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; From 1f72e6ab5d9a9532fc76cbf6fe74b44b5eaca8e1 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Tue, 12 Mar 2024 17:03:49 -0400 Subject: [PATCH 24/67] Changed some elements in puzzles and added importer --- puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml | 2 +- puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml | 2 +- .../edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java | 0 .../java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java | 2 -- 4 files changed, 2 insertions(+), 4 deletions(-) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml b/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml index 4d9f8b631..ce1330437 100644 --- a/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml +++ b/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml @@ -1,7 +1,7 @@ - + diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml b/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml index cd34805e5..10eb04aa3 100644 --- a/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml +++ b/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml @@ -1,7 +1,7 @@ - + diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java new file mode 100644 index 000000000..e69de29bb diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java index b79b7743a..fdf0df221 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java @@ -7,8 +7,6 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; -import edu.rpi.legup.puzzle.nurikabe.NurikabeBoard; -import edu.rpi.legup.puzzle.nurikabe.NurikabeView; import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; import edu.rpi.legup.puzzle.starbattle.StarBattleCell; import edu.rpi.legup.puzzle.starbattle.StarBattleController; From be30904d9a2e0b9a7b9dce1deb0b8ec65b29bca6 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 12 Mar 2024 17:10:49 -0400 Subject: [PATCH 25/67] Blackout rule check method --- .../starbattle/rules/BlackoutDirectRule.java | 16 ++++++++++++++++ .../starbattle/rules/SurroundStarDirectRule.java | 1 - 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java index 3c89b0800..57a5688f2 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java @@ -2,6 +2,7 @@ import edu.rpi.legup.model.gameboard.Board; import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.ContradictionRule; import edu.rpi.legup.model.rules.DirectRule; import edu.rpi.legup.model.tree.TreeNode; import edu.rpi.legup.model.tree.TreeTransition; @@ -30,6 +31,21 @@ public BlackoutDirectRule() { @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + StarBattleBoard board = (StarBattleBoard) transition.getBoard(); + StarBattleBoard origBoard = (StarBattleBoard) transition.getParents().get(0).getBoard(); + ContradictionRule contraRule = new TooManyStarsContradictionRule(); + + StarBattleCell cell = (StarBattleCell) board.getPuzzleElement(puzzleElement); + + if (cell.getType() != StarBattleCellType.BLACK) { + return "Only black cells are allowed for this rule!"; + } + + StarBattleBoard modified = (StarBattleBoard) origBoard.copy(); + modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.STAR); + if (contraRule.checkContradictionAt(modified, puzzleElement) != null) { + return "Black cells must be placed in a row, region, or column with enough stars!"; + } return null; } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java index 1565bff9d..0c46da09c 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java @@ -41,7 +41,6 @@ public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElem } StarBattleBoard modified = (StarBattleBoard) origBoard.copy(); - //TODO: please for the love of god make a copy method for star battle board because this isn't actually going to work otherwise modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.STAR); if (contraRule.checkContradictionAt(modified, puzzleElement) != null) { return "Black cells must be placed adjacent to a star!"; From f37f4ef5d78a8e675272c351b11f899fea97b3db Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 12 Mar 2024 17:16:49 -0400 Subject: [PATCH 26/67] FinishWithStars rule check method --- .../rules/FinishWithStarsDirectRule.java | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java index d2711eced..53ab8d947 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java @@ -2,6 +2,7 @@ import edu.rpi.legup.model.gameboard.Board; import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.ContradictionRule; import edu.rpi.legup.model.rules.DirectRule; import edu.rpi.legup.model.tree.TreeNode; import edu.rpi.legup.model.tree.TreeTransition; @@ -30,6 +31,21 @@ public FinishWithStarsDirectRule() { @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + StarBattleBoard board = (StarBattleBoard) transition.getBoard(); + StarBattleBoard origBoard = (StarBattleBoard) transition.getParents().get(0).getBoard(); + ContradictionRule contraRule = new TooFewStarsContradictionRule(); + + StarBattleCell cell = (StarBattleCell) board.getPuzzleElement(puzzleElement); + + if (cell.getType() != StarBattleCellType.STAR) { + return "Only star cells are allowed for this rule!"; + } + + StarBattleBoard modified = (StarBattleBoard) origBoard.copy(); + modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.BLACK); + if (contraRule.checkContradictionAt(modified, puzzleElement) != null) { + return "Star cells must be placed in a row, region, or column without extra spaces!"; + } return null; } From 9fe76cbb915f25fd098e0a3533d068b26d3662d1 Mon Sep 17 00:00:00 2001 From: Sarah Date: Tue, 12 Mar 2024 17:20:37 -0400 Subject: [PATCH 27/67] Deleted Add Star Case Rule, started on Clashing Orbit --- .../starbattle/rules/AddStarCaseRule.java | 57 ------------------- .../rules/ClashingOrbitContradictionRule.java | 25 ++++++++ .../rules/TooManyStarsContradictionRule.java | 5 ++ 3 files changed, 30 insertions(+), 57 deletions(-) delete mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/AddStarCaseRule.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/AddStarCaseRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/AddStarCaseRule.java deleted file mode 100644 index d945f5be9..000000000 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/AddStarCaseRule.java +++ /dev/null @@ -1,57 +0,0 @@ -package edu.rpi.legup.puzzle.starbattle.rules; - -import edu.rpi.legup.model.gameboard.Board; -import edu.rpi.legup.model.gameboard.CaseBoard; -import edu.rpi.legup.model.gameboard.PuzzleElement; -import edu.rpi.legup.model.rules.CaseRule; -import edu.rpi.legup.model.tree.TreeTransition; -import edu.rpi.legup.puzzle.lightup.LightUpBoard; -import edu.rpi.legup.puzzle.lightup.LightUpCell; -import edu.rpi.legup.puzzle.starbattle.*; - -import java.awt.*; -import java.util.*; -import java.util.List; - -public class AddStarCaseRule extends CaseRule { - public AddStarCaseRule() { - super("STBL-CASE-0001", - "Add Star", - "Different ways a region's star number can be satisfied", - ""); - } - - @Override - public CaseBoard getCaseBoard(Board board) { - StarBattleBoard starbattleBoard = (StarBattleBoard) board.copy(); - CaseBoard caseBoard = new CaseBoard(starbattleBoard, this); - - return caseBoard; - } - - /** - * Gets the possible cases at a specific location based on this case rule - * - * @param board the current board state - * @param puzzleElement the cell to determine the possible cases for - * @return a list of elements the specified spot could be - */ - @Override - public List getCases(Board board, PuzzleElement puzzleElement) { - StarBattleBoard starbattleBoard = (StarBattleBoard) board; - // take selected spot, check if there are any stars in that row, column, and region - - // do we want all possible cases, that seems like a lot - return null; - } - - @Override - public String checkRuleRaw(TreeTransition transition) { - return null; - } - - @Override - public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { - return null; - } -} \ No newline at end of file diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java index 2eb584ea1..c15593796 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java @@ -9,6 +9,8 @@ import edu.rpi.legup.puzzle.starbattle.StarBattleCell; import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; +import java.awt.*; + public class ClashingOrbitContradictionRule extends ContradictionRule { public ClashingOrbitContradictionRule() { @@ -28,6 +30,29 @@ public ClashingOrbitContradictionRule() { */ @Override public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { + StarBattleBoard starbattleBoard = (StarBattleBoard) board; + StarBattleCell cell = (StarBattleCell) starbattleBoard.getPuzzleElement(puzzleElement); + + if (cell.getType() != StarBattleCellType.STAR) { + return super.getNoContradictionMessage(); + } + + // check neighboring cells for a star + Point location = cell.getLocation(); + + int rowStart = Math.max( location.x - 1, 0 ); + int rowEnd = Math.min( location.x + 1, starbattleBoard.getSize() - 1 ); + int colStart = Math.max( location.y - 1, 0 ); + int colEnd = Math.min( location.y + 1, starbattleBoard.getSize() - 1 ); + + for (int row = rowStart; rowStart <= rowEnd; row++) { + for (int col = colStart; colStart <= colEnd; col++) { + if (starbattleBoard.getCell(row, col).getType() == StarBattleCellType.STAR) { + return null; + } + } + } + return super.getNoContradictionMessage(); } } \ No newline at end of file diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java index 56cd71ba7..09f6e8136 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java @@ -28,6 +28,11 @@ public TooManyStarsContradictionRule() { */ @Override public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { + // check row + + // check column + + // check region return super.getNoContradictionMessage(); } } \ No newline at end of file From 78069d4600b81872eb365df557a1d0dac7d2d875 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Tue, 12 Mar 2024 17:26:48 -0400 Subject: [PATCH 28/67] Added importer --- .../puzzle/starbattle/StarBattleImporter.java | 110 ++++++++++++++++++ 1 file changed, 110 insertions(+) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java index e69de29bb..161b03bf0 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java @@ -0,0 +1,110 @@ +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.model.PuzzleImporter; +import edu.rpi.legup.save.InvalidFileFormatException; +import org.w3c.dom.Element; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; +import java.awt.*; +import java.awt.Point; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + + +public class StarBattleImporter extends PuzzleImporter{ + + + public StarBattleImporter(StarBattle starbattle) { + super(starbattle); + } + + private Map regionsMap; + + /** + * Puzzle setting to support row and column inputs + */ + @Override + public boolean acceptsRowsAndColumnsInput() { + return true; + } + + /** + * Puzzle setting to disable support for text input + */ + @Override + public boolean acceptsTextInput() { + return false; + } + + + /** + * Constructs empty StarBattle gameboard as per the provided dimensions + * @param rows number of rows and columns for the gameboard + */ + @Override + public void initializeBoard(int rows, int columns) { + StarBattleBoard StarBattleBoard = new StarBattleBoard(rows); + puzzle.setCurrentBoard(StarBattleBoard); + } + + + + /** + * Constructs StarBattle gameboard + * @param node xml document node + * @throws InvalidFileFormatException if file is invalid + */ + @Override + public void initializeBoard(Node node) throws InvalidFileFormatException { + Element puzzleElement = (Element) node; + + NodeList regionNodes = puzzleElement.getElementsByTagName("region"); + if (regionNodes.getLength() == 0) { + throw new InvalidFileFormatException("No regions found for the StarBattle puzzle"); + } + + int size = Integer.parseInt(puzzleElement.getAttribute("size")); + + StarBattleBoard StarBattleBoard = new StarBattleBoard(size); // Initialize the board with width and height from XML + + for (int i = 0; i < regionNodes.getLength(); i++) { + Element regionElement = (Element) regionNodes.item(i); + NodeList cellNodes = regionElement.getElementsByTagName("cell"); + + for (int j = 0; j < cellNodes.getLength(); j++) { + Element cellElement = (Element) cellNodes.item(j); + int x = Integer.parseInt(cellElement.getAttribute("x")); + int y = Integer.parseInt(cellElement.getAttribute("y")); + int value = Integer.parseInt(cellElement.getAttribute("value")); + + Point cellPoint = new Point(x, y); + + // Create the StarBattleCell with the cell type and value + StarBattleCell cell = new StarBattleCell(value, cellPoint, i, size); + cell.setIndex(y * size + x); // Calculate the index based on size + cell.setModifiable(true); + + // Add the cell to the board + StarBattleBoard.setCell(x, y, cell); + } + } + + puzzle.setCurrentBoard(StarBattleBoard); + } + + + + /** + * Initialize board via string of statements. + * @throws UnsupportedOperationException since StarBattle does not support text input + */ + @Override + public void initializeBoard(String[] statements) throws UnsupportedOperationException { + throw new UnsupportedOperationException("Ripple Effect does not accept text input"); + } +} + + + From 4b75d469117c407b38fed10edcfc090618ecdc3b Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 15 Mar 2024 16:18:53 -0400 Subject: [PATCH 29/67] Fix clashing orbit bugs --- .../starbattle/rules/ClashingOrbitContradictionRule.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java index c15593796..79453803b 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java @@ -45,9 +45,10 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { int colStart = Math.max( location.y - 1, 0 ); int colEnd = Math.min( location.y + 1, starbattleBoard.getSize() - 1 ); - for (int row = rowStart; rowStart <= rowEnd; row++) { - for (int col = colStart; colStart <= colEnd; col++) { - if (starbattleBoard.getCell(row, col).getType() == StarBattleCellType.STAR) { + for (int row = rowStart; row <= rowEnd; row++) { + for (int col = colStart; col <= colEnd; col++) { + if (starbattleBoard.getCell(row, col).getType() == StarBattleCellType.STAR + && (row != location.x || col != location.y)) { return null; } } From 900854f83aa48368507d4a569b21eb27376cb698 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 15 Mar 2024 16:31:01 -0400 Subject: [PATCH 30/67] Add puzzle number field to board --- .../edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java index 143fbaca6..dedcc0a58 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java @@ -8,12 +8,14 @@ public class StarBattleBoard extends GridBoard { private int size; + private int puzzleNum; protected List regions; //private ArrayList groupSizes; - public StarBattleBoard(int size) { + public StarBattleBoard(int size, int num) { super(size, size); this.size = size; + this.puzzleNum = num; this.regions = new ArrayList<>(); } @@ -39,6 +41,8 @@ public Set getRow(int rowNum) { return row; } + public int getPuzzleNumber() { return puzzleNum; } + public Set getCol(int colNum) { Set column = new HashSet<>(); for (int i = 0; i < size; i++) { @@ -55,7 +59,7 @@ public StarBattleRegion getRegion(int index) { } public StarBattleBoard copy() { - StarBattleBoard copy = new StarBattleBoard(size); + StarBattleBoard copy = new StarBattleBoard(size, puzzleNum); for (int x = 0; x < this.dimension.width; x++) { for (int y = 0; y < this.dimension.height; y++) { copy.setCell(x, y, getCell(x, y).copy()); From e0db10322ebcd8bbb74678c972453db1e4578498 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 15 Mar 2024 16:57:22 -0400 Subject: [PATCH 31/67] Contradiction check function for too few stars --- .../puzzle/starbattle/StarBattleBoard.java | 4 +++ .../puzzle/starbattle/StarBattleCell.java | 2 ++ .../rules/TooFewStarsContradictionRule.java | 31 +++++++++++++++++++ 3 files changed, 37 insertions(+) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java index dedcc0a58..cebe7d2db 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java @@ -58,6 +58,10 @@ public StarBattleRegion getRegion(int index) { return regions.get(index); } + public StarBattleRegion getRegion(StarBattleCell cell) { + return getRegion(cell.getGroupIndex()); + } + public StarBattleBoard copy() { StarBattleBoard copy = new StarBattleBoard(size, puzzleNum); for (int x = 0; x < this.dimension.width; x++) { diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java index 2e89649e2..4296c8230 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java @@ -24,6 +24,8 @@ public StarBattleCell(int value, Point location, int groupIndex, int size) { this.max = size; } + public int getGroupIndex() { return groupIndex; } + @Override public void setType(Element e, MouseEvent m) { switch (e.getElementID()) { diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java index a063b2b6b..af30a5e18 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java @@ -8,6 +8,9 @@ import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; import edu.rpi.legup.puzzle.starbattle.StarBattleCell; import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; +import edu.rpi.legup.puzzle.starbattle.StarBattleRegion; + +import java.awt.*; public class TooFewStarsContradictionRule extends ContradictionRule { @@ -28,6 +31,34 @@ public TooFewStarsContradictionRule() { */ @Override public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { + StarBattleBoard sbBoard = (StarBattleBoard) board; + StarBattleCell cell = (StarBattleCell) puzzleElement; + Point location = cell.getLocation(); + int column = location.x; + int row = location.y; + int rowCount = 0; + int columnCount = 0; + for (int i = 0; i < sbBoard.getSize(); ++i) { + if (sbBoard.getCell(row, i).getType() != StarBattleCellType.BLACK) { + ++rowCount; + } + if (sbBoard.getCell(i, column).getType() != StarBattleCellType.BLACK) { + ++columnCount; + } + } + if (rowCount < sbBoard.getPuzzleNumber() || columnCount < sbBoard.getPuzzleNumber()) { + return null; + } + StarBattleRegion region = sbBoard.getRegion(cell); + int regionCount = 0; + for (StarBattleCell c: region.getCells()) { + if (c.getType() != StarBattleCellType.BLACK) { + ++regionCount; + } + } + if (regionCount < sbBoard.getPuzzleNumber()) { + return null; + } return super.getNoContradictionMessage(); } } \ No newline at end of file From e8375dbbe4531fc1589b38bdeb402f013969649b Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 15 Mar 2024 17:10:58 -0400 Subject: [PATCH 32/67] Changed importer and xml files to include puzzleNum --- .../6x6 Star Battle 1star Normal1.xml | 1 + .../6x6 Star Battle 1star Normal2.xml | 1 + .../puzzle/starbattle/StarBattleBoard.java | 7 ++++++ .../puzzle/starbattle/StarBattleImporter.java | 24 ++++++++++--------- 4 files changed, 22 insertions(+), 11 deletions(-) diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml b/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml index ce1330437..4163e15a9 100644 --- a/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml +++ b/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml @@ -1,6 +1,7 @@ + diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml b/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml index 10eb04aa3..29307fb58 100644 --- a/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml +++ b/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml @@ -1,6 +1,7 @@ + diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java index dedcc0a58..e80e49399 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java @@ -17,6 +17,9 @@ public StarBattleBoard(int size, int num) { this.size = size; this.puzzleNum = num; this.regions = new ArrayList<>(); + for (int i = 0; i < size; i++) { + regions.add(new StarBattleRegion()); + } } @Override @@ -58,6 +61,10 @@ public StarBattleRegion getRegion(int index) { return regions.get(index); } + public void setRegion(int regionNum, StarBattleRegion region) { + regions.set(regionNum, region); + } + public StarBattleBoard copy() { StarBattleBoard copy = new StarBattleBoard(size, puzzleNum); for (int x = 0; x < this.dimension.width; x++) { diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java index 161b03bf0..32090172e 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java @@ -13,7 +13,7 @@ import java.util.Map; -public class StarBattleImporter extends PuzzleImporter{ +public class StarBattleImporter extends PuzzleImporter{ public StarBattleImporter(StarBattle starbattle) { @@ -38,14 +38,14 @@ public boolean acceptsTextInput() { return false; } - - /** + /** * Constructs empty StarBattle gameboard as per the provided dimensions * @param rows number of rows and columns for the gameboard */ @Override public void initializeBoard(int rows, int columns) { - StarBattleBoard StarBattleBoard = new StarBattleBoard(rows); + int puzzle_num = 1; + StarBattleBoard StarBattleBoard = new StarBattleBoard(rows, puzzle_num); puzzle.setCurrentBoard(StarBattleBoard); } @@ -59,19 +59,19 @@ public void initializeBoard(int rows, int columns) { @Override public void initializeBoard(Node node) throws InvalidFileFormatException { Element puzzleElement = (Element) node; - + int puzzle_num = Integer.parseInt(puzzleElement.getAttribute("puzzle_num")); NodeList regionNodes = puzzleElement.getElementsByTagName("region"); - if (regionNodes.getLength() == 0) { - throw new InvalidFileFormatException("No regions found for the StarBattle puzzle"); - } - int size = Integer.parseInt(puzzleElement.getAttribute("size")); + if (regionNodes.getLength() != size) { + throw new InvalidFileFormatException("Not the current amount of regions in the puzzle."); + } - StarBattleBoard StarBattleBoard = new StarBattleBoard(size); // Initialize the board with width and height from XML + StarBattleBoard StarBattleBoard = new StarBattleBoard(size, puzzle_num); // Initialize the board with width and height from XML for (int i = 0; i < regionNodes.getLength(); i++) { Element regionElement = (Element) regionNodes.item(i); NodeList cellNodes = regionElement.getElementsByTagName("cell"); + StarBattleRegion region_i = new StarBattleRegion(); for (int j = 0; j < cellNodes.getLength(); j++) { Element cellElement = (Element) cellNodes.item(j); @@ -88,7 +88,9 @@ public void initializeBoard(Node node) throws InvalidFileFormatException { // Add the cell to the board StarBattleBoard.setCell(x, y, cell); + region_i.addCell(cell); } + StarBattleBoard.setRegion(i, region_i); } puzzle.setCurrentBoard(StarBattleBoard); @@ -102,7 +104,7 @@ public void initializeBoard(Node node) throws InvalidFileFormatException { */ @Override public void initializeBoard(String[] statements) throws UnsupportedOperationException { - throw new UnsupportedOperationException("Ripple Effect does not accept text input"); + throw new UnsupportedOperationException("Star Battle does not accept text input"); } } From 52c1aee25da3e80586cbdba537be411fa798fff9 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 15 Mar 2024 17:27:54 -0400 Subject: [PATCH 33/67] Rule check method for star or empty case rule --- .../starbattle/rules/StarOrEmptyCaseRule.java | 27 ++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java index a30823faa..1bbbe3e92 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java @@ -5,11 +5,14 @@ import edu.rpi.legup.model.gameboard.CaseBoard; import edu.rpi.legup.model.gameboard.PuzzleElement; import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.nurikabe.NurikabeCell; +import edu.rpi.legup.puzzle.nurikabe.NurikabeType; import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; import edu.rpi.legup.puzzle.starbattle.StarBattleCell; import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; import java.util.ArrayList; +import java.util.List; public class StarOrEmptyCaseRule extends CaseRule { @@ -29,7 +32,29 @@ public StarOrEmptyCaseRule() { */ @Override public String checkRuleRaw(TreeTransition transition) { - //TODO: implement this + List childTransitions = transition.getParents().get(0).getChildren(); + if (childTransitions.size() != 2) { + return super.getInvalidUseOfRuleMessage() + ": This case rule must have 2 children."; + } + + TreeTransition case1 = childTransitions.get(0); + TreeTransition case2 = childTransitions.get(1); + if (case1.getBoard().getModifiedData().size() != 1 || + case2.getBoard().getModifiedData().size() != 1) { + return super.getInvalidUseOfRuleMessage() + ": This case rule must have 1 modified cell for each case."; + } + + StarBattleCell mod1 = (StarBattleCell) case1.getBoard().getModifiedData().iterator().next(); + StarBattleCell mod2 = (StarBattleCell) case2.getBoard().getModifiedData().iterator().next(); + if (!mod1.getLocation().equals(mod2.getLocation())) { + return super.getInvalidUseOfRuleMessage() + ": This case rule must modify the same cell for each case."; + } + + if (!((mod1.getType() == StarBattleCellType.STAR && mod2.getType() == StarBattleCellType.BLACK) || + (mod2.getType() == StarBattleCellType.STAR && mod1.getType() == StarBattleCellType.BLACK))) { + return super.getInvalidUseOfRuleMessage() + ": This case rule must create a star cell and a black cell."; + } + return null; } From 08492e146af252e83bc9737cba59ebae996df286 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 15 Mar 2024 17:40:46 -0400 Subject: [PATCH 34/67] Added exporter --- .../puzzle/starbattle/StarBattleExporter.java | 36 +++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleExporter.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleExporter.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleExporter.java new file mode 100644 index 000000000..dcf149d0f --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleExporter.java @@ -0,0 +1,36 @@ +package edu.rpi.legup.puzzle.starbattle; + +import edu.rpi.legup.model.PuzzleExporter; +import edu.rpi.legup.model.gameboard.PuzzleElement; + +import org.w3c.dom.Document; + +public class StarBattleExporter extends PuzzleExporter { + public StarBattleExporter(StarBattle starbattle) { + super(starbattle); + } + + @Override + protected org.w3c.dom.Element createBoardElement(Document newDocument) { + StarBattleBoard board = (StarBattleBoard) puzzle.getTree().getRootNode().getBoard(); + org.w3c.dom.Element boardElement = newDocument.createElement("board"); + boardElement.setAttribute("size", String.valueOf(board.getSize())); + boardElement.setAttribute("puzzle_num", String.valueOf(board.getPuzzleNumber())); + for (PuzzleElement puzzleElement : board.getPuzzleElements()) { + org.w3c.dom.Element regionsElement = newDocument.createElement("region"); + StarBattleRegion region = (StarBattleRegion) puzzleElement; + org.w3c.dom.Element cellsElement = newDocument.createElement("cells"); + for (PuzzleElement puzzleElement : region.getPuzzleElements()) { + StarBattleCell cell = (StarBattleCell) puzzleElement; + if (cell.getData() != -2) { + org.w3c.dom.Element cellElement = puzzle.getFactory().exportCell(newDocument, puzzleElement); + cellsElement.appendChild(cellElement); + } + regionsElement.appendChild(cellsElement); + } + boardElement.appendChild(regionsElement); + } + + return boardElement; + } +} From cbe163513b4897bee86a96a209122199b65413be Mon Sep 17 00:00:00 2001 From: Sarah Date: Fri, 15 Mar 2024 20:17:17 -0400 Subject: [PATCH 35/67] Updated TooManyStarsContradictionRule --- .../rules/ClashingOrbitContradictionRule.java | 1 + .../rules/TooManyStarsContradictionRule.java | 63 +++++++++++++++++++ 2 files changed, 64 insertions(+) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java index 79453803b..28398143e 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java @@ -33,6 +33,7 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { StarBattleBoard starbattleBoard = (StarBattleBoard) board; StarBattleCell cell = (StarBattleCell) starbattleBoard.getPuzzleElement(puzzleElement); + // Contradiction rule can only be applied to cells with a star in it if (cell.getType() != StarBattleCellType.STAR) { return super.getNoContradictionMessage(); } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java index 09f6e8136..9165a2b1a 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java @@ -5,11 +5,17 @@ import edu.rpi.legup.model.rules.ContradictionRule; import edu.rpi.legup.model.tree.TreeNode; import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.lightup.LightUpCell; import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; import edu.rpi.legup.puzzle.starbattle.StarBattleCell; import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; +import edu.rpi.legup.puzzle.starbattle.StarBattleRegion; + +import java.awt.*; +import java.util.List; public class TooManyStarsContradictionRule extends ContradictionRule { + private final String INVALID_USE_MESSAGE = "Contradiction must be a cell containing a star."; public TooManyStarsContradictionRule() { super("STBL-CONT-0001", @@ -28,11 +34,68 @@ public TooManyStarsContradictionRule() { */ @Override public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { + StarBattleBoard starbattleBoard = (StarBattleBoard) board; + StarBattleCell cell = (StarBattleCell) starbattleBoard.getPuzzleElement(puzzleElement); + Point location = cell.getLocation(); + int starCount = 0; + int puzzleNum = starbattleBoard.getPuzzleNumber(); + + if (cell.getType() != StarBattleCellType.STAR) { + return super.getNoContradictionMessage(); + } + // check row + for (int i = location.x - 1; i >= 0; i--) { // to the left of selected cell + StarBattleCell check = starbattleBoard.getCell(i, location.y); + if (check.getType() == StarBattleCellType.STAR) { + starCount++; + if (starCount >= puzzleNum) { + break; + } + } + } + + for (int i = location.x + 1; i < starbattleBoard.getWidth(); i++) { // to the right of selected cell + StarBattleCell check = starbattleBoard.getCell(i, location.y); + if (check.getType() == StarBattleCellType.STAR) { + starCount++; + if (starCount >= puzzleNum) { + break; + } + } + } // check column + starCount = 0; + for (int j = location.y - 1; j >= 0; j--) { // above selected cell + StarBattleCell check = starbattleBoard.getCell(location.x, j); + if (check.getType() == StarBattleCellType.STAR) { + starCount++; + if (starCount >= puzzleNum) { + break; + } + } + } + + for (int j = location.y + 1; j < starbattleBoard.getWidth(); j++) { // below selected cell + StarBattleCell check = starbattleBoard.getCell(location.x, j); + if (check.getType() == StarBattleCellType.STAR) { + starCount++; + if (starCount >= puzzleNum) { + break; + } + } + } // check region + starCount = 0; + List reg; + /* + for (go through list of regions) { + check all spots in region + } + */ + return super.getNoContradictionMessage(); } } \ No newline at end of file From dd8b3fef0047ce78fefb691bd5e87885ac47645b Mon Sep 17 00:00:00 2001 From: Sarah Date: Tue, 19 Mar 2024 16:39:38 -0400 Subject: [PATCH 36/67] added region check to TooManyStarsContradictionRule --- .../rules/TooManyStarsContradictionRule.java | 28 +++++++++++++------ 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java index 9165a2b1a..a3044a8cb 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java @@ -15,7 +15,7 @@ import java.util.List; public class TooManyStarsContradictionRule extends ContradictionRule { - private final String INVALID_USE_MESSAGE = "Contradiction must be a cell containing a star."; + private final String INVALID_USE_MESSAGE = "Contradiction must be applied to a cell containing a star."; public TooManyStarsContradictionRule() { super("STBL-CONT-0001", @@ -39,9 +39,10 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { Point location = cell.getLocation(); int starCount = 0; int puzzleNum = starbattleBoard.getPuzzleNumber(); + boolean valid = false; if (cell.getType() != StarBattleCellType.STAR) { - return super.getNoContradictionMessage(); + return INVALID_USE_MESSAGE; } // check row @@ -50,6 +51,7 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { if (check.getType() == StarBattleCellType.STAR) { starCount++; if (starCount >= puzzleNum) { + valid = true; break; } } @@ -60,6 +62,7 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { if (check.getType() == StarBattleCellType.STAR) { starCount++; if (starCount >= puzzleNum) { + valid = true; break; } } @@ -72,6 +75,7 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { if (check.getType() == StarBattleCellType.STAR) { starCount++; if (starCount >= puzzleNum) { + valid = true; break; } } @@ -82,6 +86,7 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { if (check.getType() == StarBattleCellType.STAR) { starCount++; if (starCount >= puzzleNum) { + valid = true; break; } } @@ -89,13 +94,20 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { // check region starCount = 0; - List reg; - /* - for (go through list of regions) { - check all spots in region + StarBattleRegion reg = starbattleBoard.getRegion(cell); + List cellList = reg.getCells(); // list of cells + for (int k = 0; k < cellList.size(); k++) { + if (cellList.get(k) == cell) { + continue; + } else if (cellList.get(k).getType() == StarBattleCellType.STAR) { + valid = true; + break; + } } - */ - return super.getNoContradictionMessage(); + if (valid == true) { + return super.getNoContradictionMessage(); + } + return null; } } \ No newline at end of file From 2555896041d62b86b86656145cce6fde2106492a Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 19 Mar 2024 16:41:27 -0400 Subject: [PATCH 37/67] Split up row/column and region containment rules into separate rules for rows and columns --- .../puzzle/starbattle/StarBattleBoard.java | 2 +- .../rules/ColumnsWithinRegionsDirectRule.java | 43 +++++++++++++++++++ .../rules/FinishWithStarsDirectRule.java | 2 +- ...va => RegionsWithinColumnsDirectRule.java} | 9 ++-- .../rules/RegionsWithinRowsDirectRule.java | 43 +++++++++++++++++++ ....java => RowsWithinRegionsDirectRule.java} | 9 ++-- .../rules/SurroundStarDirectRule.java | 2 +- .../rules/starbattle_reference_sheet.txt | 10 +++-- 8 files changed, 101 insertions(+), 19 deletions(-) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java rename src/main/java/edu/rpi/legup/puzzle/starbattle/rules/{RegionsWithinRowsColumnsDirectRule.java => RegionsWithinColumnsDirectRule.java} (81%) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java rename src/main/java/edu/rpi/legup/puzzle/starbattle/rules/{RowsColumnsWithinRegionsDirectRule.java => RowsWithinRegionsDirectRule.java} (82%) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java index a2a93ff8e..7accc86e3 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java @@ -60,7 +60,7 @@ public StarBattleRegion getRegion(int index) { } return regions.get(index); } - + public StarBattleRegion getRegion(StarBattleCell cell) { return getRegion(cell.getGroupIndex()); } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java new file mode 100644 index 000000000..05c9a2868 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java @@ -0,0 +1,43 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.DirectRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; + +public class ColumnsWithinRegionsDirectRule extends DirectRule { + public ColumnsWithinRegionsDirectRule() { + super("STBL-BASC-0002", + "Columns Within Regions", + "If a number of columns is fully contained by an equal number of regions, spaces of other columns in those regions must be black.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the child node logically follows from the parent node + * at the specific puzzleElement index using this rule + * + * @param transition transition to check + * @param puzzleElement equivalent puzzleElement + * @return null if the child node logically follow from the parent node at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + + return null; + } + + /** + * Creates a transition {@link Board} that has this rule applied to it using the {@link TreeNode}. + * + * @param node tree node used to create default transition board + * @return default board or null if this rule cannot be applied to this tree node + */ + @Override + public Board getDefaultBoard(TreeNode node) { + + return null; + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java index 53ab8d947..13050a5ac 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java @@ -13,7 +13,7 @@ public class FinishWithStarsDirectRule extends DirectRule { public FinishWithStarsDirectRule() { - super("STBL-BASC-0002", + super("STBL-BASC-0003", "Finish With Stars", "Unknown spaces must be stars if there are just enough in a row, column, or region to satisfy the puzzle number.", "INSERT IMAGE NAME HERE"); diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsColumnsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java similarity index 81% rename from src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsColumnsDirectRule.java rename to src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java index 81645a2ad..84787e704 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsColumnsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java @@ -5,13 +5,10 @@ import edu.rpi.legup.model.rules.DirectRule; import edu.rpi.legup.model.tree.TreeNode; import edu.rpi.legup.model.tree.TreeTransition; -import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; -import edu.rpi.legup.puzzle.starbattle.StarBattleCell; -import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; -public class RegionsWithinRowsColumnsDirectRule extends DirectRule { - public RegionsWithinRowsColumnsDirectRule() { - super("STBL-BASC-0003", +public class RegionsWithinColumnsDirectRule extends DirectRule { + public RegionsWithinColumnsDirectRule() { + super("STBL-BASC-0004", "Regions Within Rows/Columns", "If a number of regions is fully contained by an equal number of rows or columns, spaces of other regions in those rows or columns must be black.", "INSERT IMAGE NAME HERE"); diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java new file mode 100644 index 000000000..e71c97df9 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java @@ -0,0 +1,43 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.DirectRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; + +public class RegionsWithinRowsDirectRule extends DirectRule { + public RegionsWithinRowsDirectRule() { + super("STBL-BASC-0005", + "Regions Within Rows/Columns", + "If a number of regions is fully contained by an equal number of rows or columns, spaces of other regions in those rows or columns must be black.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the child node logically follows from the parent node + * at the specific puzzleElement index using this rule + * + * @param transition transition to check + * @param puzzleElement equivalent puzzleElement + * @return null if the child node logically follow from the parent node at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + + return null; + } + + /** + * Creates a transition {@link Board} that has this rule applied to it using the {@link TreeNode}. + * + * @param node tree node used to create default transition board + * @return default board or null if this rule cannot be applied to this tree node + */ + @Override + public Board getDefaultBoard(TreeNode node) { + + return null; + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsColumnsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java similarity index 82% rename from src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsColumnsWithinRegionsDirectRule.java rename to src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java index 53a7b27ee..128c44095 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsColumnsWithinRegionsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java @@ -5,13 +5,10 @@ import edu.rpi.legup.model.rules.DirectRule; import edu.rpi.legup.model.tree.TreeNode; import edu.rpi.legup.model.tree.TreeTransition; -import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; -import edu.rpi.legup.puzzle.starbattle.StarBattleCell; -import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; -public class RowsColumnsWithinRegionsDirectRule extends DirectRule { - public RowsColumnsWithinRegionsDirectRule() { - super("STBL-BASC-0004", +public class RowsWithinRegionsDirectRule extends DirectRule { + public RowsWithinRegionsDirectRule() { + super("STBL-BASC-0006", "Rows/Columns Within Regions", "If a number of rows or columns is fully contained by an equal number of regions, spaces of other rows or columns, respectively, in those regions must be black.", "INSERT IMAGE NAME HERE"); diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java index 0c46da09c..a5533104c 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java @@ -13,7 +13,7 @@ public class SurroundStarDirectRule extends DirectRule { public SurroundStarDirectRule() { - super("STBL-BASC-0005", + super("STBL-BASC-0007", "Surround Star", "Any space adjacent to a star must be black.", "INSERT IMAGE NAME HERE"); diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt index 70e81bb73..958440a71 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt @@ -4,10 +4,12 @@ Star or Empty: STBL-CASE-0002 Basic Rules: Blackout: STBL-BASC-0001 -Finish With Stars: STBL-BASC-0002 -Regions Within Rows or Columns: STBL-BASC-0003 -Rows or Columns Within Regions: STBL-BASC-0004 -Surround Star: STBL-BASC-0005 +Columns Within Regions: STBL-BASC-0002 +Finish With Stars: STBL-BASC-0003 +Regions Within Columns: STBL-BASC-0004 +Regions Within Rows: STBL-BASC-0005 +Rows Within Regions: STBL-BASC-0006 +Surround Star: STBL-BASC-0007 Contradiction Rules: Too Many Stars: STBL-CONT-0001 From 489f31d4c53180d2fe7e0d61396fb13d8e99df51 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Tue, 19 Mar 2024 17:09:49 -0400 Subject: [PATCH 38/67] Create StarBattleCellFactory.java --- .../edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java new file mode 100644 index 000000000..e69de29bb From 7674f2225dc23ba409b56a76f5e7ec939dc6f3e8 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 19 Mar 2024 17:19:19 -0400 Subject: [PATCH 39/67] Start implementing columns within regions direct rule --- .../puzzle/starbattle/StarBattleBoard.java | 11 +++++++ .../puzzle/starbattle/StarBattleRegion.java | 9 ++++++ .../rules/ColumnsWithinRegionsDirectRule.java | 29 ++++++++++++++++++- 3 files changed, 48 insertions(+), 1 deletion(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java index 7accc86e3..764e952ea 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java @@ -69,6 +69,17 @@ public void setRegion(int regionNum, StarBattleRegion region) { regions.set(regionNum, region); } + public int columnStars(int columnIndex) { + int stars = 0; + if (columnIndex < size) { + for (StarBattleCell c: this.getCol(columnIndex)) { + if (c.getType() == StarBattleCellType.STAR) + ++stars; + } + } + return stars; + } + public StarBattleBoard copy() { StarBattleBoard copy = new StarBattleBoard(size, puzzleNum); for (int x = 0; x < this.dimension.width; x++) { diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java index ebae5ce86..099cabfcd 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleRegion.java @@ -14,4 +14,13 @@ public StarBattleRegion copy() { } return copy; } + + public int numStars() { + int stars = 0; + for (StarBattleCell c: regionCells) { + if (c.getType() == StarBattleCellType.STAR) + ++stars; + } + return stars; + } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java index 05c9a2868..efd8b47ca 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java @@ -1,10 +1,16 @@ package edu.rpi.legup.puzzle.starbattle.rules; import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.GridRegion; import edu.rpi.legup.model.gameboard.PuzzleElement; import edu.rpi.legup.model.rules.DirectRule; import edu.rpi.legup.model.tree.TreeNode; import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +import java.util.HashSet; public class ColumnsWithinRegionsDirectRule extends DirectRule { public ColumnsWithinRegionsDirectRule() { @@ -25,7 +31,28 @@ public ColumnsWithinRegionsDirectRule() { */ @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { - + StarBattleBoard board = (StarBattleBoard) transition.getBoard(); + StarBattleCell cell = (StarBattleCell) board.getPuzzleElement(puzzleElement); + if (cell.getType() != StarBattleCellType.BLACK) { + return "Only black cells are allowed for this rule!"; + } + //which columns are within the region + HashSet columns = new HashSet(); + int columnStars = 0; + for (PuzzleElement r: board.getRegion(cell).getCells()) { + columns.add(((StarBattleCell) r).getLocation().x); + } + //which regions are the columns within + HashSet regions = new HashSet(); + int regionStars = 0; + for (Integer c: columns) { + for (int i = 0; i < board.getSize(); ++i) { + if (regions.add(board.getCell(c,i).getGroupIndex())) { + regionStars += board.getRegion(board.getCell(c,i)).numStars(); + } + } + } + // are the columns and regions missing an equal amount of stars return null; } From 53a5004f00ab5e81a954c89223e98c412559bf87 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 19 Mar 2024 17:28:54 -0400 Subject: [PATCH 40/67] Continue columns within regions --- .../legup/puzzle/starbattle/StarBattleBoard.java | 11 +++++++++++ .../rules/ColumnsWithinRegionsDirectRule.java | 14 +++++++++++--- 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java index 764e952ea..ce04f31a6 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleBoard.java @@ -80,6 +80,17 @@ public int columnStars(int columnIndex) { return stars; } + public int rowStars(int rowIndex) { + int stars = 0; + if (rowIndex < size) { + for (StarBattleCell c: this.getRow(rowIndex)) { + if (c.getType() == StarBattleCellType.STAR) + ++stars; + } + } + return stars; + } + public StarBattleBoard copy() { StarBattleBoard copy = new StarBattleBoard(size, puzzleNum); for (int x = 0; x < this.dimension.width; x++) { diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java index efd8b47ca..086a8f82e 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java @@ -11,6 +11,7 @@ import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; import java.util.HashSet; +import java.util.Set; public class ColumnsWithinRegionsDirectRule extends DirectRule { public ColumnsWithinRegionsDirectRule() { @@ -31,19 +32,23 @@ public ColumnsWithinRegionsDirectRule() { */ @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + //TODO: fix this StarBattleBoard board = (StarBattleBoard) transition.getBoard(); StarBattleCell cell = (StarBattleCell) board.getPuzzleElement(puzzleElement); if (cell.getType() != StarBattleCellType.BLACK) { return "Only black cells are allowed for this rule!"; } //which columns are within the region - HashSet columns = new HashSet(); + Set columns = new HashSet(); int columnStars = 0; for (PuzzleElement r: board.getRegion(cell).getCells()) { - columns.add(((StarBattleCell) r).getLocation().x); + int column = ((StarBattleCell) r).getLocation().x; + if (columns.add(column)) { + columnStars += board.columnStars(column); + } } //which regions are the columns within - HashSet regions = new HashSet(); + Set regions = new HashSet(); int regionStars = 0; for (Integer c: columns) { for (int i = 0; i < board.getSize(); ++i) { @@ -53,6 +58,9 @@ public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElem } } // are the columns and regions missing an equal amount of stars + if (board.getPuzzleNumber() * columns.size() - columnStars != board.getPuzzleNumber() * regions.size() - regionStars) { + return "The number of missing stars in the "; + } return null; } From eee926b4c51e049d07e8ba30618208979bb51b24 Mon Sep 17 00:00:00 2001 From: Sarah Date: Wed, 20 Mar 2024 13:52:28 -0400 Subject: [PATCH 41/67] reworked TooManyStars logic --- .../8x8 Star Battle 1star Normal1.xml | 10 ++++++ .../rules/TooManyStarsContradictionRule.java | 33 ++++++++++--------- 2 files changed, 27 insertions(+), 16 deletions(-) create mode 100644 puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml diff --git a/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml b/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml new file mode 100644 index 000000000..ba237102f --- /dev/null +++ b/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml @@ -0,0 +1,10 @@ + + + + + + + + + + \ No newline at end of file diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java index a3044a8cb..7777ff5a4 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java @@ -39,30 +39,30 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { Point location = cell.getLocation(); int starCount = 0; int puzzleNum = starbattleBoard.getPuzzleNumber(); - boolean valid = false; + boolean valid = true; if (cell.getType() != StarBattleCellType.STAR) { - return INVALID_USE_MESSAGE; + return this.INVALID_USE_MESSAGE; } // check row - for (int i = location.x - 1; i >= 0; i--) { // to the left of selected cell + for (int i = location.x - 1; i >= 0; i--) { StarBattleCell check = starbattleBoard.getCell(i, location.y); if (check.getType() == StarBattleCellType.STAR) { starCount++; if (starCount >= puzzleNum) { - valid = true; + valid = false; break; } } } - for (int i = location.x + 1; i < starbattleBoard.getWidth(); i++) { // to the right of selected cell + for (int i = location.x + 1; i < starbattleBoard.getWidth(); i++) { StarBattleCell check = starbattleBoard.getCell(i, location.y); if (check.getType() == StarBattleCellType.STAR) { starCount++; if (starCount >= puzzleNum) { - valid = true; + valid = false; break; } } @@ -70,23 +70,23 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { // check column starCount = 0; - for (int j = location.y - 1; j >= 0; j--) { // above selected cell + for (int j = location.y - 1; j >= 0; j--) { StarBattleCell check = starbattleBoard.getCell(location.x, j); if (check.getType() == StarBattleCellType.STAR) { starCount++; if (starCount >= puzzleNum) { - valid = true; + valid = false; break; } } } - for (int j = location.y + 1; j < starbattleBoard.getWidth(); j++) { // below selected cell + for (int j = location.y + 1; j < starbattleBoard.getWidth(); j++) { StarBattleCell check = starbattleBoard.getCell(location.x, j); if (check.getType() == StarBattleCellType.STAR) { starCount++; if (starCount >= puzzleNum) { - valid = true; + valid = false; break; } } @@ -97,15 +97,16 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { StarBattleRegion reg = starbattleBoard.getRegion(cell); List cellList = reg.getCells(); // list of cells for (int k = 0; k < cellList.size(); k++) { - if (cellList.get(k) == cell) { - continue; - } else if (cellList.get(k).getType() == StarBattleCellType.STAR) { - valid = true; - break; + if (cellList.get(k).getType() == StarBattleCellType.STAR) { + starCount++; + if (starCount >= puzzleNum) { + valid = false; + break; + } } } - if (valid == true) { + if (valid == false) { return super.getNoContradictionMessage(); } return null; From 59c8d6f9563caff709e20e84a4bc15f8d04a5600 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 22 Mar 2024 15:10:18 -0400 Subject: [PATCH 42/67] Exporter and Cell Factory started --- .../starbattle/StarBattleCellFactory.java | 66 +++++++++++++++++++ .../puzzle/starbattle/StarBattleExporter.java | 11 ++-- 2 files changed, 70 insertions(+), 7 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java index e69de29bb..06c879836 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java @@ -0,0 +1,66 @@ +package edu.rpi.legup.puzzle.starbattle; +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.ElementFactory; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.puzzle.nurikabe.NurikabeCell; +import edu.rpi.legup.puzzle.starbattle.starbattleBoard; +import edu.rpi.legup.puzzle.starbattle.starbattleCell; +import edu.rpi.legup.save.InvalidFileFormatException; +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; + +import java.awt.*; + +public class StarBattleCellFactory extends ElementFactory { + @Override + public StarBattleCell importCell(Node node, Board board) throws InvalidFileFormatException { + try { + if (!node.getNodeName().equalsIgnoreCase("cell")) { + throw new InvalidFileFormatException("starbattle Factory: unknown puzzleElement puzzleElement"); + } + + StarBattleBoard starbattleBoard = (StarBattleBoard) board; + int size = starbattleBoard.getSize(); + + NamedNodeMap attributeList = node.getAttributes(); + int value = Integer.valueOf(attributeList.getNamedItem("value").getNodeValue()); + int x = Integer.valueOf(attributeList.getNamedItem("x").getNodeValue()); + int y = Integer.valueOf(attributeList.getNamedItem("y").getNodeValue()); + int groupIndex = Integer.valueOf(attributeList.getNamedItem("groupIndex").getNodeValue()); + if (x >= size || y >= size) { + throw new InvalidFileFormatException("starbattle Factory: cell location out of bounds"); + } + if (groupIndex >= size || groupIndex < 0) { + throw new InvalidFileFormatException("starbattle Factory: not in a valid region"); + } + if (value != 0) { //ALL INITIAL PUZZLES ARE BLANK, SUBJECT TO CHANGE + throw new InvalidFileFormatException("starbattle Factory: cell unknown value"); + } + + StarBattleCell cell = new StarBattleCell(value, new Point(x, y), groupIndex, size); + cell.setIndex(y * size + x); + return cell; + } + catch (NumberFormatException e1) { + throw new InvalidFileFormatException("starbattle Factory: unknown value where integer expected"); + } catch (NullPointerException e2) { + throw new InvalidFileFormatException("starbattle Factory: could not find attribute(s)"); + } + } + + public org.w3c.dom.Element exportCell(Document document, PuzzleElement puzzleElement) { + org.w3c.dom.Element cellElement = document.createElement("cell"); + + NurikabeCell cell = (NurikabeCell) puzzleElement; + Point loc = cell.getLocation(); + + cellElement.setAttribute("value", String.valueOf(cell.getData())); + cellElement.setAttribute("x", String.valueOf(loc.x)); + cellElement.setAttribute("y", String.valueOf(loc.y)); + + return cellElement; + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleExporter.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleExporter.java index dcf149d0f..58fb41e63 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleExporter.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleExporter.java @@ -1,7 +1,6 @@ package edu.rpi.legup.puzzle.starbattle; import edu.rpi.legup.model.PuzzleExporter; -import edu.rpi.legup.model.gameboard.PuzzleElement; import org.w3c.dom.Document; @@ -16,14 +15,12 @@ protected org.w3c.dom.Element createBoardElement(Document newDocument) { org.w3c.dom.Element boardElement = newDocument.createElement("board"); boardElement.setAttribute("size", String.valueOf(board.getSize())); boardElement.setAttribute("puzzle_num", String.valueOf(board.getPuzzleNumber())); - for (PuzzleElement puzzleElement : board.getPuzzleElements()) { + for (StarBattleRegion sb_region : board.regions) { org.w3c.dom.Element regionsElement = newDocument.createElement("region"); - StarBattleRegion region = (StarBattleRegion) puzzleElement; org.w3c.dom.Element cellsElement = newDocument.createElement("cells"); - for (PuzzleElement puzzleElement : region.getPuzzleElements()) { - StarBattleCell cell = (StarBattleCell) puzzleElement; - if (cell.getData() != -2) { - org.w3c.dom.Element cellElement = puzzle.getFactory().exportCell(newDocument, puzzleElement); + for (StarBattleCell cell : sb_region.getCells()) { + if (cell.getData() == 0) { + org.w3c.dom.Element cellElement = puzzle.getFactory().exportCell(newDocument, cell); cellsElement.appendChild(cellElement); } regionsElement.appendChild(cellsElement); From 9d5362b94680e212e7c0521e48de106e12ab021b Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 22 Mar 2024 16:12:50 -0400 Subject: [PATCH 43/67] Update StarBattleCellFactory.java --- .../rpi/legup/puzzle/starbattle/StarBattleCellFactory.java | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java index 06c879836..827934111 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java @@ -2,9 +2,8 @@ import edu.rpi.legup.model.gameboard.Board; import edu.rpi.legup.model.gameboard.ElementFactory; import edu.rpi.legup.model.gameboard.PuzzleElement; -import edu.rpi.legup.puzzle.nurikabe.NurikabeCell; -import edu.rpi.legup.puzzle.starbattle.starbattleBoard; -import edu.rpi.legup.puzzle.starbattle.starbattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; import edu.rpi.legup.save.InvalidFileFormatException; import org.w3c.dom.Document; import org.w3c.dom.Element; @@ -54,7 +53,7 @@ public StarBattleCell importCell(Node node, Board board) throws InvalidFileForma public org.w3c.dom.Element exportCell(Document document, PuzzleElement puzzleElement) { org.w3c.dom.Element cellElement = document.createElement("cell"); - NurikabeCell cell = (NurikabeCell) puzzleElement; + StarBattleCell cell = (StarBattleCell) puzzleElement; Point loc = cell.getLocation(); cellElement.setAttribute("value", String.valueOf(cell.getData())); From 0deae52edcb4cc5315db11626dc46f4d0d6697fe Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 22 Mar 2024 16:26:53 -0400 Subject: [PATCH 44/67] Deleted extraneous libraries, and finished going thru guide of implementing puzzles Hopefully we get puzzles up soon. --- .../java/edu/rpi/legup/puzzle/starbattle/StarBattle.java | 8 ++++---- .../legup/puzzle/starbattle/StarBattleCellFactory.java | 4 ---- .../rpi/legup/puzzle/starbattle/StarBattleImporter.java | 9 --------- .../edu/rpi/legup/puzzle/starbattle/StarBattleView.java | 2 +- 4 files changed, 5 insertions(+), 18 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java index 78800916e..760fa88b2 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattle.java @@ -5,12 +5,12 @@ public class StarBattle extends Puzzle { public StarBattle() { super(); - //this.name = "StarBattle"; + this.name = "StarBattle"; - //this.importer = new StarBattleImporter(this); - //this.exporter = new StarBattleExporter(this); + this.importer = new StarBattleImporter(this); + this.exporter = new StarBattleExporter(this); - //this.factory = new StarBattleCellFactory(); + this.factory = new StarBattleCellFactory(); } @Override diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java index 827934111..92ea8abf6 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java @@ -2,14 +2,10 @@ import edu.rpi.legup.model.gameboard.Board; import edu.rpi.legup.model.gameboard.ElementFactory; import edu.rpi.legup.model.gameboard.PuzzleElement; -import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; -import edu.rpi.legup.puzzle.starbattle.StarBattleCell; import edu.rpi.legup.save.InvalidFileFormatException; import org.w3c.dom.Document; -import org.w3c.dom.Element; import org.w3c.dom.NamedNodeMap; import org.w3c.dom.Node; -import org.w3c.dom.NodeList; import java.awt.*; diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java index 32090172e..fa0e065ee 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleImporter.java @@ -5,12 +5,7 @@ import org.w3c.dom.Element; import org.w3c.dom.Node; import org.w3c.dom.NodeList; -import java.awt.*; import java.awt.Point; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; public class StarBattleImporter extends PuzzleImporter{ @@ -20,8 +15,6 @@ public StarBattleImporter(StarBattle starbattle) { super(starbattle); } - private Map regionsMap; - /** * Puzzle setting to support row and column inputs */ @@ -49,8 +42,6 @@ public void initializeBoard(int rows, int columns) { puzzle.setCurrentBoard(StarBattleBoard); } - - /** * Constructs StarBattle gameboard * @param node xml document node diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java index fdf0df221..a39770d85 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java @@ -31,7 +31,7 @@ public class StarBattleView extends GridBoardView { STAR = ImageIO.read(ClassLoader.getSystemResourceAsStream("edu/rpi/legup/images/starbattle/star.png")); } catch (IOException e) { - LOGGER.error("Failed to open StarBattle images"); + LOGGER.error("Failed to open starbattle image."); } } From 2ba4382b9243a73a7bf1b58d91c8d1d79349bc07 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 22 Mar 2024 17:12:02 -0400 Subject: [PATCH 45/67] Implemented rule check function for region/row/column overlap rules --- .../rules/ColumnsWithinRegionsDirectRule.java | 46 ++++++--- .../rules/ColumnsWithinRowsDirectRule.java | 97 +++++++++++++++++++ .../rules/RegionsWithinColumnsDirectRule.java | 8 +- .../rules/RegionsWithinRowsDirectRule.java | 7 +- .../rules/RowsWithinColumnsDirectRule.java | 51 ++++++++++ .../rules/RowsWithinRegionsDirectRule.java | 55 ++++++++++- 6 files changed, 240 insertions(+), 24 deletions(-) create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java create mode 100644 src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java index 086a8f82e..980f6db19 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java @@ -32,34 +32,50 @@ public ColumnsWithinRegionsDirectRule() { */ @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { - //TODO: fix this + //assumption: the rule has been applied to its fullest extent and the rows and regions + //are now mutually encompassing StarBattleBoard board = (StarBattleBoard) transition.getBoard(); StarBattleCell cell = (StarBattleCell) board.getPuzzleElement(puzzleElement); if (cell.getType() != StarBattleCellType.BLACK) { return "Only black cells are allowed for this rule!"; } - //which columns are within the region + //the columns that are contained Set columns = new HashSet(); - int columnStars = 0; - for (PuzzleElement r: board.getRegion(cell).getCells()) { - int column = ((StarBattleCell) r).getLocation().x; - if (columns.add(column)) { - columnStars += board.columnStars(column); - } - } - //which regions are the columns within + //the regions that contain them Set regions = new HashSet(); + //columns and regions to process + Set columnsToCheck = new HashSet(); + Set regionsToCheck = new HashSet(); + int columnStars = 0; int regionStars = 0; - for (Integer c: columns) { - for (int i = 0; i < board.getSize(); ++i) { - if (regions.add(board.getCell(c,i).getGroupIndex())) { - regionStars += board.getRegion(board.getCell(c,i)).numStars(); + regions.add(cell.getGroupIndex()); + regionsToCheck.add(cell.getGroupIndex()); + + while (!columnsToCheck.isEmpty() || !regionsToCheck.isEmpty()) { + for (int r: regionsToCheck) { + regionStars += board.getRegion(r).numStars(); + for (PuzzleElement c: board.getRegion(r).getCells()) { + int column = ((StarBattleCell) c).getLocation().x; + if (columns.add(column)) { + columnsToCheck.add(column); + } + } + regionsToCheck.remove(r); + } + for (int c: columnsToCheck) { + columnStars += board.columnStars(c); + for (int i = 0; i < board.getSize(); ++i) { + int region = board.getCell(c,i).getGroupIndex(); + if (regions.add(region)) { + regionsToCheck.add(region); + } } + columnsToCheck.remove(c); } } // are the columns and regions missing an equal amount of stars if (board.getPuzzleNumber() * columns.size() - columnStars != board.getPuzzleNumber() * regions.size() - regionStars) { - return "The number of missing stars in the "; + return "The number of missing stars in the columns and regions must be equal and every extraneous cell must be black!"; } return null; } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java new file mode 100644 index 000000000..4c8eb6915 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java @@ -0,0 +1,97 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.DirectRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +import java.util.HashSet; +import java.util.Set; + +public class ColumnsWithinRowsDirectRule extends DirectRule { + + public ColumnsWithinRowsDirectRule() { + super("STBL-BASC-XXXX", + "Columns Within Rows", + "If a number of columns is fully contained by an equal number of rows, spaces of other columns in those rows must be black.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the child node logically follows from the parent node + * at the specific puzzleElement index using this rule + * + * @param transition transition to check + * @param puzzleElement equivalent puzzleElement + * @return null if the child node logically follow from the parent node at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + + //assumption: the rule has been applied to its fullest extent and the rows and columns + //are now mutually encompassing + StarBattleBoard board = (StarBattleBoard) transition.getBoard(); + StarBattleCell cell = (StarBattleCell) board.getPuzzleElement(puzzleElement); + if (cell.getType() != StarBattleCellType.BLACK) { + return "Only black cells are allowed for this rule!"; + } + + //the columns that are contained + Set columns = new HashSet(); + //the rows that contain them + Set rows = new HashSet(); + //columns and rows to process + Set columnsToCheck = new HashSet(); + Set rowsToCheck = new HashSet(); + int columnStars = 0; + int rowStars = 0; + int firstRow = cell.getLocation().y; + rows.add(firstRow); + rowsToCheck.add(firstRow); + + while (!columnsToCheck.isEmpty() || !rowsToCheck.isEmpty()) { + for (int r: rowsToCheck) { + rowStars += board.rowStars(r); + for (PuzzleElement c: board.getRow(r)) { + int column = ((StarBattleCell) c).getLocation().x; + if (columns.add(column)) { + columnsToCheck.add(column); + } + } + rowsToCheck.remove(r); + } + for (int c: columnsToCheck) { + columnStars += board.columnStars(c); + for (PuzzleElement r: board.getCol(c)) { + int row = ((StarBattleCell) r).getLocation().y; + if (rows.add(row)) { + rowsToCheck.add(row); + } + } + columnsToCheck.remove(c); + } + } + // are the columns and regions missing an equal amount of stars + if (board.getPuzzleNumber() * columns.size() - columnStars != board.getPuzzleNumber() * rows.size() - rowStars) { + return "The number of missing stars in the columns and rows must be equal and every extraneous cell must be black!"; + } + return null; + } + + /** + * Creates a transition {@link Board} that has this rule applied to it using the {@link TreeNode}. + * + * @param node tree node used to create default transition board + * @return default board or null if this rule cannot be applied to this tree node + */ + @Override + public Board getDefaultBoard(TreeNode node) { + + return null; + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java index 84787e704..74e296522 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java @@ -9,8 +9,8 @@ public class RegionsWithinColumnsDirectRule extends DirectRule { public RegionsWithinColumnsDirectRule() { super("STBL-BASC-0004", - "Regions Within Rows/Columns", - "If a number of regions is fully contained by an equal number of rows or columns, spaces of other regions in those rows or columns must be black.", + "Regions Within Columns", + "If a number of regions is fully contained by an equal number of columns, spaces of other regions in those columns must be black.", "INSERT IMAGE NAME HERE"); } @@ -25,8 +25,8 @@ public RegionsWithinColumnsDirectRule() { */ @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { - - return null; + ColumnsWithinRegionsDirectRule correspondingRule = new ColumnsWithinRegionsDirectRule(); + return correspondingRule.checkRuleRawAt(transition, puzzleElement); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java index e71c97df9..f89e0d63f 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java @@ -9,8 +9,8 @@ public class RegionsWithinRowsDirectRule extends DirectRule { public RegionsWithinRowsDirectRule() { super("STBL-BASC-0005", - "Regions Within Rows/Columns", - "If a number of regions is fully contained by an equal number of rows or columns, spaces of other regions in those rows or columns must be black.", + "Regions Within Rows", + "If a number of regions is fully contained by an equal number of rows, spaces of other regions in those rows must be black.", "INSERT IMAGE NAME HERE"); } @@ -26,7 +26,8 @@ public RegionsWithinRowsDirectRule() { @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { - return null; + RowsWithinRegionsDirectRule correspondingRule = new RowsWithinRegionsDirectRule(); + return correspondingRule.checkRuleRawAt(transition, puzzleElement); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java new file mode 100644 index 000000000..48fb1cd81 --- /dev/null +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java @@ -0,0 +1,51 @@ +package edu.rpi.legup.puzzle.starbattle.rules; + +import edu.rpi.legup.model.gameboard.Board; +import edu.rpi.legup.model.gameboard.PuzzleElement; +import edu.rpi.legup.model.rules.DirectRule; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +import java.util.HashSet; +import java.util.Set; + +public class RowsWithinColumnsDirectRule extends DirectRule { + + public RowsWithinColumnsDirectRule() { + super("STBL-BASC-XXXX", + "Rows Withing Columns", + "If a number of rows is fully contained by an equal number of columns, spaces of other rows in those columns must be black.", + "INSERT IMAGE NAME HERE"); + } + + /** + * Checks whether the child node logically follows from the parent node + * at the specific puzzleElement index using this rule + * + * @param transition transition to check + * @param puzzleElement equivalent puzzleElement + * @return null if the child node logically follow from the parent node at the specified puzzleElement, + * otherwise error message + */ + @Override + public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + + ColumnsWithinRowsDirectRule correspondingRule = new ColumnsWithinRowsDirectRule(); + return correspondingRule.checkRuleRawAt(transition, puzzleElement); + } + + /** + * Creates a transition {@link Board} that has this rule applied to it using the {@link TreeNode}. + * + * @param node tree node used to create default transition board + * @return default board or null if this rule cannot be applied to this tree node + */ + @Override + public Board getDefaultBoard(TreeNode node) { + + return null; + } +} diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java index 128c44095..8cc68d292 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java @@ -5,12 +5,18 @@ import edu.rpi.legup.model.rules.DirectRule; import edu.rpi.legup.model.tree.TreeNode; import edu.rpi.legup.model.tree.TreeTransition; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; + +import java.util.HashSet; +import java.util.Set; public class RowsWithinRegionsDirectRule extends DirectRule { public RowsWithinRegionsDirectRule() { super("STBL-BASC-0006", - "Rows/Columns Within Regions", - "If a number of rows or columns is fully contained by an equal number of regions, spaces of other rows or columns, respectively, in those regions must be black.", + "Rows Within Regions", + "If a number of rows is fully contained by an equal number of regions, spaces of other rows in those regions must be black.", "INSERT IMAGE NAME HERE"); } @@ -26,6 +32,51 @@ public RowsWithinRegionsDirectRule() { @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { + //assumption: the rule has been applied to its fullest extent and the rows and regions + //are now mutually encompassing + StarBattleBoard board = (StarBattleBoard) transition.getBoard(); + StarBattleCell cell = (StarBattleCell) board.getPuzzleElement(puzzleElement); + if (cell.getType() != StarBattleCellType.BLACK) { + return "Only black cells are allowed for this rule!"; + } + //the rows that are contained + Set rows = new HashSet(); + //the regions that contain them + Set regions = new HashSet(); + //rows and regions to process + Set rowsToCheck = new HashSet(); + Set regionsToCheck = new HashSet(); + int rowStars = 0; + int regionStars = 0; + regions.add(cell.getGroupIndex()); + regionsToCheck.add(cell.getGroupIndex()); + + while (!rowsToCheck.isEmpty() || !regionsToCheck.isEmpty()) { + for (int r: regionsToCheck) { + regionStars += board.getRegion(r).numStars(); + for (PuzzleElement ro: board.getRegion(r).getCells()) { + int row = ((StarBattleCell) ro).getLocation().y; + if (rows.add(row)) { + rowsToCheck.add(row); + } + } + regionsToCheck.remove(r); + } + for (int r: rowsToCheck) { + rowStars += board.rowStars(r); + for (int i = 0; i < board.getSize(); ++i) { + int region = board.getCell(i,r).getGroupIndex(); + if (regions.add(region)) { + regionsToCheck.add(region); + } + } + rowsToCheck.remove(r); + } + } + // are the columns and regions missing an equal amount of stars + if (board.getPuzzleNumber() * rows.size() - rowStars != board.getPuzzleNumber() * regions.size() - regionStars) { + return "The number of missing stars in the rows and regions must be equal and every extraneous cell must be black!"; + } return null; } From 49cd17e88546c0f43a14c9c5a4101c6e5a9bb84c Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 22 Mar 2024 17:17:56 -0400 Subject: [PATCH 46/67] Minor changes to direct rules --- .../rules/ColumnsWithinRegionsDirectRule.java | 2 +- .../rules/ColumnsWithinRowsDirectRule.java | 4 ++-- .../starbattle/rules/FinishWithStarsDirectRule.java | 2 +- .../rules/RegionsWithinColumnsDirectRule.java | 4 ++-- .../rules/RegionsWithinRowsDirectRule.java | 4 ++-- .../rules/RowsWithinColumnsDirectRule.java | 4 ++-- .../rules/RowsWithinRegionsDirectRule.java | 4 ++-- .../starbattle/rules/SurroundStarDirectRule.java | 2 +- .../starbattle/rules/starbattle_reference_sheet.txt | 12 +++++++----- 9 files changed, 20 insertions(+), 18 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java index 980f6db19..93fb86dc5 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java @@ -17,7 +17,7 @@ public class ColumnsWithinRegionsDirectRule extends DirectRule { public ColumnsWithinRegionsDirectRule() { super("STBL-BASC-0002", "Columns Within Regions", - "If a number of columns is fully contained by an equal number of regions, spaces of other columns in those regions must be black.", + "If a number of columns is fully contained by a number of regions with an equal number of missing stars, spaces of other columns in those regions must be black.", "INSERT IMAGE NAME HERE"); } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java index 4c8eb6915..389ba02c2 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java @@ -15,9 +15,9 @@ public class ColumnsWithinRowsDirectRule extends DirectRule { public ColumnsWithinRowsDirectRule() { - super("STBL-BASC-XXXX", + super("STBL-BASC-0003", "Columns Within Rows", - "If a number of columns is fully contained by an equal number of rows, spaces of other columns in those rows must be black.", + "If a number of columns is fully contained by a number of rows with an equal number of missing stars, spaces of other columns in those rows must be black.", "INSERT IMAGE NAME HERE"); } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java index 13050a5ac..ed6a8a986 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java @@ -13,7 +13,7 @@ public class FinishWithStarsDirectRule extends DirectRule { public FinishWithStarsDirectRule() { - super("STBL-BASC-0003", + super("STBL-BASC-0004", "Finish With Stars", "Unknown spaces must be stars if there are just enough in a row, column, or region to satisfy the puzzle number.", "INSERT IMAGE NAME HERE"); diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java index 74e296522..d2fa4fbe3 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java @@ -8,9 +8,9 @@ public class RegionsWithinColumnsDirectRule extends DirectRule { public RegionsWithinColumnsDirectRule() { - super("STBL-BASC-0004", + super("STBL-BASC-0005", "Regions Within Columns", - "If a number of regions is fully contained by an equal number of columns, spaces of other regions in those columns must be black.", + "If a number of regions is fully contained by a number of columns with an equal number of missing stars, spaces of other regions in those columns must be black.", "INSERT IMAGE NAME HERE"); } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java index f89e0d63f..15993b85d 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java @@ -8,9 +8,9 @@ public class RegionsWithinRowsDirectRule extends DirectRule { public RegionsWithinRowsDirectRule() { - super("STBL-BASC-0005", + super("STBL-BASC-0006", "Regions Within Rows", - "If a number of regions is fully contained by an equal number of rows, spaces of other regions in those rows must be black.", + "If a number of regions is fully contained by a number of rows with an equal number of missing stars, spaces of other regions in those rows must be black.", "INSERT IMAGE NAME HERE"); } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java index 48fb1cd81..2d6c148d0 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java @@ -15,9 +15,9 @@ public class RowsWithinColumnsDirectRule extends DirectRule { public RowsWithinColumnsDirectRule() { - super("STBL-BASC-XXXX", + super("STBL-BASC-0007", "Rows Withing Columns", - "If a number of rows is fully contained by an equal number of columns, spaces of other rows in those columns must be black.", + "If a number of rows is fully contained by a number of columns with an equal number of missing stars, spaces of other rows in those columns must be black.", "INSERT IMAGE NAME HERE"); } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java index 8cc68d292..7dfaae59f 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java @@ -14,9 +14,9 @@ public class RowsWithinRegionsDirectRule extends DirectRule { public RowsWithinRegionsDirectRule() { - super("STBL-BASC-0006", + super("STBL-BASC-0008", "Rows Within Regions", - "If a number of rows is fully contained by an equal number of regions, spaces of other rows in those regions must be black.", + "If a number of rows is fully contained by a number of regions with an equal number of missing stars, spaces of other rows in those regions must be black.", "INSERT IMAGE NAME HERE"); } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java index a5533104c..0608d388f 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java @@ -13,7 +13,7 @@ public class SurroundStarDirectRule extends DirectRule { public SurroundStarDirectRule() { - super("STBL-BASC-0007", + super("STBL-BASC-0009", "Surround Star", "Any space adjacent to a star must be black.", "INSERT IMAGE NAME HERE"); diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt index 958440a71..f18965fd6 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/starbattle_reference_sheet.txt @@ -5,11 +5,13 @@ Star or Empty: STBL-CASE-0002 Basic Rules: Blackout: STBL-BASC-0001 Columns Within Regions: STBL-BASC-0002 -Finish With Stars: STBL-BASC-0003 -Regions Within Columns: STBL-BASC-0004 -Regions Within Rows: STBL-BASC-0005 -Rows Within Regions: STBL-BASC-0006 -Surround Star: STBL-BASC-0007 +Columns Within Rows: STBL-BASC-0003 +Finish With Stars: STBL-BASC-0004 +Regions Within Columns: STBL-BASC-0005 +Regions Within Rows: STBL-BASC-0006 +Rows Within Columns: STBL-BASC-0007 +Rows Within Regions: STBL-BASC-0008 +Surround Star: STBL-BASC-0009 Contradiction Rules: Too Many Stars: STBL-CONT-0001 From 096f070b8482cef0942aad5258f9e94f6ee1e238 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 22 Mar 2024 17:33:28 -0400 Subject: [PATCH 47/67] Added StarBattle to config Showed how to run in allfiles Changed puzzles to be more standardized with each other --- bin/main/edu/rpi/legup/legup/config | 6 ++++- .../6x6 Star Battle 1star Normal1.xml | 3 +-- .../6x6 Star Battle 1star Normal2.xml | 3 +-- .../8x8 Star Battle 1star Normal1.xml | 23 ++++++++++++++++++- .../starbattle/StarBattleCellFactory.java | 7 +++++- .../puzzle/starbattle/StarBattleView.java | 2 +- .../rpi/legup/puzzle/starbattle/allfiles.txt | 7 +++++- src/main/resources/edu/rpi/legup/legup/config | 6 ++++- 8 files changed, 47 insertions(+), 10 deletions(-) diff --git a/bin/main/edu/rpi/legup/legup/config b/bin/main/edu/rpi/legup/legup/config index 19e63a2a3..05f4e9e40 100644 --- a/bin/main/edu/rpi/legup/legup/config +++ b/bin/main/edu/rpi/legup/legup/config @@ -31,6 +31,10 @@ + - + diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml b/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml index 4163e15a9..110dd9abe 100644 --- a/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml +++ b/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml @@ -1,8 +1,7 @@ - - + diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml b/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml index 29307fb58..49efeba59 100644 --- a/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml +++ b/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml @@ -1,8 +1,7 @@ - - + diff --git a/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml b/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml index ba237102f..e429c3ad1 100644 --- a/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml +++ b/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml @@ -1,7 +1,28 @@ - + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java index 92ea8abf6..9f7fd0fee 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellFactory.java @@ -39,9 +39,14 @@ public StarBattleCell importCell(Node node, Board board) throws InvalidFileForma cell.setIndex(y * size + x); return cell; } + catch (NumberFormatException e1) { + e1.printStackTrace(); throw new InvalidFileFormatException("starbattle Factory: unknown value where integer expected"); - } catch (NullPointerException e2) { + } + + catch (NullPointerException e2) { + e2.printStackTrace(); throw new InvalidFileFormatException("starbattle Factory: could not find attribute(s)"); } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java index a39770d85..cc6d39677 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java @@ -22,7 +22,7 @@ import java.util.ArrayList; public class StarBattleView extends GridBoardView { - private final static Logger LOGGER = LogManager.getLogger(StarBattleView.class.getName()); + private static final Logger LOGGER = LogManager.getLogger(StarBattleView.class.getName()); static Image STAR; diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt b/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt index 7970eadbf..5a9ec0f0a 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/allfiles.txt @@ -227,4 +227,9 @@ public enum StarBattleType { //StarBattleExporter.java //StarBattleImporter.java -//StarBattleView.java \ No newline at end of file +//StarBattleView.java + +How to run Legup: + +./gradlew build +Java -jar build/libs/Legup.jar \ No newline at end of file diff --git a/src/main/resources/edu/rpi/legup/legup/config b/src/main/resources/edu/rpi/legup/legup/config index 19e63a2a3..05f4e9e40 100644 --- a/src/main/resources/edu/rpi/legup/legup/config +++ b/src/main/resources/edu/rpi/legup/legup/config @@ -31,6 +31,10 @@ + - + From b713212c73cdb07adcf209fcd8c773ba9b856455 Mon Sep 17 00:00:00 2001 From: Sarah Date: Tue, 26 Mar 2024 16:46:20 -0400 Subject: [PATCH 48/67] Reorganized puzzle files (put in subdirectories) --- .../6x6 Star Battle 1star Normal1.xml | 0 .../6x6 Star Battle 1star Normal2.xml | 0 .../rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java | 1 - 3 files changed, 1 deletion(-) rename puzzles files/starbattle/{ => 6x6 Star Battle Normal}/6x6 Star Battle 1star Normal1.xml (100%) rename puzzles files/starbattle/{ => 6x6 Star Battle Normal}/6x6 Star Battle 1star Normal2.xml (100%) diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml b/puzzles files/starbattle/6x6 Star Battle Normal/6x6 Star Battle 1star Normal1.xml similarity index 100% rename from puzzles files/starbattle/6x6 Star Battle 1star Normal1.xml rename to puzzles files/starbattle/6x6 Star Battle Normal/6x6 Star Battle 1star Normal1.xml diff --git a/puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml b/puzzles files/starbattle/6x6 Star Battle Normal/6x6 Star Battle 1star Normal2.xml similarity index 100% rename from puzzles files/starbattle/6x6 Star Battle 1star Normal2.xml rename to puzzles files/starbattle/6x6 Star Battle Normal/6x6 Star Battle 1star Normal2.xml diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java index 57a5688f2..ceea86164 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java @@ -57,7 +57,6 @@ public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElem */ @Override public Board getDefaultBoard(TreeNode node) { - return null; } } From 52220ca56382cc0552b8660137a20f5f756151bf Mon Sep 17 00:00:00 2001 From: Sarah Date: Tue, 26 Mar 2024 16:47:05 -0400 Subject: [PATCH 49/67] Created 8x8 1 star puzzle --- .../8x8 Star Battle 1star Normal1.xml | 31 ------ .../8x8 Star Battle 1star Normal1.xml | 104 ++++++++++++++++++ 2 files changed, 104 insertions(+), 31 deletions(-) delete mode 100644 puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml create mode 100644 puzzles files/starbattle/8x8 Star Battle Normal/8x8 Star Battle 1star Normal1.xml diff --git a/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml b/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml deleted file mode 100644 index e429c3ad1..000000000 --- a/puzzles files/starbattle/8x8 Star Battle 1star Normal1.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/puzzles files/starbattle/8x8 Star Battle Normal/8x8 Star Battle 1star Normal1.xml b/puzzles files/starbattle/8x8 Star Battle Normal/8x8 Star Battle 1star Normal1.xml new file mode 100644 index 000000000..977a62e1f --- /dev/null +++ b/puzzles files/starbattle/8x8 Star Battle Normal/8x8 Star Battle 1star Normal1.xml @@ -0,0 +1,104 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From e2db3f2ff2f11c8ed7e3872473d6a11b406647c5 Mon Sep 17 00:00:00 2001 From: Sarah Date: Tue, 26 Mar 2024 17:44:35 -0400 Subject: [PATCH 50/67] Created more puzzles --- .../6x6 Star Battle 1star Normal1.xml | 0 .../6x6 Star Battle 1star Normal2.xml | 0 .../6x6 StarBattle 1star Normal3.xml | 67 ++++++++++++ .../7x7 puzzle1.xml | 42 +++++++ .../8x8 Star Battle 1star Normal1.xml | 0 .../8x8 Star Battle 1star Normal2.xml | 103 ++++++++++++++++++ .../8x8 Star Battle 1star Normal3.xml | 103 ++++++++++++++++++ 7 files changed, 315 insertions(+) rename puzzles files/starbattle/{6x6 Star Battle Normal => 6x6 Star Battle 1 star Normal}/6x6 Star Battle 1star Normal1.xml (100%) rename puzzles files/starbattle/{6x6 Star Battle Normal => 6x6 Star Battle 1 star Normal}/6x6 Star Battle 1star Normal2.xml (100%) create mode 100644 puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 StarBattle 1star Normal3.xml create mode 100644 puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 puzzle1.xml rename puzzles files/starbattle/{8x8 Star Battle Normal => 8x8 Star Battle 1 star Normal}/8x8 Star Battle 1star Normal1.xml (100%) create mode 100644 puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal2.xml create mode 100644 puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal3.xml diff --git a/puzzles files/starbattle/6x6 Star Battle Normal/6x6 Star Battle 1star Normal1.xml b/puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 Star Battle 1star Normal1.xml similarity index 100% rename from puzzles files/starbattle/6x6 Star Battle Normal/6x6 Star Battle 1star Normal1.xml rename to puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 Star Battle 1star Normal1.xml diff --git a/puzzles files/starbattle/6x6 Star Battle Normal/6x6 Star Battle 1star Normal2.xml b/puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 Star Battle 1star Normal2.xml similarity index 100% rename from puzzles files/starbattle/6x6 Star Battle Normal/6x6 Star Battle 1star Normal2.xml rename to puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 Star Battle 1star Normal2.xml diff --git a/puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 StarBattle 1star Normal3.xml b/puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 StarBattle 1star Normal3.xml new file mode 100644 index 000000000..80f8658d3 --- /dev/null +++ b/puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 StarBattle 1star Normal3.xml @@ -0,0 +1,67 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 puzzle1.xml b/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 puzzle1.xml new file mode 100644 index 000000000..b4c56807a --- /dev/null +++ b/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 puzzle1.xml @@ -0,0 +1,42 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/puzzles files/starbattle/8x8 Star Battle Normal/8x8 Star Battle 1star Normal1.xml b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal1.xml similarity index 100% rename from puzzles files/starbattle/8x8 Star Battle Normal/8x8 Star Battle 1star Normal1.xml rename to puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal1.xml diff --git a/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal2.xml b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal2.xml new file mode 100644 index 000000000..e9c734546 --- /dev/null +++ b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal2.xml @@ -0,0 +1,103 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal3.xml b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal3.xml new file mode 100644 index 000000000..1f050440b --- /dev/null +++ b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal3.xml @@ -0,0 +1,103 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From f747aa8ac836f3a0bba4a4587a3d6ffbe76f381b Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 29 Mar 2024 16:01:43 -0400 Subject: [PATCH 51/67] Update StarBattleView.java --- .../edu/rpi/legup/puzzle/starbattle/StarBattleView.java | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java index cc6d39677..e0914215a 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java @@ -6,20 +6,12 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; - -import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; -import edu.rpi.legup.puzzle.starbattle.StarBattleCell; -import edu.rpi.legup.puzzle.starbattle.StarBattleController; -import edu.rpi.legup.puzzle.starbattle.StarBattleElementView; import edu.rpi.legup.puzzle.starbattle.StarBattleView; import edu.rpi.legup.ui.boardview.GridBoardView; import edu.rpi.legup.controller.BoardController; -import edu.rpi.legup.model.gameboard.CaseBoard; import edu.rpi.legup.model.gameboard.PuzzleElement; -import edu.rpi.legup.ui.boardview.ElementView; import java.awt.*; -import java.util.ArrayList; public class StarBattleView extends GridBoardView { private static final Logger LOGGER = LogManager.getLogger(StarBattleView.class.getName()); From 23c3d92a9d7ccc7538234f8e80ed856f268df73b Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 29 Mar 2024 16:47:14 -0400 Subject: [PATCH 52/67] Wrote 5x5 puzzle file 1 --- .../5x5 Star Battle 1 star Normal 1.xml | 53 +++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml diff --git a/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml b/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml new file mode 100644 index 000000000..8cd026437 --- /dev/null +++ b/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml @@ -0,0 +1,53 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From 99e431fd3d452b0edb04f980976b188895264f5d Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 29 Mar 2024 16:51:07 -0400 Subject: [PATCH 53/67] StarBattle Runs --- .../legup/puzzle/starbattle/StarBattleController.java | 6 ++---- .../edu/rpi/legup/puzzle/starbattle/StarBattleView.java | 6 ++---- src/main/java/edu/rpi/legup/utility/LegupUtils.java | 9 ++++++++- 3 files changed, 12 insertions(+), 9 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java index f7a094397..6b2a9352d 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java @@ -14,12 +14,10 @@ public void changeCell(MouseEvent e, PuzzleElement data) { this.boardView.getSelectionPopupMenu().show(boardView, this.boardView.getCanvas().getX() + e.getX(), this.boardView.getCanvas().getY() + e.getY()); } else { - if (cell.getData() == 0) { + data.setData(cell.getData() + 1); + if (cell.getData() >= 0) { data.setData(-3); } - else { - data.setData(cell.getData() + 1); - } } } else { diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java index e0914215a..ceb0eec19 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleView.java @@ -14,16 +14,14 @@ import java.awt.*; public class StarBattleView extends GridBoardView { - private static final Logger LOGGER = LogManager.getLogger(StarBattleView.class.getName()); - static Image STAR; static { try { - STAR = ImageIO.read(ClassLoader.getSystemResourceAsStream("edu/rpi/legup/images/starbattle/star.png")); + STAR = ImageIO.read(ClassLoader.getSystemClassLoader().getResource("edu/rpi/legup/images/starbattle/star.gif")); } catch (IOException e) { - LOGGER.error("Failed to open starbattle image."); + // pass } } diff --git a/src/main/java/edu/rpi/legup/utility/LegupUtils.java b/src/main/java/edu/rpi/legup/utility/LegupUtils.java index dbdd24e7f..317fb787e 100644 --- a/src/main/java/edu/rpi/legup/utility/LegupUtils.java +++ b/src/main/java/edu/rpi/legup/utility/LegupUtils.java @@ -85,7 +85,14 @@ private static List findClassesZip(String path, String packageName) throw for (ZipEntry entry = zip.getNextEntry(); entry != null; entry = zip.getNextEntry()) { if (!entry.isDirectory() && entry.getName().endsWith(".class") && entry.getName().startsWith(packageName)) { String className = entry.getName().replace('/', '.'); - classes.add(Class.forName(className.substring(0, className.length() - ".class".length()))); + String substr = className.substring(0, className.length() - ".class".length()); + try { + Class c = Class.forName(substr); + classes.add(c); + } + catch (LinkageError | ClassNotFoundException e) { + System.out.println("Failed on " + substr); + } } } return classes; From 63ea4911079b43136c3ea1f272d3663e85cc6d44 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 29 Mar 2024 17:27:36 -0400 Subject: [PATCH 54/67] Fix spelling error --- .../5x5 Star Battle 1 star Normal 1.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml b/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml index 8cd026437..5fefc844f 100644 --- a/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml +++ b/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml @@ -1,4 +1,4 @@ - + From 617b0acabfb25b7a3abf4dc0300c56e6c74e4221 Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Fri, 29 Mar 2024 17:35:39 -0400 Subject: [PATCH 55/67] Update StarBattleController.java Fixed the right click issue. --- .../edu/rpi/legup/puzzle/starbattle/StarBattleController.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java index 6b2a9352d..9566a3f52 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java @@ -22,12 +22,10 @@ public void changeCell(MouseEvent e, PuzzleElement data) { } else { if (e.getButton() == MouseEvent.BUTTON3) { + data.setData(cell.getData() - 1); if (cell.getData() == -3) { data.setData(0); } - else { - data.setData(cell.getData() - 1); - } } } } From b3452a8262338a721c84ab3fb0058359b1e50d0b Mon Sep 17 00:00:00 2001 From: Sarah Date: Fri, 29 Mar 2024 18:03:45 -0400 Subject: [PATCH 56/67] Created more puzzles --- .../6x6 StarBattle 1star Normal3.xml | 1 + .../7x7 Star Battle 1star Hard1.xml | 60 +++++++++++++ .../7x7 Star Battle 1star Normal1.xml | 85 +++++++++++++++++++ .../7x7 Star Battle 1star Normal2.xml | 85 +++++++++++++++++++ .../7x7 puzzle1.xml | 42 --------- .../8x8 Star Battle 1star Normal1.xml | 1 + .../8x8 Star Battle 1star Normal2.xml | 1 + .../8x8 Star Battle 1star Normal3.xml | 1 + 8 files changed, 234 insertions(+), 42 deletions(-) create mode 100644 puzzles files/starbattle/7x7 Star Battle 1 star Hard/7x7 Star Battle 1star Hard1.xml create mode 100644 puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal1.xml create mode 100644 puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal2.xml delete mode 100644 puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 puzzle1.xml diff --git a/puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 StarBattle 1star Normal3.xml b/puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 StarBattle 1star Normal3.xml index 80f8658d3..855943612 100644 --- a/puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 StarBattle 1star Normal3.xml +++ b/puzzles files/starbattle/6x6 Star Battle 1 star Normal/6x6 StarBattle 1star Normal3.xml @@ -64,4 +64,5 @@ + \ No newline at end of file diff --git a/puzzles files/starbattle/7x7 Star Battle 1 star Hard/7x7 Star Battle 1star Hard1.xml b/puzzles files/starbattle/7x7 Star Battle 1 star Hard/7x7 Star Battle 1star Hard1.xml new file mode 100644 index 000000000..bacc00b11 --- /dev/null +++ b/puzzles files/starbattle/7x7 Star Battle 1 star Hard/7x7 Star Battle 1star Hard1.xml @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal1.xml b/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal1.xml new file mode 100644 index 000000000..70b81e376 --- /dev/null +++ b/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal1.xml @@ -0,0 +1,85 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal2.xml b/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal2.xml new file mode 100644 index 000000000..c541ece06 --- /dev/null +++ b/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal2.xml @@ -0,0 +1,85 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 puzzle1.xml b/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 puzzle1.xml deleted file mode 100644 index b4c56807a..000000000 --- a/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 puzzle1.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal1.xml b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal1.xml index 977a62e1f..02dd5d6c0 100644 --- a/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal1.xml +++ b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal1.xml @@ -101,4 +101,5 @@ + \ No newline at end of file diff --git a/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal2.xml b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal2.xml index e9c734546..0df84ef62 100644 --- a/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal2.xml +++ b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal2.xml @@ -100,4 +100,5 @@ + \ No newline at end of file diff --git a/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal3.xml b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal3.xml index 1f050440b..725c91d7f 100644 --- a/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal3.xml +++ b/puzzles files/starbattle/8x8 Star Battle 1 star Normal/8x8 Star Battle 1star Normal3.xml @@ -100,4 +100,5 @@ + \ No newline at end of file From 85c9b7c9d3e84b9d6e3eeb3374e72103073407f1 Mon Sep 17 00:00:00 2001 From: Sarah Date: Tue, 2 Apr 2024 16:40:19 -0400 Subject: [PATCH 57/67] created image for star or empty case rule --- .../rpi/legup/images/starbattle/UnknownTile.png | Bin 0 -> 9733 bytes .../starbattle/cases/StarOrEmptyCaseRule.png | Bin 0 -> 4437 bytes 2 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/UnknownTile.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/cases/StarOrEmptyCaseRule.png diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/UnknownTile.png b/src/main/resources/edu/rpi/legup/images/starbattle/UnknownTile.png new file mode 100644 index 0000000000000000000000000000000000000000..850fbf127f04020fe83c6a4f6db75078967916ea GIT binary patch literal 9733 zcmeHNc{G&m`yaAXmTak)X=KYg%*HS^C}WMXl|9BR3}%Lz(F{qlgir~QEfj5%rPW@R z5)lchi0qNbR+8UCz3*G+_dVx#-gAE6|ID0c=6SCBx<1!^eeUbJ&)nCU7_0pz8-?VA zKp@aYGgF)m@C{zQ1o(hYW>C;92(%$B$j*UfgJ*;N7<4klmjq@7`jNmS4uuQ?ae8jr zQ%Yu)MZVp#9TYgf8*hX(%{CU^9J!;+j0A#MNvKa$Jt+njdWBUWjaiz zWF)szlOj%Q_{4l}jLmFyB&I)FG~53;!hrZZEkL$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y70dQO53jhEB literal 0 HcmV?d00001 diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/cases/StarOrEmptyCaseRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/cases/StarOrEmptyCaseRule.png new file mode 100644 index 0000000000000000000000000000000000000000..0383711bb7fb4d881c78c0d5c61227ac7c05cb49 GIT binary patch literal 4437 zcmbtYc{r5q8n^HJRwzc9h#145nZ_7fjYRe(N@Hd)8D@+b#$;bIvSewJkff+DJ4wrz zD4AA8N)jouXB%slGt^h#cdqltxz4$+dFOfW=l(sv=U$)pz20Pdy944PN+MibT;kR! zOGnO#-MEAVIRB*2OlQs@OhS2taB)dI+PJux+7ilKTznL~vpdDz_7Dt14Aezqi9R@8 zS|Evo=Hh~z(nx4b0FDCi!TI5XOf)9%HfjLySQ8C5Lt8ytk_FBmkD`-tPINnG3_Sn? z#cG%$MBp?ShaeC~K?7)kgrE=@%|v697sk2YmTP$)=GAEd9Z!$IhTga=X3G@YQ3og4-cz$S+!E(AlylPGv%5MYB7 z?L(weOf)n^06(eCC=@c@=NEfWh%S0_hPtstm*X@DjST^Tb@evP0s!DY@GvuM$cFf1 z6DM5ortm`|;5T<7p~)dQ=Wr6vM8gpmLZp&0xJ`zQML$U_$T&0whehb?=|gn%I6r+j z=-*Tud;DHtMWa|_5zxJQK4>%)tAm9=jCCN!IE;>uA=F352cz$c(f7eXF}UAEKbHKH zX1@=I#Zcc+-^dUOhJcNshI{pX?Yyb{C*GMz#rSWyg80q*du|g82W>=`fd3JcP2p!$ zei8o&*$?2~((>P@3XA!bCK8oQ*en4o281Kv0&zi8v(Gk)kE7uDW$@E4js!EKQv8WzgcF*K_6OMFgWwyOzh*gAzZv`gDZZSx z{1xDT7(qjm{?-8;7;Lk0iDYLYk$|v32Zf^HpnsqKkEZ;vj?>tj76<)02spy8qXZYk zIX}ppgTknlX351RmSk;d=1j|nsOeDxk}JOX_SVHJ(R6X} zqvLH$^=m{gTZ8ARC&zO~s;{3gxp}wrk1?0kWf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FLNCm34@DHq)$ literal 0 HcmV?d00001 From 84827707929cb2992d9cbdedd30ec7cac52903fc Mon Sep 17 00:00:00 2001 From: EmilioBejasa <69165764+EmilioBejasa@users.noreply.github.com> Date: Tue, 2 Apr 2024 17:10:42 -0400 Subject: [PATCH 58/67] Deleted WHITE element It was unnecessary, we were switching between unknown star and blank anyways. --- .../legup/puzzle/starbattle/StarBattleCellType.java | 2 +- .../puzzle/starbattle/StarBattleController.java | 12 ++++++++---- .../puzzle/starbattle/StarBattleElementView.java | 7 +------ .../puzzle/starbattle/rules/StarOrEmptyCaseRule.java | 4 ++-- 4 files changed, 12 insertions(+), 13 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java index f3524034e..565f608d7 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCellType.java @@ -2,7 +2,7 @@ package edu.rpi.legup.puzzle.starbattle; public enum StarBattleCellType { - WHITE(-3), STAR(-2), BLACK(-1), UNKNOWN(0); + STAR(-2), BLACK(-1), UNKNOWN(0); public int value; diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java index 9566a3f52..4ebeb39ba 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleController.java @@ -14,18 +14,22 @@ public void changeCell(MouseEvent e, PuzzleElement data) { this.boardView.getSelectionPopupMenu().show(boardView, this.boardView.getCanvas().getX() + e.getX(), this.boardView.getCanvas().getY() + e.getY()); } else { - data.setData(cell.getData() + 1); if (cell.getData() >= 0) { - data.setData(-3); + data.setData(-2); + } + else { + data.setData(cell.getData() + 1); } } } else { if (e.getButton() == MouseEvent.BUTTON3) { - data.setData(cell.getData() - 1); - if (cell.getData() == -3) { + if (cell.getData() == -2) { data.setData(0); } + else { + data.setData(cell.getData() - 1); + } } } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleElementView.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleElementView.java index a88773a06..ff5d54d1c 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleElementView.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleElementView.java @@ -29,12 +29,6 @@ public void drawElement(Graphics2D graphics2D) { graphics2D.setStroke(new BasicStroke(1)); graphics2D.setColor(Color.BLACK); graphics2D.fillRect(location.x, location.y, size.width, size.height); - } else if (type == StarBattleCellType.WHITE) { - graphics2D.setStroke(new BasicStroke(1)); - graphics2D.setColor(Color.WHITE); - graphics2D.fillRect(location.x, location.y, size.width, size.height); - graphics2D.setColor(Color.BLACK); - graphics2D.drawRect(location.x, location.y, size.width, size.height); } else if (type == StarBattleCellType.UNKNOWN) { graphics2D.setStroke(new BasicStroke(1)); graphics2D.setColor(Color.LIGHT_GRAY); @@ -42,5 +36,6 @@ public void drawElement(Graphics2D graphics2D) { graphics2D.setColor(Color.BLACK); graphics2D.drawRect(location.x, location.y, size.width, size.height); } + } } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java index 1bbbe3e92..035e55073 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java @@ -20,7 +20,7 @@ public StarOrEmptyCaseRule() { super("STBL-CASE-0002", "Star or Empty", "Each unknown space is either a star or empty.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/cases/StarOrEmptyCaseRule.png"); } /** @@ -98,6 +98,6 @@ public ArrayList getCases(Board board, PuzzleElement puzzleElement) { @Override public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElement) { - return null; + return checkRuleRaw(transition); } } From 09263e681d8e316deea41a3ce920783caad9dead Mon Sep 17 00:00:00 2001 From: Sarah Date: Tue, 2 Apr 2024 17:35:17 -0400 Subject: [PATCH 59/67] More rule images --- .../ClashingOrbitContradictionRule.png | Bin 0 -> 5397 bytes .../TooFewStarsContradictionRule.png | Bin 0 -> 3571 bytes .../TooManyStarsContradictionRule.png | Bin 0 -> 5815 bytes .../starbattle/rules/BlackOutDirectRule.png | Bin 0 -> 5209 bytes .../rules/FinishWithStarDirectRule.png | Bin 0 -> 4399 bytes .../images/starbattle/rules/SurroundStar.png | Bin 0 -> 5102 bytes 6 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/contradictions/ClashingOrbitContradictionRule.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/contradictions/TooFewStarsContradictionRule.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/contradictions/TooManyStarsContradictionRule.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/rules/BlackOutDirectRule.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/rules/FinishWithStarDirectRule.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/rules/SurroundStar.png diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/ClashingOrbitContradictionRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/ClashingOrbitContradictionRule.png new file mode 100644 index 0000000000000000000000000000000000000000..3cdbfd4e1ebb0dc820f59cfd90297d35795e93df GIT binary patch literal 5397 zcmbtY2{_bU+n-U%QV}vpjK~sW>smtf#b(EYC5nH0k%zFqDVHghx6`8>*=NW+73sJkA7yyEGK)?d>h- zEh>n^J3)nEFc?%w1S%o|A#p%FeX#_D4+QJUNkX6kA7iMXJRR_8cLExR1s`D|>~Tbb zEDsMA_&2m7fq+Nb|3Sxk3L=h2h({uVB%`4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0w??!Ar@i@<+UR@IdK2AepL8h}FN$0B&5H6{J@DhQ z5U2RzPlYy|BKct_zeYt}O}_xrAROCR^TH z2fwI>lGxJWQ+gHkmyj;AYSpQ0>KdJkUFYoFhUae)F88csgb*M0$JbxCdRt)~>EOWk z-`^#Wl>sl6*$B#YLhv6CP48|frL!Y+aLY45>|1rfbzu_lNF@`|ux60%Q7?>jt@lC?$;Rn$qg(ER9S|sOg4H_+&)k zfFfn*FmwzNIt+6t0u70yQ-64{BYIp`?i- zNT&O>%gk(qb7nuT?Cew+5{!scNl`QNfhlgHDsERkkR_wlqk5&JBp_WU@^ox=SZ2Jm zRZ@X^QYOwkpy%!kJYBh*8UU&XMOg@uG?NVDXSl0rF}m`&WMxyrnz0=~LEcPiYHUP| z5r-|&=)Laa1mD&+Tdy+%wdHs8uRS%ynkZht`*@cC^Y0<>&O@n6c}OHeT+(r)%?Ww4 zqb*j-m?8SUk0<&(`Dr?R?5V(y!^bVM#nA7gsIoeA*$zJNK5a?lJ#aj`E$&o&T*OFY zoOgyk99~}E-=O?@{8x<(3zk-)*zm?8bk#LW)$;?z#l=$wmwK}e^!0Q5`t}Mr$uli( zt8J=PjF8CGL0+tRkX8=y*v8o%s4-`qx20Y;-3SEvaOVUSisg4H^CX_ub7oacn Wa{k=8Y32$D_&C}V?XKD$i2e@+u;#@8 literal 0 HcmV?d00001 diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/TooManyStarsContradictionRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/TooManyStarsContradictionRule.png new file mode 100644 index 0000000000000000000000000000000000000000..724f8aa64d9733c30ca7fe5d1d52fe92cb539e8d GIT binary patch literal 5815 zcmbtY2{e>%+aDoYc2TxQma$|oV+n(?@7s{2kQp=9F{3f|EJ;~YG_pn6BZ2&wIY}p6@$np68kCy080pU;BMOPoj;LF*~auD*ymsH#IRp z(4Of1i}@h!9`G^4p7vk~FmVn90604KFS-ml4j}-5A2ZrH@$WVD)pg0YI75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X`>5yITv{{G8DOEnf2TAMOU8H?iK@3_x;cF^rphZh3iGc90i=Z#_VEk)D~nnlaK#PHKs7yu-A9&E4XJ>Sz`; zXmO@M4;Xn4CQ6-3 z1fYcYS`OU1c?(}1Z*fweJpD4{VPB!)PGzXIbi23&Pi|F~SjDNkrESo5YP5|pv98Ls zX-?&|=0F<@mTO{+9N}!tYND7^7sP&fsd>$cogOKaKg%lFW#*)M7z1yw@nBr7v2{Av zQ>yEalFQrpaI~!EX2E>OQCCLB4i0mYfu5rcAU78AmQ!cvHk>i3LW+xDGE1_sWkRYTXNhybPYSH@rvr3=?u@ zF>xN^2B;vZcN*cBE$d$r&fa%@VD!0z$dy=^I0f1uv+EfyBqEo%d0xXF1o~?-WdO&v zo=`s@j9cd0=ujM3HrhZdgrb=794}qsYzk9$swhu*pC*w(TCN*8-xds^UJ@o>xqKZL z*4*r^tL=KKXC^xZ&Q_k|bKR}x*D3B) zzp%kz$5l^_Sf4B5w&IoCf^B`c7|swQaj`B%ZhRD6S~)Dl-IjGaPr`fxf+-1E;d#|$ zV5%?4Y9g6oJn^ce#F+4Ut~k->Ry@<8ewe-kj$=>3LUw`6_!56UOVf#9tSirkZ{t`# zyMh6P$b$C$Y*ib;r@aT#3!LeF!+4{d;#+wl>x;^=HR(g&@zlz`8bEX7OspDa%A#v8 z$7a$A+sX2~A@_&yVjD47In(vNQm>$*drZ#jwPa+RJ?&!?zcTtk+Obp({l>lB zx=qAJ)6ygJHA3eE&$H2;J0njyb%a$&`sqMsz|pee;yddafn{=m78Y9B(N~S^5PCY! vKTOZRP^t{>yrp`1*|wujxJ-KJ=?^-2sZA7TzjO8er)5(^D}yRM_t<{{;x|T1 literal 0 HcmV?d00001 diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/rules/BlackOutDirectRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/rules/BlackOutDirectRule.png new file mode 100644 index 0000000000000000000000000000000000000000..53fac213291591a0318f46e049ad083a25315527 GIT binary patch literal 5209 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baT^Vat8MuG8wMgUW!)x#UBvo94=Jn8XT}(1i;=(|JyA>T^K&JO1KDM&Xv(O&;Z*ibDgP-} zxN09wH|)*eZDXBz4RujCWt-M&*Mrt?d1?n^eH~iB(qEWRiLYwoPg~d*sF!{GzBZBU z*MBjYa^9IE1Ut~48!5s$`bSfn7|hJj+T~rTmj0Gh_#djm;nXRX`L5O%b6$`r^qUK5 z+^#rIr8uV{j+Y1kpiU=9CDHPg9@($5Ds&60qSMY};uABd;>{8aUkZzr zMLVIo^9^|^tE&vY41eWA6NS2Uwep`QV0z^T+3uz!=2ncgq#bfOw;C~TR~-sUIqrCI zR3WANU9s4!Lh28Tqyh!;c%-nSs}qWqS4&v$XuN@9h}M3UkAXf9oKJPO78_*WKaaX> yUY>@?dYE(vnPeQ4cSVG6cME^@2Hm(|efL^?N&mJN|A+ literal 0 HcmV?d00001 diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/rules/FinishWithStarDirectRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/rules/FinishWithStarDirectRule.png new file mode 100644 index 0000000000000000000000000000000000000000..24eddc3b058a4a390b9e9344d4aa012c85f415be GIT binary patch literal 4399 zcmbtY2{hDe{~yLOM1&UN8j1;x8Oy|s-Pkj3mRqP~%uGy8Gh+;c2q{}+iB!tIM9EsV z!lh(4Ew)?8QVp_3S;G6H{@r`u^PY46=Y7wandkR?p3nF5eAnmsoryeRV=gQxB?tn6 zge@&h?0}KD`GxQSzx0tL2VfAOTR3@vK--^gez}rVw(kXjc>Kr?j!Z|KHHJVtr-~=i z+(@dv=jZ?$1kyF|rQ-=_Nld64$(>BqgU!^`!JuTK9_$zjhs4pbBoDHMKZ9iNZ{tAl zKTALpVFvnwy1p2I;2epGhx(qQP`xm|dax~C4Dh@;jer3l2Jtk;&cy5o1d#M#9!w@3 zgFvuYELE05BfJ2L3s>h1ErDMwdeV9+WNN zM^t_ie-GJr;9t`6|4$W>@H0(xZw6(n1c(F#i9$L@qB1v=r1m38L;{9MW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=ZGu1A_)-M`l4B0d|B4U^#t$4Ji0;09_Q@bjVl^q&`_JWpIP7_$^IX<+)*;_lRVKcN6Kxkan&P%IZyHD$T&f25X*J8ZGAl#1%x;efZoO;7P zJVn^2Q0{iuyF%j94n)539Tj_IGyedGnmL!4`(`Nlo2Ef&Pq|%uyQuPf?t$gHg}nM9 zZYORRzT(-hL)_~}W={n~ZSZaATvA3WA2I1o@Lwq$lRcm|RShkQN6?ExTGV~?M{$A| zxzIPc_bf>mKCQK0JDQU8>4J}-P>&H$%eCNi(7f=x_oSA}l*=x3JG2O_5q*`~UwS!Q z?A?*J2t$6p$)knN&*ByK?=Nmt)3yXIii_oqbGs?G+8_KfTu=Gfc}F@gx_lq)5p8I_ z3S5S$S`shnxb}XeYxSX@`pIubB4HiR&VHu&w8)6zhwj}R9TD;AOsiT_;n*PYm2t8? zGs_=%>q4>kotGQL+pQk&(bXZR{^d76N*DcB^e2h^bR=<{=Jm9-u!f{h0Z*mD32(oNiFt$=8Xn; z+Z%P~wQAWN|7B^(*Qevs;%DQEFy*oSGIve4r;tP727PO9_Jch; z7Y2)6)AVx2ccTbRLjEfYO2?~!_nCrSE3CahG4RvK(IriJi+zI!_|Ge42X@>- vCEmQ*QcZe~Gc)7UiEdnxsBCU1*#LdKM9g_RH=MNjmxiUOjmZOJ*NguGqH>uU literal 0 HcmV?d00001 diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/rules/SurroundStar.png b/src/main/resources/edu/rpi/legup/images/starbattle/rules/SurroundStar.png new file mode 100644 index 0000000000000000000000000000000000000000..13287f779e74d6c70489f32013ec3675b07dfe4c GIT binary patch literal 5102 zcmbtYc{tQ>*SBZM8rhPG82cDm$JW?|5V9qP84SZPGZ;H%-wR1f+1He%ku8##gv!2G zS`cI3m7byAe!t&yJ%7B<`(D?4=bm%!b3SLkulqakW*7CD8Tl9~C@7c>4RkJ%SNP#W zPe=atnaQ*yFAP2gwpa=ZmX5=RGEIKCOM7F5$q0;qBMcn`)&+y~!6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6x8??}o3h8nx$&mAu{>+4t~pziG|$mla;ZeL zNJvteDHIi|CRCHzFH8%CLPH?eUQe*c^)=@Q8Z6yNBEPomGU?4d1Z_y17AD^!PqqlO zc|6IVOBS+3m+HN2WE_3H7?XfXdw4USBlisM;5#$z!mzW$807HEdGZamMjf5IfTJmI zb*DDZkNEBdYVzELn;jvIaT1Uo+`aV$p?YKh={pTN>4;Oa4hxa%RetK|?%=F>`iL(5abs=w(U+qO@9{wX|sC!YTO3UfmzW@w;>+Jvl literal 0 HcmV?d00001 From 999fa1780ad12f8ecbe0912d3da285b7b7c902ee Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 5 Apr 2024 16:42:27 -0400 Subject: [PATCH 60/67] Made small test board --- .../rules/BlackoutDirectRuleTest.java | 19 ++++++++++ .../BlackoutDirectRule/ColumnBlackout | 36 +++++++++++++++++++ 2 files changed, 55 insertions(+) create mode 100644 src/test/java/puzzles/starbattle/rules/BlackoutDirectRuleTest.java create mode 100644 src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/ColumnBlackout diff --git a/src/test/java/puzzles/starbattle/rules/BlackoutDirectRuleTest.java b/src/test/java/puzzles/starbattle/rules/BlackoutDirectRuleTest.java new file mode 100644 index 000000000..b87b88de5 --- /dev/null +++ b/src/test/java/puzzles/starbattle/rules/BlackoutDirectRuleTest.java @@ -0,0 +1,19 @@ +package puzzles.starbattle.rules; + +import legup.MockGameBoardFacade; +import legup.TestUtilities; +import edu.rpi.legup.model.tree.TreeNode; +import edu.rpi.legup.model.tree.TreeTransition; +import org.junit.Assert; +import org.junit.BeforeClass; +import org.junit.Test; + +import edu.rpi.legup.puzzle.starbattle.StarBattle; +import edu.rpi.legup.puzzle.starbattle.StarBattleBoard; +import edu.rpi.legup.puzzle.starbattle.StarBattleCell; +import edu.rpi.legup.puzzle.starbattle.StarBattleCellType; +import edu.rpi.legup.puzzle.starbattle.rules.BlackoutDirectRule; +import edu.rpi.legup.save.InvalidFileFormatException; + +public class BlackoutDirectRuleTest { +} diff --git a/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/ColumnBlackout b/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/ColumnBlackout new file mode 100644 index 000000000..f2a5b42d9 --- /dev/null +++ b/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/ColumnBlackout @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From 15e19d39a03c41b0807233927bac1b7eb63d454b Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 5 Apr 2024 16:52:31 -0400 Subject: [PATCH 61/67] Add image paths to rule constructors --- .../rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java | 2 +- .../puzzle/starbattle/rules/ClashingOrbitContradictionRule.java | 2 +- .../puzzle/starbattle/rules/FinishWithStarsDirectRule.java | 2 +- .../legup/puzzle/starbattle/rules/SurroundStarDirectRule.java | 2 +- .../puzzle/starbattle/rules/TooFewStarsContradictionRule.java | 2 +- .../puzzle/starbattle/rules/TooManyStarsContradictionRule.java | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java index ceea86164..45c550bde 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java @@ -16,7 +16,7 @@ public BlackoutDirectRule() { super("STBL-BASC-0001", "Blackout", "If a row, column, or region has enough stars, its unknown spaces are black.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/rules/BlackOutDirectRule.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java index 28398143e..0ca27ab4a 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ClashingOrbitContradictionRule.java @@ -17,7 +17,7 @@ public ClashingOrbitContradictionRule() { super("STBL-CONT-0003", "Clashing Orbit", "No two stars can be adjacent to each other.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/contradictions/ClashingOrbitContradictionRule.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java index ed6a8a986..f6b7eef86 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java @@ -16,7 +16,7 @@ public FinishWithStarsDirectRule() { super("STBL-BASC-0004", "Finish With Stars", "Unknown spaces must be stars if there are just enough in a row, column, or region to satisfy the puzzle number.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/rules/FinishWithStarDirectRule.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java index 0608d388f..5d42e895e 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java @@ -16,7 +16,7 @@ public SurroundStarDirectRule() { super("STBL-BASC-0009", "Surround Star", "Any space adjacent to a star must be black.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/rules/SurroundStar.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java index af30a5e18..d1ed62107 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooFewStarsContradictionRule.java @@ -18,7 +18,7 @@ public TooFewStarsContradictionRule() { super("STBL-CONT-0002", "Too Few Stars", "There are too few stars in this region/row/column and there are not enough places to put the remaining stars.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/contradictions/TooFewStarsContradictionRule.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java index 7777ff5a4..880e3b8ac 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java @@ -21,7 +21,7 @@ public TooManyStarsContradictionRule() { super("STBL-CONT-0001", "Too Many Stars", "There are too many stars in this region/row/column.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/contradictions/TooManyStarsContradictionRule.png"); } /** From 729d6b7fe2908851f8cd9915be63883b9de88fcd Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 5 Apr 2024 17:18:02 -0400 Subject: [PATCH 62/67] Write first test for blackout direct rule --- .../rules/BlackoutDirectRuleTest.java | 50 +++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/src/test/java/puzzles/starbattle/rules/BlackoutDirectRuleTest.java b/src/test/java/puzzles/starbattle/rules/BlackoutDirectRuleTest.java index b87b88de5..d42f40c87 100644 --- a/src/test/java/puzzles/starbattle/rules/BlackoutDirectRuleTest.java +++ b/src/test/java/puzzles/starbattle/rules/BlackoutDirectRuleTest.java @@ -1,5 +1,9 @@ package puzzles.starbattle.rules; +import edu.rpi.legup.puzzle.nurikabe.Nurikabe; +import edu.rpi.legup.puzzle.nurikabe.NurikabeBoard; +import edu.rpi.legup.puzzle.nurikabe.NurikabeCell; +import edu.rpi.legup.puzzle.nurikabe.NurikabeType; import legup.MockGameBoardFacade; import legup.TestUtilities; import edu.rpi.legup.model.tree.TreeNode; @@ -15,5 +19,51 @@ import edu.rpi.legup.puzzle.starbattle.rules.BlackoutDirectRule; import edu.rpi.legup.save.InvalidFileFormatException; +import java.awt.*; + public class BlackoutDirectRuleTest { + + private static final BlackoutDirectRule RULE = new BlackoutDirectRule(); + private static StarBattle starbattle; + + @BeforeClass + public static void setUp() { + MockGameBoardFacade.getInstance(); + starbattle = new StarBattle(); + } + + @Test + public void BlackoutDirectRuleTest_ColumnBlackout() throws InvalidFileFormatException { + TestUtilities.importTestBoard("puzzles/starbattle/rules/BlackoutDirectRule/ColumnBlackout", starbattle); + TreeNode rootNode = starbattle.getTree().getRootNode(); + TreeTransition transition = rootNode.getChildren().get(0); + transition.setRule(RULE); + + StarBattleBoard board = (StarBattleBoard) transition.getBoard(); + + StarBattleCell cell1 = board.getCell(1, 1); + cell1.setData(StarBattleCellType.BLACK.value); + StarBattleCell cell2 = board.getCell(1, 2); + cell2.setData(StarBattleCellType.BLACK.value); + StarBattleCell cell3 = board.getCell(1, 3); + cell3.setData(StarBattleCellType.BLACK.value); + + board.addModifiedData(cell1); + board.addModifiedData(cell2); + board.addModifiedData(cell3); + + Assert.assertNull(RULE.checkRule(transition)); + + for (int i = 0; i < board.getHeight(); i++) { + for (int k = 0; k < board.getWidth(); k++) { + Point point = new Point(k, i); + if (point.equals(cell1.getLocation()) || point.equals(cell2.getLocation()) || point.equals(cell3.getLocation())) { + Assert.assertNull(RULE.checkRuleAt(transition, board.getCell(k, i))); + } + else { + Assert.assertNotNull(RULE.checkRuleAt(transition, board.getCell(k, i))); + } + } + } + } } From ee074b1b63917e8cfea295d72ddb6a87731a2713 Mon Sep 17 00:00:00 2001 From: summerhenson Date: Fri, 5 Apr 2024 17:24:06 -0400 Subject: [PATCH 63/67] Test puzzle files --- .../BlackoutDirectRule/RegionBlackout | 36 +++++++++++++++++++ .../BlackoutDirectRule/RowBlackout | 36 +++++++++++++++++++ 2 files changed, 72 insertions(+) create mode 100644 src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/RegionBlackout create mode 100644 src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/RowBlackout diff --git a/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/RegionBlackout b/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/RegionBlackout new file mode 100644 index 000000000..f2a5b42d9 --- /dev/null +++ b/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/RegionBlackout @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/RowBlackout b/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/RowBlackout new file mode 100644 index 000000000..f2a5b42d9 --- /dev/null +++ b/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/RowBlackout @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From c789e5b049b31dc793de92016a594cb8d1969f86 Mon Sep 17 00:00:00 2001 From: Sarah Date: Fri, 5 Apr 2024 17:44:05 -0400 Subject: [PATCH 64/67] remade images to be 3x3 --- .../7x7 Star Battle 1star Hard1.xml | 33 ++++++- .../7x7 Star Battle 1star Normal.xml | 85 ++++++++++++++++++ .../ClashingOrbitContradictionRule.png | Bin 5397 -> 5135 bytes .../TooFewStarsContradictionRule.png | Bin 3571 -> 3218 bytes .../TooManyStarsContradictionRule.png | Bin 5815 -> 6199 bytes .../starbattle/rules/BlackOutDirectRule.png | Bin 5209 -> 4717 bytes .../rules/ColumnsWithinRegionsDirectRule.png | Bin 0 -> 3781 bytes .../rules/FinishWithStarDirectRule.png | Bin 4399 -> 4326 bytes .../rules/RowsWithinRegionsDirectRule.png | Bin 0 -> 3761 bytes 9 files changed, 114 insertions(+), 4 deletions(-) create mode 100644 puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal.xml create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/rules/ColumnsWithinRegionsDirectRule.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/rules/RowsWithinRegionsDirectRule.png diff --git a/puzzles files/starbattle/7x7 Star Battle 1 star Hard/7x7 Star Battle 1star Hard1.xml b/puzzles files/starbattle/7x7 Star Battle 1 star Hard/7x7 Star Battle 1star Hard1.xml index bacc00b11..c1d7770f6 100644 --- a/puzzles files/starbattle/7x7 Star Battle 1 star Hard/7x7 Star Battle 1star Hard1.xml +++ b/puzzles files/starbattle/7x7 Star Battle 1 star Hard/7x7 Star Battle 1star Hard1.xml @@ -36,22 +36,47 @@ - + + + + + + + + + + + + - + + + + - + + + + + + + + + - + + + + diff --git a/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal.xml b/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal.xml new file mode 100644 index 000000000..cab0a0a5e --- /dev/null +++ b/puzzles files/starbattle/7x7 Star Battle 1 star Normal/7x7 Star Battle 1star Normal.xml @@ -0,0 +1,85 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/ClashingOrbitContradictionRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/ClashingOrbitContradictionRule.png index 3cdbfd4e1ebb0dc820f59cfd90297d35795e93df..d25340b407edf02eebfdbc35764b0527ecea59b7 100644 GIT binary patch delta 4008 zcmai0XHb(1uuVcJ8mS^k4-kqHq?b@b6;V10p$byE(vd zy8#uEu5<{!h4OfR-=DYtc4l{WcF)-}hj24Rys`ugR!A=eiy)MoP_A;WF7l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kV7E*y@*?by%xaZQn)f zcgrug&@D|mAD|xA(DxC~rFKPw5(TN5zsX(f>-PJl3smyO$5?MlT=`byJtRweEr+jH zzXJKm;c;X(TW;Pw4e2Gxv2zb!;Ga;Xn|DQyzT~Uvin!`5Hsl(JFdx85Ff>f-(?!pl yJEz+OZ|a||-29l`#G7u_rYA92=+t=mHPH&|n}o^6(jJ1F_e|-z;um?#(EkDBN<(1) diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/TooFewStarsContradictionRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/TooFewStarsContradictionRule.png index 8d4c7bf3520f49394a88c0a5922779aa589b1674..cc019752f8531a366fd784d6772182e185a8d8df 100644 GIT binary patch delta 2078 zcmb7Fdpy$%8{gJaj{7CX!g!mgOzws=*OE#uFJ~@mvYAW02sv)EABol?%DN!;$fe{~ zOfF}ViatZBjoM_=+{tB|96CGiAMfAqdH#F;d7kI{e8124S%crwXsiZ6ltCkh;AOt|!XNo|eJy(J^ST&#JqBs>Mi||n(#g&+DO^)V|rp#je=#WvPJ)a z^QyHnr~^o<6BF5=I!O3jS)oT=UUY71ou2=*r$id-c0@0ZWwfom!?<7IykoXz8y6~1 zo-D*xD6a0egED$|DcEdVDrpyxidL?^#Z#=L!~qNbGxIKmX@lll%evqM#08B zo56Y@njXA6D_s248u`g`X^sE#`s~j3)}`5Z$V#4gVx>Dpg!1+AX-psz|Ft0$#xgSP z!(Fgg_1kyutV-{Z-(SXJok6*Fxs~5sTwL6CK;b)IdjhAodIcXJ2e!t~|F#rIA|bhq zxT`2!`xmMe=xwQeX;;Dmhp7UZRy#D@*xijOw241dIy^o;@XA_xqZ%57GrXr%?n!NK zX&F<&Hn;`t#dwt1l~-5mFRe9`24^o z%Uq|?#IWfat6Kk-(2@1o_eojpXapLK2Fw$daIQaO6%t7#Qd5GtW)(W_+r>>=wj#Z# zyObcuWDzB_G~ga%N^^m`sIzk%&C5>-!xkZpXVq>LkCTegan(B1_wO9;^GL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5{_2MH+v%ghw~<}1JwxFM|(%^>v-5M{}$dXyiR-JoWayLIs#T+cDjH2 zFIKZL!|Up(6LzbWdiNPJT>E3Nm8CM6ZR`NIvMMh@1;5kqpX6>0KhQD-w7^4Q7m`A= zs6%g`dQS3disH)ckj4wmi3+c^KXgPJHeCFDxY<}(MO$s~Fq}A4Vj8Ya5p?L!X`XHm z{h@|J+0ve-UX!V4Z7Qe5eJfcRefWA$vff`^P3BXVOpnkf)wy~OPEJm4Vx&m#i|ERf zLLxY9cpwY1bl`DPSM>w%T@`P%HVQWjxKYaCcPI2H?~3A&zR^ zRsOG2CBl``BU(@cqF}LhprhzU!yM+2L;OEx&ff+f&|`qY3q-5pzc2QJ+_R0;^PokS zk#Na5;Nn?<#QRK7dNf7w0y1WOO7rtnff_a{+7>O%E9Nm7NcT))(NKtuvzF||{LR$) zQv|y5#|_sRDstGtS{HjaCLAxPQ&ub;|LF&09FNV=iNKP^Y@>AYtYa;)BBc5GA7_+zwS0XElTBRII7x+z$YF?|hRRUb*zAbGgHD%%zHDdi|YfNH_zws$} zkmzR>iEHR~eMY&Z`J;rw0s7>N>fa7q>6N_=FR2VcV$c*QBSJ|`Ic}E7v0K4E5;FA$ z_idox0)ol^b)^7b#X&_Dued|w)c;o^6K+~Bdr#{N=MnI9$pG#O^~)B!YcE&OE-0^w z!V7kU>)gw!tia=yY6nl=9hT{=>Y6lMr5{*Eu65{n+!7_OYqa*%pqw@!9S@Fo^4cb$&c7B6ih8@s zC-w{1Q%A3xN?EubZ|LYKRUlbJ8=O+ad9Z(M`%JNY z{LL)R-Z`zrT0mv6h14=xJpN(zWgZ8`zmjaV#c2HkXjJq86u#>*B$41*Ao zivE&6N?$G&Q)bFNt*^gP42#cAEsG&#ikjz<>By_S`( zB=86mke6M6zaiTM5m1JDhE!&E>>@0LU+flmGw# diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/TooManyStarsContradictionRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/contradictions/Too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^Z}na$m6FE@ehzu^DQ$NKttCPGG}0D)@9%xXR5N?4fBNfA zflDtfu)o~?(TY*_G-zKvVHN?xAR=Nn@sS~)LVwj88sAnaS{rtqu*n*o9ant${ug-r z9r#9#|7@weCR56XAj(kgzW54jhZNH>?Z8SE51!wsMGLpZm5%D%OmZ zG$KK*Eak@*EFMe4xsRn~DAtYQ1-qZUfJ0K^GKX4gCf=DhhpmajfwPKiDF!n#HEqrQ z7@>%j(``N9PdG&~M*$;Q2qi5^FOlT`NX_YpCLkg0&@PgKq}klVfUZCETRqcsKilJs ze8h_h>fXwa@{gzfTXy3L7D=(3`p;1u&g7Oq3JHvbg<}FoShM0pKbZtl_hXlG4fTcj zHNRNqW9%zy7O&>-n<-@xS(vo^plc06^0EL{suhTr7L8AN6h}EqG4n6xocd?`<$;>I zRRQf>^aNaXL=#$6vu9Qg?F^!~rqBjKnQsK9B3Z1-ytZzv6OQCW|#f@?f z0c);WJH;P4U^}=dx%m)v#IL0sJ+(t61v+rR9hJ-JlHrpI`G?7VmV+S9zgS7uV|jen z;H|g%F;C%V8h2|8n7Ghndjj6(K*kT5)TJ6iS-lu+eq{RveU>rII1v1w9CcLS4$hE% zc;Mibc)Y_ecs7Z>3qUHx8oo^Q1H!}8p%x~SW~{5HmzIka&&bS;TadY=`s6I5HctB7 zD``o_14kKkj!5Qqu!hc5YLNw8USi1eVA78^s?|H%MYcB-pQ0b$4xE`*-n2fL{m9P! zGWO8CH4>O9W);0AnmIF8%k;B4@Sjn7l_(2Ro7&3W8j7oE_r9Lc>iGc0(6t|nBuVy# z9%k8^FfHA>Qz5(m_f^aOPn~itxiVZN$q2OM41*M{Hz>WTYlbUi{lcA118$<*(9wWC Jt$bo1{eO3p=0E@d diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/rules/ColumnsWithinRegionsDirectRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/rules/ColumnsWithinRegionsDirectRule.png new file mode 100644 index 0000000000000000000000000000000000000000..3493810b78122654a0f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lb7gys+zguY)M6b2nJmzASOV-C>Of(jl z2txOl?L)*GRgSwlKL7m6OTH2;4idskdhAIQ+T|bE*OR~bg6=|^t9zpSkOFR z@beIyx>GjBn(D0Ns2?1@ui^42XL-s1gj68b475CK$$e3AIUOn5teC57bSg@TUhSjf zXi#X~=2Yd%>-boK8{_h3>C-8MiF9B&bX1|p=J9X7Ta;9l84!!uYpsV}qGwxmo2m&O z`k9G})Sh^uF0r>jVa3Ob7(lWA^9b1E$B)BS%KD}NM|&5;F8D|7tauq%!V@kj68)tM zj<)W8GCf3JUJQJ#K2ooa!`VF?{JaswDZt+|d*@jq9UK4pwTzv8*N10#nPxixpn0lq zrr(cv=P(ZbQ)*sb%JOnootJnHJRNlxU}Q_1vSV;(--+mV;t)!#3f)xilp%7YaY6b# Date: Tue, 9 Apr 2024 16:38:38 -0400 Subject: [PATCH 65/67] Added direct rule images, updated image locations --- .../rules/ColumnsWithinRegionsDirectRule.java | 2 +- .../rules/ColumnsWithinRowsDirectRule.java | 2 +- .../rules/RegionsWithinColumnsDirectRule.java | 2 +- .../rules/RegionsWithinRowsDirectRule.java | 2 +- .../rules/RowsWithinColumnsDirectRule.java | 2 +- .../rules/RowsWithinRegionsDirectRule.java | 2 +- .../rules/ColumnsWithinRegionsDirectRule.png | Bin 3781 -> 6456 bytes .../rules/ColumnsWithinRowsDirectRule.png | Bin 0 -> 5331 bytes .../rules/RegionsWithinColumnsDirectRule.png | Bin 0 -> 6402 bytes .../rules/RegionsWithinRowsDirectRule.png | Bin 0 -> 6269 bytes .../rules/RowsWithinColumnsDirectRule.png | Bin 0 -> 5117 bytes .../rules/RowsWithinRegionsDirectRule.png | Bin 3761 -> 6477 bytes 12 files changed, 6 insertions(+), 6 deletions(-) create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/rules/ColumnsWithinRowsDirectRule.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/rules/RegionsWithinColumnsDirectRule.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/rules/RegionsWithinRowsDirectRule.png create mode 100644 src/main/resources/edu/rpi/legup/images/starbattle/rules/RowsWithinColumnsDirectRule.png diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java index 93fb86dc5..b42bfd1c0 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRegionsDirectRule.java @@ -18,7 +18,7 @@ public ColumnsWithinRegionsDirectRule() { super("STBL-BASC-0002", "Columns Within Regions", "If a number of columns is fully contained by a number of regions with an equal number of missing stars, spaces of other columns in those regions must be black.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/rules/ColumnsWithinRegionsDirectRule.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java index 389ba02c2..0a78c8868 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/ColumnsWithinRowsDirectRule.java @@ -18,7 +18,7 @@ public ColumnsWithinRowsDirectRule() { super("STBL-BASC-0003", "Columns Within Rows", "If a number of columns is fully contained by a number of rows with an equal number of missing stars, spaces of other columns in those rows must be black.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/rules/ColumnsWithinRowsDirectRule.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java index d2fa4fbe3..16951fb2a 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinColumnsDirectRule.java @@ -11,7 +11,7 @@ public RegionsWithinColumnsDirectRule() { super("STBL-BASC-0005", "Regions Within Columns", "If a number of regions is fully contained by a number of columns with an equal number of missing stars, spaces of other regions in those columns must be black.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/rules/RegionsWithinColumnsDirectRule.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java index 15993b85d..27dc001a0 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RegionsWithinRowsDirectRule.java @@ -11,7 +11,7 @@ public RegionsWithinRowsDirectRule() { super("STBL-BASC-0006", "Regions Within Rows", "If a number of regions is fully contained by a number of rows with an equal number of missing stars, spaces of other regions in those rows must be black.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/rules/RegionsWithinRowsDirectRule.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java index 2d6c148d0..4054ec017 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinColumnsDirectRule.java @@ -18,7 +18,7 @@ public RowsWithinColumnsDirectRule() { super("STBL-BASC-0007", "Rows Withing Columns", "If a number of rows is fully contained by a number of columns with an equal number of missing stars, spaces of other rows in those columns must be black.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/rules/RowsWithinColumnsDirectRule.png"); } /** diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java index 7dfaae59f..7af2c79ed 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/RowsWithinRegionsDirectRule.java @@ -17,7 +17,7 @@ public RowsWithinRegionsDirectRule() { super("STBL-BASC-0008", "Rows Within Regions", "If a number of rows is fully contained by a number of regions with an equal number of missing stars, spaces of other rows in those regions must be black.", - "INSERT IMAGE NAME HERE"); + "edu/rpi/legup/images/starbattle/rules/RowsWithinRegionsDirectRule.png"); } /** diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/rules/ColumnsWithinRegionsDirectRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/rules/ColumnsWithinRegionsDirectRule.png index 3493810b78122654a0f7091cf605ef0cf9dc9c84..1a88e9d07c6a0e4a1425d9725be9d1fc130058ee 100644 GIT binary patch delta 5806 zcmZ`-XH=8TwwB(dh%_OD4nhcoUP22X9Vyb48Xz<&0U|BZQRy`_se+*i(m?^Kp-7Ql zq$pLSePTcmxOl#E?m2g@duGj_J+q%@?>*06GwXf(I9eddvc|+{gsBD6LSIkb@v*0< zz0+d{xG2ig`^KN4sEqQqcXWp%fevsNgcnrcpuJN7h;V`mm`mx4>3hTAt_ZClU${w- zfvIDVyQ7?wfU**0N*-Uzpn4iTF)+=5P>M}a6^ZmkILNCy`6*EXfj~uHCueyRxQ`NL zS{0$N zBmZIlVf_!+|H>&tERu#G=4JeE4iqR)4=+FYYhltxJ7qx-B(pqoe=Pm|nG3GSq}6)Bd)M@$O1x1{!@^-H1!lk)vro zHuOQt1Jf>$?r`JT#h6^Zn1qPK1z7ZRQo)u)*4O+W?I$4zKk~Nng2y<*jj>UB{IIYv zr6$is(r}fha(R*ay>kK(WCO70s;bM8~{M#(vpptXrY1_&?&ZB9>_TYQ#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B+O>wxKYeVw id9c50H<`P9$nc%LI{9H#w%gI)jz;=sdd1M2cm4;2F`f_r literal 0 HcmV?d00001 diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/rules/RegionsWithinColumnsDirectRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/rules/RegionsWithinColumnsDirectRule.png new file mode 100644 index 0000000000000000000000000000000000000000..fde683dcde26e2d717999fe759d97d3f3f524dee GIT binary patch literal 6402 zcmbtZcTkgGm!@ctCcPs>1nGnpYUovZZz>RyP(zV~Dg+SeQl+Xik={EZMXG>`^dcZ2 zARtHw>1r6N}R{|W2%+O}qT2e4qX8|bO)dnHp?d*m{T8Y)5-~SfXi^2g0%&;-INga4(h({2t!{TBbcufOcKs1CrbqJ zmckM^BhXNww=>cOCFL!{`HNQy`}=Yk#EAvD!)>JulvV#gu#ya?JsRyM1p;|_c?o!l z2)Mf2frKO_B|(D1AYoyCEP@~9kzc`c;D44s08`{Cu1$fB`wQ==8 z%W!fM0sl}dpwaFQHh(FnM#u%NIgzaaJ_2?71b z)}@VqDX4g(@4#hk;9zkfIMkM394u_hFDi}@<(GsCO7IIxKn2BZ1cebI!lHkPeyjXD zjj9cn1uP5}76VHPi3*8Jf+Yn1D*W2~cf66S2h9G`6;zk5J-eG!UcVqB%wb^g2SZH4rnCeUnx>R zqW?Wb*xHjqLS5`+IKBDd2wSKJ63r=VfURR!7nG?3+TOuM$rb70?1EBua7Vz<1|CQR zkRK@YKlu5F8Up%<)&GZ=ZvUwD%WC}9a+h_8-N3pi^2bH2B&Fbiws&=xHH5lD?Sa}3 zE|5#if3IR2;8z;{Poc(k=-*iX+abK6ZvSWoEKKTG5xcq@xw;}{m7p%3PzdNhm;cA3 z{5~DF$FbcG`a2V_!r!TaaKVleckIjv)bfbL!J+29qpV=${o+SDff3Dk<2$l&Ayw2< z?-bWUkWHV(rx@$5a~mx!Heafz&&>v}RB%Rq;~|;L6h1*VCtd65=_xr$az& zJd)~e=whRN(t7rzgPA~rV5?M|d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ee#xUH7dCOs3mr8jrR`U z?G_F~WqW^^87&=cEY^(tO(g%^1!>N<;be#%-j4PxSM1zevU|Y00NUhROl`WxVSRZ0 z%|L|ot#)O)*%#)U7ZfO(l6BqRF-vhs-3IF@E0XaGzH?iAXV0Pd6}uUHUH*_#H3`|) zI;RAeCoNJv6Iv98pXCRBp&&PM3=8{umhpKX2|;qRWHq)Ey8?w-*l{*+|8kJw5BkyA2D{mmwj;~@v02- zWz)~EyKrnyFjl!si*R!->56aEO6cVe3q8~L8(KSyQLlSYXQgG%J*IiAqt@=j`w`rF z?d|n-uMB(_9b1`WrmrEZkmqY}?rJ?FlR4r!-z|X0%sGxf5*3f=2aFc#->>zdF|#nb zGbqrPSBeax9LZKR9?;Ls?a*qfSMTGS28y`h3VVT%qxEOEi=)wc&pAlO`_Q8=^8b2RA%B1i^4bi_*Rb}{{C0cUuZ+USaF-J zXF;D=Dx1GNiBf%Nxx2f2<;FaDd(wp-pCQDL`+}xh7{#?gm0Z;j&NKAfpKp48c=Ucd zY;dW`bKrZLux0Jqvu9$rzG*Lb{77U6wHIh7Zf^B}_(en#a@B(a-)wb@D&tfiIvPF@ zW4z2cBs*G%eu4RFG2t_`>k{-;z$i=p?$i@;8KHCFdE$>ek!Q|*dF}ZzyDM4PNt@b2 zzvjXrHnqVR`V;=zw$k}-x~Q$&@!@WUTBxdN;o*-@*x9A8J9XC_s;{$-O;&s38mbx( z31vSr2A5tL?|mnp3SCDNr2k44EFFd%Ak= z^+?25nC2{1I5lKDv(@EXxY1YOGtg78%eUxney9exP${Q8IKtp_`Uio&wux57Ro96B E0_Y@20RR91 literal 0 HcmV?d00001 diff --git a/src/main/resources/edu/rpi/legup/images/starbattle/rules/RowsWithinColumnsDirectRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/rules/RowsWithinColumnsDirectRule.png new file mode 100644 index 0000000000000000000000000000000000000000..bac64a87c9ae9df53b8be031c17306773ccfba7d GIT binary patch literal 5117 zcmbtYXH-+$whmPcRivswL?n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ithinRegionsDirectRule.png b/src/main/resources/edu/rpi/legup/images/starbattle/rules/RowsWithinRegionsDirectRule.png index a9f22f16f5042b5bd5b9294f9fb465b15f1eeb0a..8907e047521d5310676821ddb141672f2b5e4d7c 100644 GIT binary patch delta 5692 zcma)AWn9!^HV@ zfb6WKIrK#|_%&P=;I?)uer|AGzZXzTKL<+*D-Ky1f&>&>LZ2d%7z>0{#So!`JoWH! zv$K$VYUM6N00My^ZdTTky71RB1jvsVPmq%swCEDZ0}N{U|6Ek^@px_}BPhWy!Y?K+ z!eb>OA;cprC}_dtT4hyL?wIZ4>OmQyL0K_A(%D+46))vDrZC;h%g@}xiGX#?EYwe#_bKnZ7k!OzA9HYoyK7llTOXkc z=qiG4{LuTb#Eiv}aYIRptN8_+Nlt~8MEL^6>e|HsxNq>=n{hdRXQ?Z>$5JEml4>Jn z`=}2d+Qs?MGf6#h`}fxJ&;#GkTD4AuUobmblE4iwbItKh^Ltv8z%iU)L?FKVD`HxS zsM&>Pf3Z8k{GuX-2h7ZIb>br5g~0|D&O(0JANd3J;Q^GU2)-4rv{Lussc}eV3BSIk zyGIGo<0w7+y%8~)Q-|;Gm{O-GWvs>vacQT+_slrv$ENo=GPHI5|c3?eI_IB6#D{5fWK zsqKMkr3|Fn?<%M4<$rv^Ii(c@VF7FJ+CI!lkF87U}S+q7=AjlbO{7>C`Q zRasInkj{4pV|tsd2os&%I7;9ygy$F8H>s>Op-cc@!tmrUOD_%h?iMMm#7!o>4qz$~B$7U(#$jlBXM$@PpN$GTi6+|ReD{n&;+4TeI(D>3 zY{;*&j*Z8SPuX3HDMpTLjx;_8uO#kn?reu4!U6M*DT6EcZ42~B$MmhK4x9Dapr-||iq-9K$43+AaRz!r&v-%YE~6<)T%Fsv+(lP>Pq)NR zqCOHvG8UD)&4T2E+3#3n#XC{8F(DTm`rE-OHs_UgpjWg3;yjoMAwZv;6-bbbHiAeI zhvgpszu^%;-=`xD`d-2y!_XIZ-*gQ2*oHWnW=(aiv_!lEkqQ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mGH?aS{`c1*btQxivo`lc@UjvpA<0pI>=M z*XxNw1PJ0M4yFlM1%!?amF~I%U8UjN(xgv)Rs^RRAjHN#PauNLr4ns|UF4m#!=ip{ zy*ka>;ORh6GTx1&oxPpK<8@c*DB%vdVyJ#XoIH{3v)@Ul+@{;P0mtwAScjkC@Rx`S z*&Ln#6SB5%P!xhHEF zKxM#-XoDwDo_Pfg}zpqYEi-C z?R&>Q?|`t%2oFr&xmWE@N_qWS(%xa4 z*xP%kkC`>V<%%= Date: Tue, 9 Apr 2024 16:47:58 -0400 Subject: [PATCH 66/67] Fix a puzzle file --- .../5x5 Star Battle 1 star Normal 1.xml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml b/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml index 5fefc844f..cccf07c95 100644 --- a/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml +++ b/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml @@ -1,7 +1,7 @@ - + @@ -9,6 +9,7 @@ + @@ -26,6 +27,7 @@ + @@ -45,9 +47,6 @@ - - - \ No newline at end of file From 1db4a7a426a50b7b7b6947435be2c458d8af778e Mon Sep 17 00:00:00 2001 From: summerhenson Date: Tue, 9 Apr 2024 17:46:10 -0400 Subject: [PATCH 67/67] Fixed some bugs with the rules --- .../5x5 Star Battle 1 star Normal 1.xml | 1 + .../edu/rpi/legup/puzzle/starbattle/StarBattleCell.java | 2 +- .../legup/puzzle/starbattle/rules/BlackoutDirectRule.java | 2 +- .../starbattle/rules/FinishWithStarsDirectRule.java | 2 +- .../puzzle/starbattle/rules/StarOrEmptyCaseRule.java | 4 ++-- .../puzzle/starbattle/rules/SurroundStarDirectRule.java | 2 +- .../starbattle/rules/TooManyStarsContradictionRule.java | 4 ++-- .../starbattle.rules/BlackoutDirectRule/ColumnBlackout | 8 ++++++-- 8 files changed, 15 insertions(+), 10 deletions(-) diff --git a/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml b/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml index cccf07c95..b86e16ff2 100644 --- a/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml +++ b/puzzles files/starbattle/5x5 Star Battle 1 star Normal/5x5 Star Battle 1 star Normal 1.xml @@ -49,4 +49,5 @@ + \ No newline at end of file diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java index 4296c8230..a316872d9 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/StarBattleCell.java @@ -13,7 +13,7 @@ public class StarBattleCell extends GridCell { /** * StarBattleCell Constructor - creates a new StarBattle cell to hold the puzzleElement * - * @param valueInt value of the star battle cell denoting its state + * @param value value of the star battle cell denoting its state * @param location location of the cell on the board * @param groupIndex indicates what group # the cell is in. * @param size size of the star battle cell diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java index 45c550bde..75fbaadb6 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/BlackoutDirectRule.java @@ -42,7 +42,7 @@ public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElem } StarBattleBoard modified = (StarBattleBoard) origBoard.copy(); - modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.STAR); + modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.STAR.value); if (contraRule.checkContradictionAt(modified, puzzleElement) != null) { return "Black cells must be placed in a row, region, or column with enough stars!"; } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java index f6b7eef86..36e691e74 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/FinishWithStarsDirectRule.java @@ -42,7 +42,7 @@ public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElem } StarBattleBoard modified = (StarBattleBoard) origBoard.copy(); - modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.BLACK); + modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.BLACK.value); if (contraRule.checkContradictionAt(modified, puzzleElement) != null) { return "Star cells must be placed in a row, region, or column without extra spaces!"; } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java index 035e55073..0aa147c6f 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/StarOrEmptyCaseRule.java @@ -83,13 +83,13 @@ public ArrayList getCases(Board board, PuzzleElement puzzleElement) { ArrayList cases = new ArrayList<>(); Board case1 = board.copy(); PuzzleElement data1 = case1.getPuzzleElement(puzzleElement); - data1.setData(StarBattleCellType.STAR); + data1.setData(StarBattleCellType.STAR.value); case1.addModifiedData(data1); cases.add(case1); Board case2 = board.copy(); PuzzleElement data2 = case2.getPuzzleElement(puzzleElement); - data2.setData(StarBattleCellType.BLACK); + data2.setData(StarBattleCellType.BLACK.value); case2.addModifiedData(data2); cases.add(case2); diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java index 5d42e895e..e1c6f3084 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/SurroundStarDirectRule.java @@ -41,7 +41,7 @@ public String checkRuleRawAt(TreeTransition transition, PuzzleElement puzzleElem } StarBattleBoard modified = (StarBattleBoard) origBoard.copy(); - modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.STAR); + modified.getPuzzleElement(puzzleElement).setData(StarBattleCellType.STAR.value); if (contraRule.checkContradictionAt(modified, puzzleElement) != null) { return "Black cells must be placed adjacent to a star!"; } diff --git a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java index 880e3b8ac..2ae424d45 100644 --- a/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java +++ b/src/main/java/edu/rpi/legup/puzzle/starbattle/rules/TooManyStarsContradictionRule.java @@ -99,14 +99,14 @@ public String checkContradictionAt(Board board, PuzzleElement puzzleElement) { for (int k = 0; k < cellList.size(); k++) { if (cellList.get(k).getType() == StarBattleCellType.STAR) { starCount++; - if (starCount >= puzzleNum) { + if (starCount > puzzleNum) { valid = false; break; } } } - if (valid == false) { + if (valid) { return super.getNoContradictionMessage(); } return null; diff --git a/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/ColumnBlackout b/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/ColumnBlackout index f2a5b42d9..ddcc4dc9a 100644 --- a/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/ColumnBlackout +++ b/src/test/resources/puzzles/starbattle.rules/BlackoutDirectRule/ColumnBlackout @@ -1,5 +1,6 @@ - - + + + @@ -25,12 +26,15 @@ + + + \ No newline at end of file