Klondike solitaire game (playable, but unfinished)
Ruby
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
bin
gfx
lib
test/patience
.gitignore
CHANGELOG.md
Gemfile
LICENSE
README.md
Rakefile
patience.gemspec

README.md

Patience

Description

Patience, version 0.1.1

Patience is a card game (also known as Solitaire), which is written in Ruby. The game is based on Ray, a Ruby library for games. Currenlty, Patience runs only on GNU/Linux, although, I'm planning to support it on Windows.

How to play

The play area of Patience (Solitaire) consits of four zones: Waste, Tableau, Stock and Foundation. The goal of the game is to allocate all the cards from Tableau to Foundation. You can drag cards from pile to pile with your mouse. Remember, you can't drop cards anywhere: there are some rules, restricting that mess. Brief rules:

Patience, rules

Stock

  • In the very beginning of each game comprises of 24 cards
  • A click on Stock reveals its card and moves it to Waste
  • You can't drag cards from Stock
  • You can't drop cards onto Stock
  • If Stock is empty, you can refresh it with cards from Waste (if there are any) by clicking the former again.

Waste

  • In the very beginning of each game has no cards
  • You can drag cards from Waste and drop them onto Tableau
  • You can't drop cards onto Waste

Tableau

  • In the very beginning of the game comprises of 28 cards
  • Consists of 7 piles. Each pile has number of pile cards
  • Accepts cards from Waste and other piles from Tableau
  • You can drop only a King onto the freed pile
  • You can move whole (valid) piles onto a proper cards
  • You can drop a card onto a card in the pile, which's lower by one rank and has suit of different color.

    Example:

    Correct drop Wrong drop

Foundation

  • In the very beginning of each game has no cards
  • Consists of 4 piles
  • If the pile of Foundation is empty, it can accept only an Ace.
  • If the pile of Foundation isn't empty, it will accept only cards of the same suit, that are higher by one rank.

Winning conditions

  • All the cards are in Foundation, other zones has no cards.

Requirements

Runs on

  • GNU/Linux

Dependencies

  • Ruby (Tested only on 1.9.3 version)

  • Ray (0.2.0)

Installation

Regular GNU/Linux way

    gem install patience

To launch the game:

    % patience

Irregular way

    git clone git://github.com/kyrylo/patience.git patience

To launch the game:

    % cd patience
    % ruby bin/patience

Credits

License

The project uses Zlib License. See LICENSE file for more information.