Skip to content

This is a simple implementation of the classic Snake game using Java and Swing.

Notifications You must be signed in to change notification settings

sowndharnewbie/SnakeGame-Using-JAVA

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

Snake Game

This is a simple implementation of the classic Snake game using Java and Swing.

Description

The Snake game is a popular retro arcade game where the player controls a snake that grows longer as it consumes apples. The objective is to guide the snake to eat as many apples as possible without colliding with the boundaries of the game screen or its own body.

This project provides a graphical user interface (GUI) for the game using Swing components. It includes features such as snake movement, apple generation, collision detection, and scoring. The player can control the snake's direction using the arrow keys on the keyboard.

Demo

Installation

  1. Clone the repository:

    git clone https://github.com/sowndharnewbie/SnakeGame-Using-JAVA.git
  2. Open the project in your Java IDE.

  3. Build and run the project.

Usage

  1. Launch the game.

  2. Use the arrow keys on your keyboard to control the snake's movement.

  3. Try to eat as many apples as possible and avoid colliding with the boundaries or the snake's own body.

  4. The game ends when the snake collides with a boundary or itself. Your score will be displayed.

Contributing

Contributions are welcome! If you have any ideas for improvements or bug fixes, feel free to open an issue or submit a pull request.

About

This is a simple implementation of the classic Snake game using Java and Swing.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages