Skip to content

jvfresco/react-rubik-cube

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This project was bootstrapped with Create React App.

Try a live version of the application here

React Rubik Cube

Web application that renders a playable version of a Rubik Cube in a 3D environment

With this project I wanted to go one step further and I learned how to use three.js. It is implemented using the React Three Fiber library

  • React
  • React Three Fiber
  • Functional components, hooks and custom hooks

Game functionalities

  • Controls

To displace a row or a column, click and drag in the axis direction of the expected movement. The minimum and maximum movement is a quarter turn each time
To rotate the camera, simply click and drag outside the rubik cube.

  • Options

Shuffle: randomly shuffles the cube.
Solve: traces back all movements to the beginning (there is not a solving algorithm implemented).
Undo: returns back one movement.
Redo: repeats an undone movement.

To do, or improve

  • Winning status recognition.
  • Implementation of solving algorithms.
  • Fix a bug existing when changing the axis when the face is dragged in the same movement.

About

Web application that renders a playable version of a Rubik Cube in a 3D environment

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published