Skip to content

samridhi171/Rubik-Cube

 
 

Repository files navigation

Rubik-Cube

GitHub issues GitHub forks GitHub stars GitHub license Website status

Link to Game Demo

https://dev-tanay.github.io/Rubik-Cube/

About the Game

This is a simple and elegant game where you can play Rubik's Cube from your own web browser.

Each of the six faces of the Rubik's cube is in one of the six colors - red, green, yellow, blue, white, and orange.

The visible part of the cube is divided into 26 pieces:

  • 6 central pieces (one colored side)
  • 12 edge pieces (two colored sides)
  • 8 corner pieces (three colored sides)

The 26 pieces are "scrambled" to have different colors on each face.

How to Play

The objective of this game is to get each face of the cube to have a single color.

This can be done in two ways:

  1. Twisting the segments
  2. This can be done by dragging the cursor over the segment you want to rotate.

  3. Changing the view of the cube
  4. This can be done by dragging the cursor in an arrow around the cube.

Installation

  1. Clone the repository
  2. git clone https://github.com/Dev-tanay/Rubik-Cube.git
  3. Navigate to the cloned repository
  4. cd Rubik-Cube
  5. Open the index.html file in a web browser

There, you've opened the game screen!

Navigating the Game Screen

  • Home
  • You'll see two icons, each on the two bottom corners of the screen. They're (1) Leaderboard and (2) Preferences.

    You can start the game by double-clicking on the text "DOUBLE TAP TO START"

  • Game start
  • Once you start the game, a timer will show above the cube.

    Now you'll see only one icon, that is Back.

  • Preferences
  • On clicking Preferences from Home screen, you'll be led to the settings page.

    The options you can change here are:

    • Cube size
    • Flip Type
    • Scramble
    • Camera Angle
    • Color Scheme

    Also, there are two new icons in the bottom corners - (3) Back and (4) Theme.

  • Theme
  • Here, you can adjust the hue, saturation, and lightness of the screen to your liking.

    The new icons in the bottom corners are - (5) Back and (6) Reset.

  • Stats
  • These display the statistics of your Rubik's Cube game. The stats include:

    • Total Number of Solves
    • Best time
    • Average of 5, 12, 25

LICENSE

This project is licensed under the MIT License - see the LICENSE file for details.

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 71.2%
  • CSS 26.1%
  • HTML 2.7%