https://github.com/sleekpanther/rush-hour-game
C++ implementation of the board game Rush Hour (Windows exe download only)
https://github.com/sleekpanther/rush-hour-game
board board-game c-plus-plus car cplusplus cpp game glut hour ice-cream-truck noah noah-patullo noahpatullo opengl patullo rush rush-hour
Last synced: about 2 months ago
JSON representation
C++ implementation of the board game Rush Hour (Windows exe download only)
- Host: GitHub
- URL: https://github.com/sleekpanther/rush-hour-game
- Owner: SleekPanther
- Created: 2017-05-06T01:48:06.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2017-05-18T22:35:39.000Z (almost 8 years ago)
- Last Synced: 2025-01-15T13:08:05.188Z (4 months ago)
- Topics: board, board-game, c-plus-plus, car, cplusplus, cpp, game, glut, hour, ice-cream-truck, noah, noah-patullo, noahpatullo, opengl, patullo, rush, rush-hour
- Homepage:
- Size: 1.64 MB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Rush Hour Game
The [classic board game](https://en.wikipedia.org/wiki/Rush_Hour_(board_game)) implemented in `C++` using OpenGL
# [Download (windows only)](https://github.com/SleekPanther/rush-hour-game/releases/latest)

Unfortunately I can't compile code for Mac
## Demo
## Code Notes
- All board setups are stored in vectors as a list of integers, but can also be read from their respective file
- 1st line is [number of horizontal vehicles] followed by [number of vertical vehicles]
- Next number is [length of the special vehicle] (how many coordinate pairs)
- Then the coordinates of the special vehicle one 1 line (e.g for `length=2`, coordinates are: x1 y1 x2 y2)
- Then [length of the 1st horizontal vehicle]
- Followed by its coordinates
- Then the vertical vehicles, length followed by their coordinates
- The current moves & vehicle positions are saved to the progress file: `.delete_this_file_if_program_dies`
Sometimes the whole program will crash & `vector` will go out of bounds if the file is corrupted
Simply delete it & the program will create a new one
- The 1st line in the **Progress file** is the previous score, all following lines follow the pattern outlined above