ssokolow / game_launcher

An experiment to see how much of a Steam-like experience can be produced without Steam
6 stars 1 forks source link

======================================= Experiment in Steam-less Game Launching

WARNING: This project doesn't yet have a permanent name, so this URL isn't permanent. I merely uploaded this on request.

This is a very Work-In-Progress experiment in how far I can go to produce something Steam-like for DRM-free games without depending on an external service.

Currently, its primary focus is on getting the game provider backends complete, comprehensive, and reliable, so this is what the test GUI looks like:

.. image:: testgui_screenshot.png :alt: Test GUI :align: center

(The blurry Crayon Physics and Delve Deeper icons will be fixed when I bypass the scaled icon caches used by PlayOnLinux and the Desura client and read straight from the source files. The undersized DOSBox icon issue is already fixed.)

At the moment, it supports the following backends:

.. _Desura: http://desura.com/ .. _install.sh: https://gist.github.com/ssokolow/7010485 .. _PlayOnLinux: http://playonlinux.com/ .. _ResidualVM: http://residualvm.org/ .. _ScummVM: http://scummvm.org/ .. _system launcher: http://standards.freedesktop.org/menu-spec/menu-spec-latest.html .. _XDG .desktop files: http://standards.freedesktop.org/desktop-entry-spec/latest/

NOTE: Currently, it preserves no state. While the "Rename..." and "Hide" options in the test GUI do work, they won't be remembered across restarts.

Dependencies

If you want to run the test suite, you'll also need:

.. _coverage.py: https://pypi.python.org/pypi/coverage .. _enum34: https://pypi.python.org/pypi/enum34 .. _Nose: https://pypi.python.org/pypi/nose .. _PyGTK 2.x: http://packages.ubuntu.com/trusty/python-gtk2 .. _PyQt5: http://www.riverbankcomputing.com/software/pyqt/download5 .. _PyXDG: https://pypi.python.org/pypi/pyxdg

NOTE Until I decide on a permanent name, I can't produce an installable package name and, thus, can't test in a virtualenv with tox. As such, I can't guarantee my list of required dependencies is complete.

Also, the test suite doesn't yet exercise the code branches for things like "PlayOnLinux not found".

Usage

. Edit the GAMES_DIRS constant in

src/game_providers/fallback/__init__.py

. Run one of the following:

Ideas (Incomplete)

. Debug logging for anything eliminated from consideration when gathering the

game list and why. (eg. TryExec failed, eliminated by deduplication, etc.)

. Look into merging with Lutris_. They've got a GUI and plans for more

backends. I'm writing more backends and may be satisfied with their GUI.

.. _Lutris: https://lutris.net/

Ideas: Data Model

. Support for moving things like PlayOnLinux, Desura/Desurium, ScummVM, and

ResidualVM out of the list of games (where the XDG backend put them) and into either the context menu for the things their game_providers returned or a menu bar.

. Some kind of automated "install.sh 'GAME_ID' or key generated-from-name

or path or ..." matching combined with not flushing SQLite records on uninstall to allow custom settings to persist should the user ever reinstall a game.

. Support for taking a "local GOG backups" folder and providing a Steam-like

ability to batch-select and install .deb and/or .tar.gz games from it. (At minimum as a proof of concept. LGOGDownloader_ integration later, maybe.)

. Tagging/Categorization, filtering, and sorting

.. _LGOGDownloader: https://github.com/Sude-/lgogdownloader

Ideas: Global Workarounds for Broken Desktops

. Save and restore gamma profiles so that buggy games won't leave the desktop

messed up and games without custom gamma support can be forced to have custom gamma by editing the gamma in another window while the game is running (either using xgamma or the X calls it makes).

. Unified suspension of the screensaver because it looks like nobody's going

to properly fix "Screensaver activation ignores Joystick input" until at least when Wayland replaces X.org.

Ideas: Per-game Workarounds for Broken Games

. Look into ways to make "separate out save/config/log files for backup using

OverlayFS" a more officially supported option, given that it's been in Ubuntu kernels since 11.10 and was mainlined in 3.18.

. Checkbox to automatically wrap joysticks via xboxdrv (Linux) or x360ce

(Windows) for games like Towerfall Ascension which only recognize XBox 360 controllers and need other joysticks to lie about their identity.

. Option to specify an Antimicro_ profile to automatically load so joystick

can be transparently added to games like Cave Story+ which don't natively support joysticks at all.

. LDPRELOAD

[1] <http://www.catonmat.net/blog/simple-ld-preload-tutorial/> [2] <http://www.catonmat.net/blog/simple-ld-preload-tutorial-part-2/> hooks to do things like:

. Support for launching as a separate user somehow as one way to protect my

$HOME from getting doodled on by Wine apps, MojoSetup, and games which use getpwuid() to write non-hidden folders.

.. _Antimicro: https://github.com/Ryochan7/antimicro .. _CUSE: http://bryanpendleton.blogspot.ca/2011/02/fuse-cuse-and-uio.html .. _getpwnam(3): http://linux.die.net/man/3/getpwnam .. _joystick selection: https://imgur.com/sJeiCFK .. _LD_PRELOAD: http://www.linuxjournal.com/article/7795 .. _MetaModes: https://help.ubuntu.com/community/VideoDriverHowto#Twin_View_or_Dual_Head_displays .. _open(2): http://linux.die.net/man/2/open .. _uinput: http://who-t.blogspot.ca/2013/09/libevdev-creating-uinput-devices.html .. _xboxdrv: http://pingus.seul.org/~grumbel/xboxdrv/ .. _x360ce: http://www.x360ce.com/default.aspx

Ideas: End-User Services

. Play time tracking using the following inputs:

. Look into the feasibility of hooking into Linux kernel

process/file-monitoring APIs to autodetect where the game stores its save files so an open analogue to Steam cloud save can be written by plugging into things like Dropbox/Mega/etc.

. XMPP <https://en.wikipedia.org/wiki/Xmpp#Deployments>_ integration for a

Steam chat analogue.

. Matchmaking for DOSBox's IPX tunneling if I can figure out how to do it

well. (LAN broadcast, Internet via XMPP and NAT traversal?)

. A plugin which provides a Launchy_-style resident launcher UI without the

requirement that all of the games clutter up the games submenu in the system launcher.

. A Filelight_-analogous pie chart

view that shows the disk usage breakdown for managed games and provides quick access to any detected uninstall scripts.

.. _Launchy: http://www.launchy.net/ .. _Filelight: https://en.wikipedia.org/wiki/Filelight