Sunday, May 13, 2012

New jrpg packages available

I am sleepy... by black_eyes from flickr (CC-NC-ND)
jrpg is an awesome game, but it suffered from a bit of software rot - I didn't update it for years and libraries used by it worked less and less well with new graphics drivers etc.

I did some minor updates and repackaged Windows version for Python 2.7.3 and Pygame 1.9.1. You can now download fresh packages from jrpg's website.

Please test it and if you have any problems please report them.

py2exe replaced by pyInstaller

Unfortunately since the time I last updated jrpg, py2exe got pretty much abandoned - they still don't have Python 2.7 packages.

I searched for replacements, and the one that seemed most promising was pyInstaller - it even had an added bonus of working under both Windows and OSX (and even Linux, not that Linux users actually need that, or I'm going to bother packaging 20 different versions of jrpg for each distribution).

It just suffered from two problems:
  • It crashed on OSX
  • It crashed on Windows
Which made it sort of not as useful as it might otherwise be.

I finally managed to fix source of the Windows crash, so there are now new packages for you, but still no OSX version.

It was a fairly classic case of "Python people don't write unit tests", since any kind of unit testing, even "run program with no arguments, see that it doesn't crash" kind would find this bug. The biggest difference between Ruby and Python is not technology, it's Python's pathological culture of One True Way To Do Things Even When The One Way Is Fucking Wrong.

So happy about fixing the bug, I tried to submit the patch, and then:
  • pyInstaller's bug tracking server crashed on me (and I tried a few times)
  • pyInstaller's mailing list bounced emails saying it doesn't exist
The fuck is wrong with this program? It just doesn't want to be fixed. Hopefully email I sent to one of maintainers directly worked better.

OSX support

Since OSX doesn't have real packaging system, people have to use crap like FailPorts, and of course jrpg does not work with Python and PyGame installed with FailPorts. At least not for me. With FailPorts you never know, you might be more lucky.

If you want to use jrpg on OSX please download Python and PyGame packages from their respective websites, install them, extract jrpg's source package and run that (jrpg.py that is).

I'll give making one click OSX package another try sometime later, but with track record of Python packaging programs so far, I wouldn't be holding my breath.

6 comments:

  1. Anonymous06:00

    For OS X, have you looked at Homebrew?

    ReplyDelete
  2. I tried MacPorts and fink, both were absolutely awful.

    If I ever wanted to reinstall OSX again I might as well try Homebrew this time, but I've been doing enough reinstalling operating systems recently.

    ReplyDelete
  3. Just had myself a play - do like it, but is there a way to play Windowed in Windows?

    ReplyDelete
  4. Korvar The Fox: If you use the prebuilt package currently there isn't any way.

    If you use source version (and install Python and Pygame separately) you can edit this line in jrpg.py:

    full_screen_mode = True

    to this:

    full_screen_mode = False

    I don't remember if it worked correctly under Windows or if it caused some driver problems. It's been long time since I last updated jrpg, and every system's graphic drivers worked a bit differently, and usually different full screen vs windowed even on the same system.

    Mode needs to be selected at start on Windows and I'd need to provide a second .exe with windowed mode. I never bothered since nobody requested it before, but if it works for you I might provide windowed .exe (or some other kind of configuration) later. Just give it a try and tell me how it went.

    ReplyDelete
  5. I made the changes you said, and it works fine!

    ReplyDelete