Age of Mythology on Linux (With Steam)

Today I will show you how you can run Age of Mythology(AoM) on Linux.

To see the precise instructions, you can jump to the section titled How to run AoM on Linux. Or read on for an account of a well spent Saturday.

Why Age of Mythology

This Saturday morning I woke up from a dream where I was playing Age of Mythology. The last time I had played Age of Mythology was in high school, 15-18 years ago! AoM was my first introduction to Norse, Egyptian and Greek mythologies. It was based on the older Age of Empire series which I had also played and loved.

The dream set alight a fire inside of me. I wanted to play AoM again. But - I did not have a Windows machine available. However, I had an unopened box of Civilization VI for the Switch. I set it up. Now I have never played any version of Civ. I had bought it thinking it would be similar to AoE or AoM. To my horror it was turn based! And the map had actual tiles! I was shocked people loved this. Civ is apparently a very popular series of games and I was very, very underwhelmed.

I cried to myself for a while and told myself - don’t whine, time to set up Wine.

Wine on current linux

My personal laptop is a Dell which only runs Ubuntu Linux. It doesn’t have a fancy graphics card. But I have Steam installed on it and it runs many popular games like CS Go and TF2. However, I had never run any Windows-only games on it.

I decided to setup Wine. Wine is a very popular Windows emulator for Linux - people use it to run Windows applications on Linux.

Trying to install wine on my Ubuntu 18.04 and failing

I followed the instructions at https://wiki.winehq.org/Ubuntu to no avail.

Every time I ran the apt install command, I would see confusing errors about broken packages. Googling did not help at all. I scoured the internet looking for a binary I could download for Ubuntu but could not find any.

Building wine from source!

I gave up on apt install and decided to build Wine from source. This takes a LOOONG time and requires the patience of a ten thousand year old tortoise.

Wine has a wiki page on how to build from source. When you run configure, you will know what packages you are missing. These could be specific libraries that are missing from your system. Google the errors and look for appropriate Ubuntu packages that can fix them.

Once configure is happy, run make followed by make install. make took at least an hour for me so I was off thinking about alternatives.

Digging up a 10 year old HP laptop that has Windows 7

While my make for wine was chugging along, I thought “why not resurrect my old Windows laptop?”. You might think, hey, I said I don’t have a Windows machine. I lied.

I have an ancient laptop from 2009 from when I was in Grad school. This is primarily a Windows 7 laptop which dual boots on to an older version of Ubuntu. But there was a problem. I did not know where the laptop was. I began excavating multiple storage closets. After going on numerous detours and finding hidden treasures, I found the laptop and its charger. I cheered and ran to my desk to set it up and charge it.

To my great wonder, the laptop still worked! I booted up Windows and downloaded a really old demo of AoM. The demo worked! I played a random map as Zeus! But the graphics were terrible. Perhaps this was how the game looked in 2002, but this was 2020. The game play was great - but I needed better graphics.

Debugging AoM + Wine on current linux laptops

My Dell laptop has decent support for modern graphics. I can play CS just fine without lag and great rendering. So I went back to my run of make which had finished finally. I ran make install to install iWine.

Now I had two options.

Should I use wine to run the aom.exe file (post-installed or post-extracted)? When I tried this, I saw errors from wine. The program wouldn’t launch.

Should I use wine to install AoM using the installer? I was able to install AoM locally. Locally wine sets up a C:\ drive at $HOME/.wine/drive_c so anything you install in C:\ should be there. However when I used wine to run the game’s exe, it failed to detect a video card :(

Why would wine not detect my video card? I had no idea. I fiddled around with configuring Wine by setting a few Windows registry keys for video & graphics (links in the Resources section) - but this didn’t help.

And that is when I stumbled on Proton.

Wtf is Proton?

From https://github.com/ValveSoftware/Proton#introduction :

Proton is a tool for use with the Steam client which allows games which are exclusive to Windows to run on the Linux operating system. It uses Wine to facilitate this.

So Steam comes inbuilt with Proton, and it includes its own distribution of Wine! I had wasted hours trying to get Wine + AoM running.

How to run AoM on Linux

Steam on Linux comes bundled with a utility called Proton that helps you run games built for Windows.

On protondb.com you can see testimonials from other users on how well a game works with Proton. Here are the testimonials for AoM: https://www.protondb.com/app/266840.

You can lookup any other Windows game on protondb to see how well it performs with proton.

Enabling Proton

On your Steam client, head over to Steam->Settings->Steam Play and enable Steam Play for “supported titles” as well as “all other titles”.

This is how my Settings look:

Enabling Proton

Use the latest version of Proton recommended by Steam.

Steam should you ask to restart it once you enable Proton.

Testing Proton

Before you buy AoM, (unless you have already purchased it), try out a Windows game that is freely available on Steam.

I personally tried out the game called “Trove”. You MUST try out at least one Windows game for proton to be completely setup. I recommend getting a couple of Windows games.

If Steam fails to launch EVERY Windows game, make sure you have python 2.7 installed locally. Find your terminal, and run python. Check if the version is 2.7. My python was pointed at python3 so initially no Windows game worked for me.

Testing AoM demo (or any non-steam game)

If you have at least one Windows game that works with Steam, you can run an additional validation step. This step is not a hard requirement.

You should have a non-steam Windows game to proceed. I used the AoM demo for this purpose.

Copy the non-steam game’s files over to the location of the Steam Windows game that works on your machine. Rename the non-steam game’s EXE file to your Steam Windows game’s EXE file. Voila! When you launch your Steam Windows game, it should launch your non-steam game!

If you are having trouble locating your Steam Windows game’s location, right-click on your game in Steam and click “Properties”. Choose the “Local Files” tab and click on “BROWSE LOCAL FILES”.

Buying AoM and enabling D3D

Now we are at a stage where can buy/download AoM from Steam. I bought the Extended Edition because I wanted to try out the Chinese civilization.

Install AoM and launch it.

If the game fails to launch, enable D3D. I had to enable D3D on my Dell.

Here is how to enable D3D for a game:

  • Right-click on the game title under the Library in Steam and select Properties.
  • Under the General tab click the Set launch options... button.
  • Enter PROTON_USE_WINED3D=1 %command% and click OK.
  • Close the game’s Properties window and launch the game.
  • Details here

Debugging Proton

You enabled Proton and your game doesn’t launch at well. Enable logs and see what is going on.

https://github.com/ValveSoftware/Proton/wiki/Proton-FAQ#where-is-proton-installed

Success!

The joy of playing a game that you enjoyed as a teenager is something else. I think I will end up purchasing the AoE set from Steam as well in the upcoming months. Now you should be able to play most Windows games on Linux using Steam! Enjoy!

Resources

A collection of all the resources that helped me setup AoM on Linux