A classic 4×4 sliding tile puzzle game, built with MonoGame for Windows and Linux.
This project is a MonoGame port of Chris' Puzzle Game, originally released for Windows Phone 7 using XNA.
The original XNA project is available at: christianhelle/xnapuzzlegame
✅ Fully Playable — The desktop port is complete and runs on Windows and Linux.
| Feature | Status |
|---|---|
| Main menu with keyboard, mouse & Tab navigation | ✅ Working |
| New game / random puzzle selection | ✅ Working |
| 4×4 sliding puzzle gameplay | ✅ Working |
| Arrow keys, WASD, and click-to-move controls | ✅ Working |
| Live preview (hold Enter or F1) | ✅ Working |
| Win screen with time and move count | ✅ Working |
| Play Again / Main Menu flow | ✅ Working |
| In-game options (Esc to pause) | ✅ Working |
| Session persistence (save/restore on exit) | ✅ Working |
| Credits screen | ✅ Working |
| Resizable window with layout scaling | ✅ Working |
- .NET 10 SDK (or later)
- Windows or Linux (uses MonoGame DesktopGL — OpenGL + SDL2)
dotnet build PuzzleGame.slnxdotnet run --project src/PuzzleGame/PuzzleGame.csprojThe game window opens at 1200×720 by default and is resizable.
The repository's static site lives under site/ and is deployed to GitHub Pages with .github\workflows\pages.yml.
- Pushes to
mainthat changesite/(or the Pages workflow itself) trigger a deployment. - You can also run the Pages workflow manually from the Actions tab.
- The committed
site\.nojekyllfile keeps Pages publishing the static files as-is.
| Input | Action |
|---|---|
| ↑ / ↓ / Tab / Mouse Wheel | Navigate menu entries |
| Enter / Left Click | Select |
| Esc / Right Click | Back / Exit |
| Input | Action |
|---|---|
| Arrow Keys / WASD | Slide tiles |
| Left Click | Click an adjacent tile to move it |
| R / F5 | Reshuffle the puzzle |
| Enter / F1 (hold) | Preview the solved image |
| Esc | Open in-game options |
The goal is to rearrange the scrambled tiles to recreate the original image. One tile is missing—slide adjacent tiles into the empty space until every piece is in its correct position.
When you solve the puzzle, a Congratulations screen shows your completion time and total moves. From there you can play again with a new image or return to the main menu.
Included puzzle images: Chrysanthemum, Desert, Hydrangeas, Jellyfish, Koala, Lighthouse, Penguins, and Tulips.
puzzlegame-mono/
├── PuzzleGame.slnx # Solution file (VS 2022+)
├── site/ # Static website published with GitHub Pages
└── src/
└── PuzzleGame/ # Main game project
├── Content/ # MonoGame content (images, fonts, puzzles)
│ ├── Fonts/ # Bundled TTF fonts (Liberation family)
│ ├── Puzzles/ # Puzzle image assets
│ └── Content.mgcb # MonoGame Content Builder manifest
├── Gameplay/ # Puzzle board logic
├── Persistence/ # Save/load session state
├── Screens/ # Menu, gameplay, win, credits screens
├── StateManagement/ # Screen manager and input handling
├── Program.cs # Entry point
└── PuzzleGame.cs # Game class
This MonoGame version preserves the spirit of the original Windows Phone 7 game while adapting the UI and input handling for desktop play:
- Mouse and keyboard first — menus respond to clicks, wheel scrolling, and Tab navigation.
- Resizable window — layouts scale smoothly across different display sizes.
- Session persistence — the game saves your progress on exit and restores it on next launch.
The original XNA codebase serves as the behavior reference for gameplay parity decisions.
Christian Resma Helle
christianhelle.com
See the original xnapuzzlegame repository for licensing details.