https://github.com/lostjared/generic.puzzle.game.javascript
conversion of my Rust Demo "Generic Puzzle Game" to HTML5/JavaScript
https://github.com/lostjared/generic.puzzle.game.javascript
blocks javascript-game puzzle puzzlegame
Last synced: 9 months ago
JSON representation
conversion of my Rust Demo "Generic Puzzle Game" to HTML5/JavaScript
- Host: GitHub
- URL: https://github.com/lostjared/generic.puzzle.game.javascript
- Owner: lostjared
- License: mit
- Created: 2024-05-30T17:31:56.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-05-31T06:20:11.000Z (almost 2 years ago)
- Last Synced: 2025-06-06T03:03:44.082Z (12 months ago)
- Topics: blocks, javascript-game, puzzle, puzzlegame
- Language: JavaScript
- Homepage: http://lostsidedead.biz/puzzle
- Size: 6.26 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Generic Puzzle Game

This is a JavaScript implementation of a generic puzzle game that involves managing a grid and manipulating blocks. The game features different levels, a scoring system, and resets the game if blocks fill up to the top of the grid.
## Features
- Dynamic grid and block management
- Scoring and leveling system
- Game reset functionality
- Responsive to keyboard input for block movement
## Game Controls
- **Arrow Up**: Rotate the block colors
- **Arrow Down**: Move the block down
- **Arrow Left**: Move the block left
- **Arrow Right**: Move the block right
- **A Key**: Shift Left
- **S Key**: Shift Right
## Installation
1. Download or clone the repository.
2. Ensure you have a local web server setup to serve the game files, or simply open the `index.html` file in a browser.
## File Structure
- `index.html`: The main HTML file that sets up the canvas and includes the JavaScript.
- `puzzle.js`: Contains the game logic and rendering functions.
- `img_converted/`: Directory containing all the game graphics.
## Usage
Open `index.html` in a web browser to start the game. Use the arrow keys to control the blocks.
## Development
### Prerequisites
- A modern web browser
- A text editor or IDE for editing HTML and JavaScript files
### Running the Game
1. Open `index.html` in your web browser.
2. Use the arrow keys to control the game blocks.
### Editing the Game
1. Open `puzzle.js` to modify the game logic.
2. Open `index.html` to modify the HTML structure or styles.
## Contributing
Feel free to fork this repository, make improvements, and submit pull requests. All contributions are welcome!
## License
This project is licensed under the MIT License.