๐ฎ Play a virtual 3D Rubik's Cube on your computer!
This game gives you a realistic 3D Rubik's Cube that you can rotate, scramble, and solve using your keyboard and mouse. Perfect for practicing your solving skills or learning how to solve a Rubik's Cube!
- ๐ฏ Practice Solving: Scramble and solve the cube as many times as you want
- ๐ฑ๏ธ 3D View: Rotate the camera to see all sides of the cube
- โฑ๏ธ Timer: Track how long it takes you to solve
- ๐ฎ Easy Controls: Use simple keyboard keys to turn the cube faces
- ๐ Built-in Help: Press H for controls, F1 for solving tips
- ๐ Instant Reset: Press C to reset to a solved state anytime
You need Python 3.11.9 first - Choose your version:
Windows Users:
- ๐ป Download for 64-bit Windows (Most common)
- ๐ป Download for 32-bit Windows
Mac Users:
- ๐ Download for Mac
Important: When installing Python, make sure to check "Add Python to PATH"!
- Click the green "Code" button at the top of this page
- Select "Download ZIP"
- Save it to your Desktop
- Right-click the ZIP file and select "Extract All"
- Double-click the extracted folder to open it
- Open Command Prompt (Windows) or Terminal (Mac)
- Type this command and press Enter:
pip install pygame==2.6.1 PyOpenGL==3.1.10 PyOpenGL_accelerate==3.1.10 numpy==2.2.6
Double-click the file called rubix-cube.py and start playing!
- R L U D F B = Turn cube faces (Right, Left, Up, Down, Front, Back)
- Arrow Keys = Also turn faces (easier for beginners)
- SPACE = Turn the front face
- Hold Shift + any key = Turn the opposite direction
- S = Scramble the cube (mix it up randomly)
- C = Reset to solved (if you get stuck)
- H = Show help
- F1 = Learn how to solve
- ESC = Quit game
- Drag = Rotate your view around the cube
- Mouse Wheel = Zoom in and out
Your Computer Should Have:
- Windows 10/11 (64-bit or 32-bit), macOS 12.0+, or Linux
- Python 3.11.9 (Required - see installation steps above)
- At least 2GB RAM (4GB recommended for smooth performance)
- OpenGL 2.1+ compatible graphics card (Most computers from 2010+ work fine)
- 200MB free disk space (including Python dependencies)
- Internet connection (for initial setup and Python package downloads)
- Make sure you installed Python 3.11.9 with "Add to PATH" checked
- Try running this in Command Prompt:
pip install pygame PyOpenGL numpy - Make sure you extracted the ZIP file completely
- Update your graphics drivers
- Close other programs to free up memory
- Install PyOpenGL_accelerate for better performance
- Press F1 in the game for solving tips
- Start with making a white cross on one face
- Work one layer at a time
- Use online tutorials for detailed steps
๐ rubix-cube/
โโโ ๐ rubix-cube.py # The game (double-click to play!)
โโโ ๐ README.md # This guide
โโโ ๐ SECURITY.md # Security information
โโโ ๐ LICENSE # Legal stuff
โโโ ๐ requirements.txt # Technical requirements
We'd love your help! You can:
- ๐ Report bugs or problems
- ๐ก Suggest new features
- ๐ง Fix issues if you know programming
- ๐ Improve the documentation
Just open an "Issue" on this GitHub page to get started!
- v1.2 โจ Added help system, better error handling, improved stability
- v1.1 ๐จ Enhanced colors, fixed display issues
- v1.0 ๐ First version with basic 3D cube
This game is free and open source under the Apache 2.0 License. You can use it, modify it, and share it freely!
Full license details: http://www.apache.org/licenses/LICENSE-2.0
Made with โค๏ธ for cube enthusiasts everywhere!
Special thanks to:
- The Pygame community for graphics support
- The PyOpenGL team for 3D rendering
- Rubik's Cube solvers worldwide for inspiration
๐งฉ Happy Cubing! ๐งฉ