Caseboard functionality merged into Board class. - #996
Merged
Merged
Conversation
Mystin
requested changes
Sep 24, 2026
Mystin
left a comment
Collaborator
There was a problem hiding this comment.
Good first PR! There are a few small changes I'd like to see which I left comments for, as well as some stuff that really isn't your fault but need to be changed regardless. Everything else looked really good and a big thanks for the effort you put into changing all of those rule classes.
Mystin
approved these changes
Sep 30, 2026
Mystin
left a comment
Collaborator
There was a problem hiding this comment.
Board's javadoc could probably use some documentation that it has case rule functionality but the method javadocs suitably explain how it works. Good work 👍
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Caseboard itself had little functionality of its own that was not related to being a Board itself, so we merge the two classes. This means adding the caseRule and the set of pickablePuzzleElements to Board, the getters and setters of said variables, and the various functions related to them (addPickableElement, removePickableElement, getCount, isPickable). This also meant replacing every mention of CaseBoard as an object type being replaced with Board, and whenever it asks if "board instanceof CaseBoard" (board being a variable of the Board class) its replaced with "board.getCaseRule() != null" because only CaseBoards have caseRules in the current functionality. As a result of all of this, this meant deleting CaseBoard.java.
Closes #993
Type of change
How Has This Been Tested?
I have built the program to the .jar file and it opens without error. Additionally, using the functionality of "CaseBoard" in Nurikabe also printed no errors.
Checklist: