I made a post on another message board about running Machinarium under Linux.
I hope this helps some other Linux users, and if you see any mistakes, please share the corrections!
It looks better in my original post on the other message board due to formatting.
========== Machinarium ==========
This game is entirely point and click Flash-based, but it's a work of art in of itself. Here is what I did to get it to work. You need to first extract the .tar.gz archive.
tar xfvz Machinarium_full_en.tar.gz
Rename the directory, and then with root privileges, copy the entire contents into /opt/machinarium/. With rsync, the backslashes (or missing backslashes) make a big difference! I left out the backslash in the source directory on purpose. Why rsync instead of cp? Because if anyone's looking over your shoulder, they'll think you've got tech creds. "Wow, rsync? That sounds complicated!"
mv Machinarium machinarium
sudo rsync -rt --progress machinarium /opt/
You can safely remove the original directory after rsync finishes.
Next you'll need to correct the file permissions.
sudo chmod 755 /opt/machinarium/Machinarium
sudo chmod 644 /opt/machinarium/{00,01,10,11}/*
Now you need to create a .desktop menu shortcut that specifies /opt/machinarium as the working directory. If you don't do this, you will only see a black screen when you run the game, unless you cd into /opt/machinarium/ first. It's more convenient to create a menu shortcut that does this for you anyways. Make a file called machinarium.desktop and save it in $HOME/.local/share/applications/ if you want it accessible by the current user only. If you want it to be globally visible, save it as root under /usr/share/applications/. Here is what my machinarium.desktop file contains. Notice the Path= line.
[Desktop Entry]
Name=Machinarium
GenericName=Flash-based story game
Comment=Flash-based story game
Path=/opt/machinarium
Exec=/opt/machinarium/machinarium_launcher.sh
Icon=/opt/machinarium/machinarium_icon.png
NoDisplay=false
StartupNotify=true
Terminal=false
Type=Application
Categories=Game;LogicGame;
To add a nice touch, download an icon and save it, as root, under /opt/machinarium/machinarium_icon.png. The above .desktop shortcut already points to this file as the "Icon", so it should show up in your menu. Here is the icon that I used:
http://darkhavans.deviantart.com/art/Machinarium-Dock-Icon-141463511sudo cp Machinarium_Dock_Icon_by_Darkhavans.png /opt/machinarium/machinarium_icon.png
You must create a simple launcher to get around the "black screen" issue. This launcher is already referenced in the above .desktop file in the Exec= line. Under /opt/machinarium/, make a new file called machinarium_launcher.sh and add these contents within.
#!/bin/bash
### Simple launcher for Machinarium.
### Fixes issue with black screen, mouse clicks, and working directory.
# Change the working directory to match the executable's directory
cd /opt/machinarium/
# Now launch the Machinarium executable, with a fix for some mouse issues
GDK_NATIVE_WINDOWS=true /opt/machinarium/Machinarium
exit 0
Now make this launcher executable.
sudo chmod +x /opt/machinarium/machinarium_launcher.sh
Try running the game from the menu now.
The game developers recommend that you disable Flash hardware accleration for better performance. I find this to be true, strange as it may sound. You can test this out for yourself. Right-click the screen, go to Settings, then uncheck hardware acceleration. When you launch the game, it will say "Press ESC to exit full screen." This is not the game displaying the message; it's Adobe Flash. You see the same message when you full screen a YouTube video. ESC does not exit full screen. After clicking on the title, you need to bring your mouse cursor towards the bottom of the screen to access the options and controls. Try to disable full screen mode as soon as you can! We know how Flash and Linux aren't best of friends, and this games run much better in windowed mode. You can also try lowering the quality under the View options after you enter windowed mode.
If you use BleachBit, make sure to add this folder to your whitelist, or else you'll lose your saved games and preferences. If you prefer, you can also just exclude Flash cookies from being deleted, since this is how the game stores user settings and saves.
/home/username/.macromedia/Flash_Player/#SharedObjects/XXXXXXXX/#localWithNet/opt/machinarium/Machinarium/
Enjoy!