World of Goo for Linux – unofficial Patch

Jan-26th-2009

UPDATE: All problems described below have now been fixed in beta 7 of World of Goo for Linux. Great work!

First of all, a quick link section.

Download link: Unofficial_WoG_Patch.tar.gz

Instructions: extract to the World of Goo directory (where the file “WorldOfGoo” sits).

Usage:

  • Really basic usage! just double click the “WoGFixLinux” icon!!
  • command line usage: ./WoGFixLinux [--only-fix-sound] [--only-fix-compiz] [--verbose]

See below for more details….

OK, merely to help, not hinder the amazing game that is the World of Goo and the great work being done to port it to the Linux platform, let me please make public the patch has fixed two problems in the beta versions (upto beta 6b at the time of writing). The two problems are:

  1. Compiz + SDL + gnome screensaver. This is a known bug, filed in various bug databases. Basically the problem being that when the gnome screensaver expires (mouse movements are not registered in the game is seems?), the World of Goo game goes from fullscreen to windowed screen. At a random time, it will return to fullscreen. It is not a bug in WoG.
    • My work around is straight forward: Disable Compiz, for the duration of the game. See below for method
  2. Sound issues:
    • WoG come pre-packaged with SDL sound libraries. For me, there are two problems with it being done this way. First of all, it means that my pulseaudio volume control does not handle the sound, thus not allowing me full control of this sound stream. This leads to problem 2:
    • I have two output devices – My speakers from my soundcard, and my VOIP USB phone. Without my pulseaudio integration, I cannot specify that my default output device is my souncard. Therefore, I am stuck listening to WoG through my USB headset. Resolution?
      • Again, very straight forward: Use system SDL libraries. This allows pulseaudio to see the output stream, and therefore I can change the output device to my speakers. Success!

I doubt either problem will be fixed in the official WoG Linux release for two reasons:

  1. The Compiz problem is a known issue, and from what I’ve seen, the only workaround is to either disable compiz (which my patch does for you), or disable gnome screensaver
  2. Without the pre-packaged SDL libraries included, there is a problem for those users without SDL sound and SDL mixer installed. I did not have these installed (32bit packages required!) prior to WoG installation. I run Fedora 64bit.

Prerequisites:

  • 32bit SDL sound libraries. The package name for this differs between distro releases
  • 32 SDL Mixer libraries.
  • fusion-icon (optional). This is beneficial as the tool will read the configuration for “loose binding” and “direct rendering”. Without this package, compiz will reload with default settings.

How it works:

  1. If the main.cpp file has not yet been compiled to “compizreader”, it does so.
  2. the bash script reads the arguments (–only-fix-sound etc…) and calls only the necessary parts of the script.
  3. If compiz is to be fixed, it is replaced with either Metacity, Kwin or xfce WM.
  4. If sound is to be fixed,  the pre-packaged SDL files are renamed, and therefore not picked up by the WorldOfGoo application.
  5. On game exit, if compiz was disabled, then it is re-enabled depending on fusion-icon settings, if they exist
  6. If sound was fixed, then the SDL files are renamed to their original filename.

Open Source

In the interests of keeping this place open, and because there’s nothing to hide, you can see the source code here:

  • The bash script WoGFixLinux
  • The C++ program that returns your correct compiz settings main.cpp

Disclaimer

This setup has only been tested on my machine. I run nvidia, 64bit Fedora, with 32bit SDL libraries, with fusion-icon etc etc… This has not been tested extensively. I would therefore appreciate feedback on how this works for you. If it works well, I’d like to know, if not so well, that’s also important.

Add A Comment

By Rob