Welcome to ColorSnake, a simple snake game built in Java! This classic game allows you to control a snake that grows in length as it consumes food while avoiding collisions with walls and itself.
-
Objective: The objective of the game is to eat as much food as possible to grow the snake's length without colliding with walls or the snake's own body.
-
Controls:
- Use the arrow keys (Up, Down, Left, Right) to control the snake's direction.
- The snake will continuously move in the direction it's facing.
- Avoid colliding with the walls and the snake's body.
-
Game Over:
- The game ends when the snake collides with the wall or itself.
- Your score will be displayed, indicating how much food you've eaten.
-
Scoring:
- You earn points for each food item eaten.
- Try to achieve the highest score possible.
Follow these steps to set up and run the Snake Game:
-
Clone the Repository:
git clone https://github.com/ismaeleBo/ColorSnake cd ColorSnake
-
Compile the Java Code:
javac SnakeGame.java
-
Run the Game:
java SnakeGame
-
Play the Game:
- Use the arrow keys to navigate the snake.
- Enjoy the game and try to beat your high score!
Feel free to customize the game by modifying the code. You can adjust various parameters like the size of the game board, speed of the snake, or the appearance of the snake and food.
Contributions to this Snake Game project are welcome! If you'd like to contribute, please follow these steps:
-
Fork the repository on GitHub.
-
Create a branch for your work:
git checkout -b feature/new-feature
-
Make your code changes and improvements.
-
Commit your changes with clear descriptions:
git commit -m "Added new features"
-
Push your changes to your fork:
git push origin feature/new-feature
-
Open a pull request on the main repository.
If you encounter any bugs while playing the game or have suggestions for improvements, please open an issue on GitHub with detailed information about the problem.
This Snake Game project is open-source and distributed under the MIT License. See the [LICENSE] file for more details.
Have fun playing ColorSnake!