A comprehensive, feature-rich, open source, and portable, collection of Solitaire games.

Overview

StretchView

PySol Fan Club edition

This is an open source and portable (Windows, Linux and Mac OS X) collection of Card Solitaire/Patience games written in Python. Its homepage is http://pysolfc.sourceforge.net/ .

The maintenance branch of PySol FC on GitHub by Shlomi Fish and by some other people, has gained official status, ported the code to Python 3, and implemented some other enhancements.

  • Build Status AppVeyor Build status

Screenshots

Image

Requirements.

Installation.

We provide an installer for Windows (requires Windows XP SP3 or higher) as well as an Android package on F-droid.

For installation from source, see: http://www.python.org/doc/current/inst/

Running from source without installation.

You can run from the source directory:

python pysol.py

After following steps similar to these (on Mageia Linux ):

Step 1 - install the dependencies

On Fedora you can do:

sudo dnf builddep PySolFC

On Mageia you can do:

sudo urpmi git make pygtk2 pygtk2.0-libglade gnome-python-canvas tkinter

On Debian / Ubuntu / etc. you can do:

sudo apt-get install cpanminus make perl python3-setuptools python3-tk

Step 2 - build PySol.

You can try running:

python3 scripts/linux-install.py
git clone https://github.com/shlomif/PySolFC.git
cd PySolFC
# Now make sure you have installed the dependencies.
gmake test
gmake rules
ln -s data/images images
tar -xvf PySolFC-Cardsets-2.0.tar.bz2 # Needs to be downloaded from sourceforge
mkdir -p ~/.PySolFC
rmdir ~/.PySolFC/cardsets
ln -s "`pwd`/PySolFC-Cardsets-2.0" ~/.PySolFC/cardsets
python pysol.py

Note! If you are using a Debian derivative (e.g: Debian, Ubuntu, or Linu Mint) and you are getting an error of "No cardsets were found !!! Main data directory is [insert dir here] Please check your PySol installation.", then you likely installed the cardsets package which has removed some files that are needed by pysol from source (without the debian modifications).

Please uninstall that package and use the cardsets archive from sourceforge.net per the instructions above.

Installing from source and running in a python venv (virtual environment)

At the moment, this only works on POSIX (Linux, FreeBSD and similar) systems. Windows and Mac users - you'll need to chip in with a script for your system.

1 - Install build prerequisites: six, random2 and pysol-cards

This is kind of stupid and maybe it can be fixed in the future, but for now:

pip install six
pip install random2
pip install pysol-cards

You may want to use your OS distribution package system instead, for example:

sudo apt-get install python-six
sudo apt-get install python-random2

For Pillow compilation, libjpeg headers and libraries need to be available:

sudo apt-get install libjpeg-dev

2 - Clone the source from version control

git clone git://github.com/shlomif/PySolFC.git
cd PySolFC

3 - Create your virtual environment.

PKGTREE=/usr/local/packages/PySolFC # or whatever
export PKGTREE
mkdir -p "$PKGTREE"
( cd "$PKGTREE" && python -m venv ./env )

4 - Run the install script

./contrib/install-pysolfc.sh

5 - Put cardsets into place as above.

6 - Enjoy playing

"$PKGTREE"/env/bin/pysol.py

Alternate toolkit.

  • Kivy (10.0 or later)

  • Features:

    • Sound support integrated.
    • Android apk build support.
  • Running from source without installation:

python pysol.py --kivy

Configuring Freecell Solver

If you want to use the solver, you should configure freecell-solver ( http://fc-solve.shlomifish.org/ ) by passing the following options to its CMake-based build-system: -DMAX_NUM_FREECELLS=8 -DMAX_NUM_STACKS=20 -DMAX_NUM_INITIAL_CARDS_IN_A_STACK=60.

Install Extras.

Related repositories and links

Related:

Other open source solitaires:

  • solitaire.gg - web-based and written in Scala
  • Solitairey - web-based written in JavaScript
  • KPat - desktop-based for KDE.
  • Aisleriot - desktop-based by the GNOME project with relatively limited functionality.

Screencasts:

Chat

To facilitate coordination about contributing to PySol, please join us for a real time Internet chat on the ##pysol chat room on Freenode (note the double octothorpe/hash-sign/pound-sign) . We may set up chat rooms on different services in the future.

In addition, we set up a Google Group for discussing open source card games which will also be used for discussing PySol. Feel free to subscribe or post!

Comments
  • [idea] Publish a flatpak on Flathub

    [idea] Publish a flatpak on Flathub

    Flatpak is a distribution-agnostic package system where the application is shipped with all the dependencies and runs inside some kind of sandbox. It's relatively new, and is gaining quite a lot of popularity.

    Additionally, Valve's Steam Deck supports Flathub out-of-the-box. In fact, its main OS is mounted read-only, so people must either use flatpak or manually install it themselves in their home directory. The easiest way to run anything on Steam Deck is through Flathub. (Well, the easiest is actually through Steam store itself.)

    opened by denilsonsa 62
  • Windows 10 some options windows hang

    Windows 10 some options windows hang

    Installed game from official Windows installer, hangs when trying to select cardsets. Sorry, haven't found where logs are to attach. If I close this blank window, game window also closes.

    Снимок экрана 2021-10-02 223745

    opened by Nebula-Mechanica 33
  • Convert the code to Python 3

    Convert the code to Python 3

    As Python 2.x is going away, we need to convert the code to use Python 3 instead. A prerequisite for that is to merge duplicate or mostly duplicate code that uses the APIs that were removed in Python 3.

    opened by shlomif 29
  • General discussion thread

    General discussion thread

    Update: Discussions are better held on the Google Group .

    I've got a question. Should we wait with bug reporting and feature requests until the Python 3 port will be ready? Or maybe we should create new tickets now to facilitate the creation of a roadmap/development plan for the future and discussion? It's obvious that the implementation of some features can take a very long time and that some stuff is low-priority.

    Apart from our own ideas, I suggest looking at the biggest solitaire packages on the market, i.e. Pretty Good Solitaire, SolSuite, and BVS Solitaire Collection (even in a virtual machine), as well as at some open source solitaire apps to see if we find something interesting.

    opened by jan-kleks 27
  • Prepare an MS Windows Binary Installer

    Prepare an MS Windows Binary Installer

    We wish to prepare a functional Windows binary installer that will install cpython (preferably 3.x) and then the pysol sources and provide a usable way to run it for non-technical people. Some leads:

    • This /r/Python thread - https://www.reddit.com/r/Python/comments/8237i3/help_is_needed_in_preparing_a_windows_binary/

    • The artifacts produced by appveyor - see https://ci.appveyor.com/project/shlomif/PySolFC . They don't seem to be usable in a windows 7 x86-64 virtualbox VM.

    Help wanted 
    opened by shlomif 22
  • Hanafuda decks can be slow to load

    Hanafuda decks can be slow to load

    Could use another opinion or some extra testing on this if anyone's available.

    As part of my effort to improve the look and feel of PySolFC, I've created a higher resolution Hanafuda cardset based on some Creative Commons images I found online. Very nice looking cardset - problem is it takes a very long time to load. I think it has something to do with the fact that Hanafuda cardsets require a large number of unique card bottoms - load times got worse when I added those in. Unfortunately, performance issues are not really my specialty and it could just be the computer I'm testing on. I tried using a second computer, which has much higher specs than the first. It loads at a reasonable speed there, but there's still some noticeable lag. Could use a few more tests to determine how much of an issue this could be.

    I think the slowness is coming from the use of Pillow's paste method, though replacing this could be a rather major refactor. If the extra bottoms are involved, adding some universal Hanafuda suit icons to replace the cardset specific bottoms might be another option, but I'd have to find some.

    Here is the cardset in question - I plan to PR this to the cardset repo once I feel a little better about the functionality:

    cardset-louie-mantia-hanafuda.zip

    Note that some of the Hanafuda games do currently have layout issues with this cardset. I'm aware of these and working on fixing those.

    opened by joeraz 18
  • No moves possible in Scorpion Tail

    No moves possible in Scorpion Tail

    Tried to play Scorpion Tail, and I can't seem to make any moves. Not even the demo can make any moves. The only thing I can do is deal out the stock, but then after that I still can't make any moves.

    This is on version 2.8.0 on Windows 10.

    opened by Arcorann 16
  • New name and promotion

    New name and promotion

    When you finish porting PySolFC to Python 3 and you add SVG support (to make PySolFC resolution-independent), you can definitely think about a name change. My suggestion is: PySol+ (BTW, PySolFC was a strange name in the first place).

    That would be the right time to think about promotion too:

    -- create a very simple website using: https://pages.github.com/ Including info on your efforts as well as on PySol's history and legacy.

    -- tell people that PySol is still alive in the form of PySol+ using reddit, Hacker News, Slashdot, and GamingOnLinux (these website are frequented by those who are "in the know", they gonna tell the others about the project). A lot of users are really nostalgic about PySol, but they simply don't know that your repo exists. It took me some time to find it as well.

    -- create a Patreon account (nice example: https://www.patreon.com/Nekotekina) to earn some cash because why not?

    enhancement 
    opened by jan-kleks 16
  • v2.6.0 - Launch error

    v2.6.0 - Launch error

    Issue:

    PySol Fan Club edition v2.6.0 crashes at startup.

    Log:

    Traceback (most recent call last):
      File "pysol.py", line 36, in <module>
      File "C:\projects\pysolfc\pysollib\main.py", line 30, in <module>
      File "C:\projects\pysolfc\pysollib\app.py", line 32, in <module>
      File "C:\projects\pysolfc\pysollib\images.py", line 28, in <module>
      File "C:\projects\pysolfc\pysollib\pysoltk.py", line 45, in <module>
      File "C:\projects\pysolfc\pysollib\tile\toolbar.py", line 29, in <module>
      File "C:\projects\pysolfc\pysollib\ui\tktile\menubar.py", line 7, in <module>
      File "C:\projects\pysolfc\pysollib\hint.py", line 36, in <module>
      File "C:\projects\pysolfc\pysollib\util.py", line 26, in <module>
    ImportError: No module named 'site'
    

    (Win8.1Pro,x64)

    opened by THEtomaso 14
  • Remove random2 dependency

    Remove random2 dependency

    Dear pysolfc developers,

    I'm a Debian Developer working on the pysolfc package. Yesterday I have looked into packaging the latest version of pysolfc and stumbled across the fact that random2 is not packaged into Debian. Unfortunately python-random2 is most likely not going to be packaged into Debian since it's not actively maintained, and its usefulness is very unclear.

    What's exactly the reason why you needed to replace the random builtin ?

    Thanks for your work.

    opened by hlef 14
  • Mint / Publish a new stable 2.2 Release - what needs to be done beforehand?

    Mint / Publish a new stable 2.2 Release - what needs to be done beforehand?

    I want to publish a new stable release, in part because from my experience people do not adequately test the prereleases and because we now have a usable windows package (thanks @Programator2 !).

    So what needs to be done?

    We need a usable release announcement in reddit-compatible markdown - @jan-kleks - can you help?

    Are there any show stopping bugs?

    I suppose the Android / Kivy port does not have to block it and we can keep it py2-only for now - @lufebe16 - what do you think?

    Anything else?

    opened by shlomif 14
  • Solitaires with Russian deck

    Solitaires with Russian deck

    Russian deck is a regular card deck but without cards from 2 to 5 (thus consisting of 36 cards instead of 52). Is it possible for you to implement solitaires analogical to these with 52 cards?

    For example, "Russian" Yukon would use 6 rows of cards instead of 7 and 4 open cards in each row (except the first) instead of 5. Klondike-like solitaires would use 6 rows instead of 7 as well.

    opened by schw0reismus 3
  • would like to have more versions of mau mau and other additions

    would like to have more versions of mau mau and other additions

    https://github.com/TokisApps/tokisapps.github.io/blob/main/20221011180532.pdf

    the document is in german by the way i cannot code it that well with such quality

    so YOU MUST DO IT

    thanks in advance

    opened by TokisApps 1
  • Pysol 2.18 android no file/storage permissions.

    Pysol 2.18 android no file/storage permissions.

    Pysol 2.18 on Android 11 has permission only for photo and media, not file/storage. This prevents saving games, settings, options, etc. This is not the case on 2.8.

    android/mobile 
    opened by DanKrabach 2
  • Pysolfc import function

    Pysolfc import function

    For the pysolfc penguin game, when you export a game and then import the exported game, the results are wrong. I think the import function is broken for the penguin game. It appears that export is correct. I cannot import a user generated game either. Thanks, Don.

    opened by donnsd 3
  • Touch controls don't work under Steam Deck game mode

    Touch controls don't work under Steam Deck game mode

    How to reproduce:

    1. Get a Steam Deck (that's the expensive part).
    2. Switch to Desktop Mode (which is just KDE/Plasma).
    3. Use Discover to install PySolFC from Flathub.
    4. Launch PySolFC. Observe how everything works fine in Desktop Mode. Both the mouse input (emulated via the trackpad) and the touch screen input can be used to play the game and interact with the menus.
    5. Add PySolFC as a non-steam game to Steam.
    6. Return to Game Mode.
    7. Go to your Library (under the Game Mode), then find PySolFC from your non-steam games section.
    8. Configure the controller input to emulate a web browser. That's the one that maps mouse to the right trackpad.
    9. Launch PySolFC under the Game Mode on Steam Deck.
    10. BUG!
      • The mouse input works fine.
      • The touch screen input doesn't work at all.

    I don't know what makes PySolFC special (maybe the TK library?), because other tools or games like Warble, LBreakoutHD, Google Chrome, VLC (all installed from Flathub) work fine under the Game Mode (although the pop-up menus can get buggy, but that's a different issue) and they all can be controlled with both (emulated) mouse and the touch screen. But somehow PySolFC doesn't accept touch controls.

    Steam OS Game Mode uses gamescope as the compositor; while the desktop mode uses the standard KDE/KWin/Plasma environment. I don't know if they use X11 or Wayland or both.

    It might be possible to reproduce this bug using gamescope under other Linux distros, but you probably need a touch screen anyway. Or possibly by running some version of Steam OS under a virtual machine with emulated touch screen. I don't know, I haven't tried those options.

    opened by denilsonsa 0
  • [Feature Request] Add mahjong (not solitaire), domino, Chinese domino, etc.

    [Feature Request] Add mahjong (not solitaire), domino, Chinese domino, etc.

    There are still more games available. Here are what I have gathered (together with board games): https://polyglotclub.com/wiki/Language/Multiple-languages/Culture/Tabletop-Games

    opened by GrimPixel 1
Releases(pysolfc-2.18.0)
Owner
Shlomi Fish
I'm an Israeli software developer, writer and humorist. You can learn more about me from the pages of my home site (link below).
Shlomi Fish
Sukoku-solver Python About Sudoku is one of the most popular puzzle games of all time

Sukoku-solver Python About Sudoku is one of the most popular puzzle games of all time. As a logic puzzle, Sudoku is also an excellent brain game. Bein

Harshith VH 1 Nov 20, 2021
Deliver buycraft orders to players across the map in minecraft servers using baritone

Deliver buycraft orders to players across the map in minecraft servers using baritone

synthels 1 Nov 14, 2021
A quantum version of Ladders and Snakes

QPath-and-Snakes A quantum version of Ladders and Snakes Desarrollo Para continuar el desarrollo sin pensar en instalación de dependencias: Descargue

2 Oct 22, 2021
Made to help you create UI using pygame in python, gonna add way more to this project

Pygame visualizer Made to help you create UI using pygame in python, gonna add way more to this project. As of now, this is only hours worth of work.

Ayza 2 Feb 08, 2022
🍦 Cheat for cs:go written in Python.

Cs::Fuck 🍦 Cheat for cs:go written in Python. You can show a video here: https://vimeo.com/642730650 Feature. TriggerBot Glow Esp NoFlash Setup. 0. p

Ѵιcнч 10 Sep 23, 2022
Launch any Heroic-Games-Launcher game using bash scripts without having to open Heroic.

HeroicBashLauncher Ever wanted to launch your EGS games installed through Heroic Games Launcher directly from the terminal, Lutris or any other fronte

288 Dec 27, 2022
Quiz game made entirely with python and pygame for school work

Tabela de conteúdo Descrição Como instalar Linguagens usadas Contribuidores Créditos Problemas com o jogo? Contate-nos Descrição Quiz feito inteiramen

3 Apr 12, 2022
Wordle for the terminal, writen in python

Wordle Wordle in the terminal, written in python Simply run bash run.sh in your terminal to run. This creates a virtual environment, installs the depe

Matthew Lidell 1 Feb 09, 2022
Open source Board Games Like Tic Tac Toe, Connect 4, Ludo, Snakes and Ladder etc...

Board-Games What to do... Add Board games like Tic Tac Toe, Connect 4, Ludo, Snakes and Ladder etc... How to do... Fork the repo Clone the repo git cl

Bit By Bit 1 Oct 10, 2022
Simple implementation of the classic Snake Game in under 100 lines of code

Snake_Game Simple python implementation of the classic Snake Game in under 100 lines of code. Printscreen of the game: Imported Libraries: random; pyg

Raffaele Fiorillo 2 Jun 13, 2022
Tic Tac Toe game developed in python; have 2 difficulty levels

Tic Tac Toe Game This is a code for Tic Tac Toe game in python. Game has 2 difficulty levels. Easy Hard To play the game, use this command in a LINUX

Akshat Mittal 1 Jun 25, 2022
Simple python 3D vector3 math library wrapping some types from GLM library using pybind11.

vmath Simple python 3D vector3 math library wrapping some types from GLM library using pybind11. Description Both pure python version and C++ version

6 Aug 02, 2022
Bingo game now in python play as much you want :) no need to give me credit it's open as fuck

Bingo-py-game A game coded with Python Introduction This is a Terminal-based game currently in its initial stage. I am working on adding more efficien

Frey 5 Aug 12, 2021
Cricket game using PYQT

Cricket-game-using-PYQT This is a Fantasy cricket Desktop application build in p

Sanket Mane 1 Jan 03, 2022
Tictactoe py tkinter canvas - Tic Tac Toe written in Python 3 with tkinter mainly using canvas

Python 3 Tic Tac Toe with tkinter This is a tkinter version of my Tic Tac Toe ga

Bojan Adzic 1 Jan 09, 2022
Pyxel is a retro game engine for Python.

Pyxel is open source and free to use. Let's start making a retro game with Pyxel!

Takashi Kitao 11.2k Jan 09, 2023
A "finish the lyrics" game using Spotify, YouTube Transcript, and YouTube Search APIs, coupled with visual machine learning

Singify Introducing Singify, the party game! Challenge your friend to who knows songs better. Play random songs from your very own Spotify playlist an

Josh Wong 4 Nov 19, 2021
Ladder network is a deep learning algorithm that combines supervised and unsupervised learning

This repository contains source code for the experiments in a paper titled Semi-Supervised Learning with Ladder Networks by A Rasmus, H Valpola, M Hon

Curious AI 505 Nov 15, 2022
EL JUEGO DEL GUSANITO

EL JUEGO DEL GUSANITO El juego consiste en una línea que no para de moverse, el usuario lo controla con las flechas de: → derecha ← izquierda ↑ arriba

Valeria Saidid Miranda Ibarra 0 Dec 19, 2021
Building a Mario-like, classic platformer game in Python using the PyGame Library

Building a Mario-like, classic platformer game in Python using the PyGame Library

Clarence Vinzcent Reyes 1 Feb 06, 2022