Giter Site home page Giter Site logo

terminal-rubiks's Introduction

Terminal Rubiks

Rubiks cube game for the terminal

Installation

$ git clone https://github.com/at1as/terminal-rubiks.git
$ cd terminal-rubiks
$ ruby play.rb

The only dependency is the colorize gem (sudo gem install colorize)

Screenshots

3D View

Flat View

Usage

Instructions will be printed as the game starts. The first is cube display settings:

How would you like the cube printed?
    [1] Flat 2D Horizontal View
    [2] Flat 2D Vertical View
    [3] Single Face
    [4] 3-Dimensional View

And the insturctions for moving the cube:

To rotate the cube type any of the following
    `r <row num> <direction>`  (rotate row number <row num> in the direction <direction>)
    `c <col num> <direction>`  (rotate col number <col num> in the direction <direction>)
    `f <direction>`            (rotate cube face in the direction <direction>)

    Examples:
      `r 2 left`  or   `r 2 l`
      `r 3 right` or   `r 3 r`
      `c 1 up`    or   `c 1 u`
      `c 1 down`  or   `c 1 d`
      `f up`      or   `f u`

TODO

  • Shuffle cube
  • Change print display settings mid game
  • CLI feels awkward. Needs some work
  • Print cube after selecting print settings

terminal-rubiks's People

Contributors

at1as avatar jwillems-twilio avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.