Skip to content

A replica of the famous 2048 game using Linked Lists and Open Graphics Library(OpenGL) coded in C++.

Notifications You must be signed in to change notification settings

MIDAS1901/GL2048

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 

Repository files navigation

GL2048

A replica of the extremely famous 2048 game made using Linked Lists and Open Graphics Library. It's entirely coded in C++.

We also implemented an optimal algorithm for the next move which makes sure the user, if he/she chooses to apply it, will attain the maximum score(if game ends in a loss) and maybe even win the game which depends on how early the user sarted to utilize this feature after starting the game.

Contributors: Navneet Das Madhukar

This was made for the partial fulfilment of the requirement of an academic project for the subject Fundamentals of Data Structures.

Here's a preview of our project.

GL2048gif

Instructions for Installation

Make sure that your OS has OpenGL installed. Navigate your terminal to the directory where you've downloaded the project. Compile and execute the game using the following commands:

g++ GL2048.cpp -lGL -lGLU -lglut

./a.out

How to play

  1. USE THE W,A,S,D keys to shift the tiles in up, left, down, right direction respectively.
  2. USE THE U key to undo the move you made(you can perform this multiple times).
  3. USE THE R key to restart the game.
  4. USE THE I key to access the Optimal Algorithm for attaining a maximum score(even win too).
  5. USE THE X key to exit the game.
  6. USE THE Right Mouse Button to access the menu and perform the above functions using mouse.

Possible Updates

  1. Availability of larger board size(eg 5x5, 6x6 etc).
  2. A more smoother user experience like in the original 2048 game.
  3. Nothing else, 3 looked better.

Please feel free to suggest improvements.

About

A replica of the famous 2048 game using Linked Lists and Open Graphics Library(OpenGL) coded in C++.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages