Multi-Module Maven project (MVC) of Sudoku Game with JavaFX GUI. The app provides the ability to choose different levels of difficulty, change the language, save to file, save to DB, and load the data from the file or from the DB. The game can be saved whenever a user wants to do it and save current progress to a file or DB and again load data to continue the started game in next session.
Main Menu ENG | Main Menu PL |
Gameplay ENG | Gameplay PL |
Save Game DB | Save Game Filesystem |
This project requires the following dependencies:
- Java >21: Minimum version required for running the application.
- JDK >21: Minimum version required for running the application.
- JavaFX >22: for building the graphical user interface.
- Maven >3.9: for project management and building.
- JOOQ: for database interactions.
- SQLite: as the database to store Sudoku boards.
- SLF4J and Logback: for logging purposes.
To set up and run this project locally, follow these steps:
-
Clone the repository:
git clone https://github.com/Oskarowski/sudoku-desktop-game.git cd sudoku-desktop-game
-
Build the project:
mvn install
-
Run the application:
mvn javafx:run -pl View
-
Start the Game:
- Launch the application, choose difficulty and click on "New Game". Or load previous game from DB or filesystem.
-
Save Game:
- Click on the "Save Game" button to save your current Sudoku board to a file.
- You can also save your game to a database by clicking the "Save to DB" button.
-
Load Game:
- To load a game from a file, click on the "Load Game" button.
- To load a game from the database, first select the desired saved game from the list and next click on the "Load from DB" button and .
-
Solve Sudoku:
- Fill in the cells with numbers from 1 to 9. Each number can appear only once per row, column, and 3x3 grid.
- Save and Load Game: Save your game progress to a file or database and load it anytime.
- Database Integration: Store and retrieve Sudoku boards from DB (SQLite).
- System Filebase Integration: Store and retrieve Sudoku boards using the system's filesystem (object serialization).
- Internationalization: Supports multiple languages.
- User-friendly Interface: Intuitive and easy-to-use GUI built with JavaFX.
- Difficulty Levels: Choose from 3 different levels of difficulty.
- Logging: Comprehensive logging for debugging.
This application supports currently English and Polish languages. The localization is handled using ResourceBundle
to load the appropriate language properties files based on the user's locale.
The Sudoku game uses a SQLite database to store game boards and fields.
For an ER diagram illustrating the database schema, please refer to ER Diagram.
This project uses JUnit Jupiter for unit tests and JaCoCo for code coverage analysis.
To execute the tests, run:
mvn test