/snake

игра змейка на C

Primary LanguageC

😊 Hello </coders> 😊

Snake Game

Snake Game

Description

This is a simple implementation of the classic "Snake" game using the raylib library. The game supports multiple difficulty levels and various game levels.

Technologies

  • Programming Language: c logo C
  • Library: cmake logo raylib
  • Build System: cmake logo CMake

Installation and Running

Requirements

  • CMake 3.10 or higher
  • C Compiler (e.g., GCC or Clang)
  • raylib (automatically downloaded and installed via CMake)

Installation Instructions

  1. Clone the repository:
  2. git clone https://github.com/BogdanPryadko4853/snake.git
    cd snake
  3. Create a build directory and navigate into it:
  4. mkdir build
    cd build
  5. Generate the build files using CMake:
  6. cmake ..
  7. Build the project:
  8. make
  9. Run the game:
  10. ./snake

Game Examples

Game Example 1 Game Example 2
Level 1 Level 2

Controls

  • Arrow Keys or WASD to control the snake.
  • Enter to start the game or select a level.
  • R to restart the level.
  • F to restart the game after losing.

Project Structure

snake-game/
├── CMakeLists.txt
├── README.md
├── main.c
├── snake.c
└── snake.h