Skip to content

tauseef-creator/2048-Game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

2048 Game in C++

This is a terminal-based implementation of the classic 2048 game, written in C++. The project recreates the core mechanics of the popular puzzle game, where players combine tiles with numbers (powers of 2) by sliding them across a 4x4 grid using arrow keys or WASD controls. The goal is to achieve the elusive 2048 tile—or go as far as possible before the grid fills up.

Build and Run

Prerequisites

  • A C++ compiler (e.g., g++ for Linux or MinGW for Windows).
  • Terminal/console access.

Instructions

  • Clone the repository:
git clone https://github.com/tauseef-creator/2048-Game.git
cd 2048-game
  • Compile the code:
g++ 2048.cpp -o 2048
  • Run the game:
./2048    # Linux
2048.exe  # Windows

Controls

  • WASD: Move tiles up (W), left (A), down (S), right (D).
  • ESC: Exit the game.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages