Gaming on Linux: A guide for sane people with limited patience
So, you want to play games on your Linux machine. Oh, boy. Batten down the hatches, because we're about to show you how to do some real computing. You ever compiled something, kid? You ever compiled something like we did back in the '90s?
You ever watched a man compile?
Oops, sorry if I frightened you. Truth is, Linux is getting more user-friendly every year, and if you’ve been paying attention to recent developments like Valve’s beta test of Steam for Linux, you might be wondering if you still need Windows in order to reliably use your PC as a modern gaming platform. Here’s the honest truth: You (probably) don’t. It still depends a little on your hardware, but for the most part Linux is as robust a gaming platform as you could ask for. I know you've heard that kind of talk before, but we mean it this time.
To prove it, we're going to show you how to play modern PC games on a Linux PC no matter what kind of hardware you own. This guide will primarily be targeting the newest version of Ubuntu (12.10), arguably the most popular and user-friendly version of Linux, but most or all of it will be applicable to any other Debian-based Linux distribution, such as Mint.
For the purposes of this guide, we're going to assume that you’ve gotten as far as installing Linux, but that’s it; no special expertise is required beyond a willingness to type commands into a terminal.
We won’t be compiling a thing. Promise.
Linux cheat sheet
Here’s a brief rundown of important terms for a novice Linux user:
WINE (which stands for WINE Is Not an Emulator, because Linux users are nothing if not clever) is a compatibility layer used for running Windows programs on Linux. It’s been around for more than 15 years and handles everyday stuff like Office without any trouble, though it was developed primarily for gaming.
A PPA (Personal Package Archive) is a Web address containing one or more prebuilt applications for a specific version of Linux, usually maintained for free by some kind soul. Using PPAs to install third-party software helps sort out compatibility issues and ensures that you get patches automatically.
sudo (Super-User DO) is a command used in front of terminal commands in order to give you administrator rights to change an important part of your system, such as installing drivers. We’ll be using it pretty often, but try not to take its power for granted—there’s a reason you have to type it each time.
Let's get started
First, you’re going to want to install the correct graphics drivers. This depends on your video card—I’ll try to keep this as simple as possible, so you have to worry about it only once. If you’re currently in the market for a video card for use with Linux, the simplest rule of thumb is always to get a mid-tier GeForce card that's at least a year old—as of this writing, that would be a Geforce GTX 560 Ti, for about $175. If you’ve already got a different card, don’t worry just yet—read on.
Getting GeForce drivers for Linux
As I said, this is the simplest and most compatible option. Open a terminal and enter the following commands (you can copy and paste by pressing Ctrl+Shift+V), remembering to press Enter after each one:
sudo add-apt-repository ppa:ubuntu-x-swat/x-updates
sudo apt-get update
sudo apt-get install nvidia-current
Reboot, and you’re good to go. You’ll automatically get updates for this driver in the future.
Intel HD Graphics or AMD Radeons older than the HD 6xxx series
If you don't have an Nvidia GPU, getting Linux drivers is a little more complicated; Nvidia develops its own driver for Linux rather than releasing open-source driver code and letting the Linux community work on it. For better or worse Nvidia is quite good at this, and thus the stable, official release of its Linux driver is usually the best one. Intel and AMD, on the other hand, release their drivers as open-source code, so we’re going to get the fastest (yet still stable) version from a community maintainer.
A disclaimer: These drivers are usually pretty good, but you are getting them from an unofficial source. They won’t always get you performance comparable to what you’d see in Windows, and they may work in slightly fewer bleeding-edge games than the Nvidia drivers, but you shouldn’t have too much to complain about.
To try them yourself, open a terminal and enter the following:
sudo add-apt-repository ppa:oibaf/graphics-drivers
sudo apt-get update
sudo apt-get dist-upgrade
Reboot, and you’re all set. These drivers will also automatically update thanks to the power of the Linux PPA.
AMD Radeon HD 6xxx or newer
If you have a brand-new Radeon GPU, you have a slightly different driver update path ahead of you. The open-source development of AMD's Linux drivers tend to lag behind a bit, so the company provides a closed-source Linux driver for newer cards. Compared to Nvidia’s official Linux drivers these could use a bit more TLC, and performance might not be as good as on Windows, but try them and see what you think; depending on the games you play, there may be no difference at all.
Point your browser to AMD’s website and select your video card and OS (Linux x86_64 in most cases) from the drop-down menu. Download the file and unzip it to the Desktop (just as you would in Windows), then open a terminal and enter the following:
sudo sh amd-driver-installer-catalyst-12.10-x86.x86_64.run
AMD’s installer will run to install and configure the AMD drivers, along with the Catalyst Control Center GPU management software. These may not automatically update, because you didn’t get them from a Ubuntu PPA (there is one, but it’s not always kept up-to-date, so we aren’t using it), but an update option should be in the Catalyst Control Center that you can use to periodically check for new updates.
Reboot, and you’re done. Phew! That’s half the hard part over with.
Installing and Configuring Wine
Even if you’re going to be playing mostly games that have been ported to Linux, Wine dramatically expands your horizons for gaming without Windows, so it’s highly recommended that you install it.
It's easy to get, too; simply open a terminal and run the following commands:
sudo add-apt-repository ppa:ubuntu-wine/ppa
sudo apt-get update
sudo apt-get install wine1.5
sudo apt-get install winetricks
The system may ask you if it can install other packages; go ahead and say yes. Once this is done, it’s time to get in the habit of using Ubuntu key shortcuts—press the Windows key on your keyboard (yes, it’s ironic; there’s a very, very small chance this key won’t have the Windows logo on it, and Linux documentation refers to it as the “Super” key, so just go with it) and type “winetricks”; then press Enter. The Winetricks interface will open.
Winetricks is a little program installed alongside Wine that lets you quickly install necessary Windows libraries without needing to track them down and figure out whether you’re supposed to be installing the version for Windows XP or the version for Windows 7 or any of that. Once it's opened, tick Select the default wineprefix, press OK and then Install a Windows DLL or component; press OK again.
For minimum headache, you'll want to select the following packages from the list:
- everything beginning with “d3dx”
- vcrun2005, vcrun2008, and vcrun2010
- xact, xact_jun2010, and xinput
- optionally dotnet3.5. Skip this for now, but remember it when you see the “Troubleshooting” section below.
After this, click OK, and everything will install; most of it will be in the background, but you may need to click through once or twice. Good news: With that done, the hard part is now over! On to the fun part: playing games.