Return to Level1Techs.com

So, You Wanna Use Wine for Video Games?

linux
gaming
wine

#1

Why hello there inquiring reader. As of this post, I have been pushed to do a post on how to do wine. Because of some health things and recent discoveries I have been a bit side tracked, but am taking the time to do this now as I believe some new linux users are coming into view here and are interested in how to game using wine.

Now a brief history here. First time I used wine was on a Lenovo B575 APU laptop back in 2012. I think….. 1.4 or 1.5 had just come out? There were a lot of hurdles because a lot of code had to be done by hand. .NET had not become open source yet and a lot of things didn’t work very well. Since steam wasn’t on linux yet, a lot of people were using wine, including me. Since then I have become rather well acquainted with its weird little tendencies and I know somewhat what its capable of, though recently I haven’t really been playing with it as much as I used to 1-2 years ago. I haven’t had time to stress test every version of wine, and with so many versions coming out nowadays with so much progress I couldn’t hardly keep up with the devs. Just keep in mind I’m not 1:1 with it anymore so a lot of my info might be a bit dated, but relevant to how to use it.

So what is wine? Many people think it is a VM or an emulator, some think its magic, most know it as a compatibility layer. “What do you mean by that? Compatibility layer?” Well, in windows, you have compatibility layers for older versions of the OS that cover old kernel features, DLL’s that no longer get maintained or don’t work anymore, or older processor features that are no longer available in the modern OS you might be using. For example, the draw systems in windows 95 are no longer available as of Windows XP, so you would use a compatibility layers to get whatever 3D app you had in your XP machine to work, whether CAD or a game.

The same applies here in linux with Wine. Wine essentially is tied to the linux systems we have today, such as pulseaudio, OpenGL, and kernel drivers such as AMDGPU. All it does is provide you with a runtime, Gecko or Mono, and makes features available to linux that you don’t normally have by default. Some OS’s have tried to make Wine a main system feature, such as YLMF or Lindows, but have failed as an answer.

Now that we have that covered, what are we talking about today? Mostly games, though office apps work too like MS word, or a web browser if you really wanted the windows version for some reason. I’ll talk about different apps you can use for Wine and how some games, such as DOOM, run just fine vs others, such as League of Legends.

As of now the newest version of Wine is 2.12 and is available in many repositories. In ubuntu you have to install a PPA version from here whereas in arch you can simply do

 sudo pacman -S wine

and have Wine ready to go. Other apps that can be paired with Wine are rather useful, such as PlayonLinux or PlayonMac, which are basic GUI managers for apps and provide install scripts for apps such as Steam or Battle.net, or WineTricks which provides an easy way to install different DLL’s or other things to your base wine installation.

Wine runs separate from PlayonLinux in what are called Prefixes. Each Prefix is like a separate windows installation and many prefixes can be installed at once, or, you can run everything off of one prefix. In PlayonLinux you can install steam games individually, or install steam and try to run everything in the one singular prefix. Normally people will advise to run individual prefixes as each game wants its own wine configuration to work. By that, I mean that wine needs to be configured a certain way to get syscalls to work correctly, so each game having its own prefix is generally preferred over one overall prefix. Because I’m a fat lazy piece of shit, I generally run everything in my normal wine prefix from the Wine package, and then have PlayonLinux for further configurations for more tricky games. Because of this, I spent some time optimizing a configuration in winecfg, the wine configuration tool.

Here is a picture of the tool and a bit of my package list.

Here is how I generally configure the base Wine package:

Under General, leave the windows configuration at its default. Before the default was Windows XP, its now Windows 7.

Under Libraries, I have these packages selected:

d3d10
d3d10_1
d3d10core
d3d11
d3d8
d3d9
all d3dcompiler packages
d3dim
d3drm
all d3dx10 packages
all d3dx11 packages
all d3dx9 packages
all msvcm thru msvcrt packages
sxs
tdi.sys
traffic
uxtheme (specifically disabled via the edit… button)
vbscript
ass vcomp packages
vcruntime140
winebus.sys
winegstreamer (I play with gstreamer a lot)
winemapi
winehttp (handles web calls, like the browser in the steam shift+tab screen)
wininet
all xaudio packages
xpssrvcs

This configuration is made as general as possible. I went for the basic windows install when I originally made it and as wine has improved I have added some things as they showed up. For PlayonLinux, it automatically sets what packages need to be in place. Steam, and other game managers, already install some of these packages, but I like to have them in place for when the calls don’t always work.

Looking to the d3d packages specifically for this, the calls made with these packages go either to your GPU driver, or to the OpenGL handler then to your driver. Some games make more use of these calls than others. For example, if you ran something like TF2 through wine it would exclusively use these calls only, even if you had the windows OpenGL version installed there would still be d3d calls made every once in a while. Now, with that, if a game uses something like OpenGL it will be forwarded to the OpenGL handler directly. There isn’t a wine package for OpenGL as that would be a bit extra for it. I don’t know if Wine installs anything to the OGL handler to handle windows calls or not? I assume theres something to that though.

Other games, such as DOOM, which use render engines like Vulkan can run basically natively and make syscalls to the GPU driver directly. Depending on what calls are made, there are positives and negatives to this. Some calls can be natively handeled, and in the case of DOOM all calls can be. If a game such as Dota 2 were to be run there are some OGL calls that are ignored and this can hurt performance. Sometimes this can also create artifacts, so if you have an OpenGL version of a game you may or may not get good FPS / native performance.

To PlayonLinux, there are many advantages and disadvantages to using it. Mostly, games will have an up-to-date install script and are kept up in the listings pretty well. In other cases games, such as League Of Legends, are kind of a crap shoot whether they are kept updated or not. POL offers some neat features aside from install scripts, such as the ability to have many versions of wine installed. Because of this you can easily change out what version of wine you want an app to run on. Example being, steam runs on wine 1.7.33, but you can change it out for 2.9 to get the windows 7 features.

Here is a few pictures of POL and some of the menu’s.


The POL main window


The install button leads to this window. You download a cache with every update to POL for these lists and scripts.

The config button leads to here. The following images are the other tabs.


This tab is basically winetricks (or is winetricks?). To install a package, you select a prefix from the side tab, then select a package and install it.

You can change the renderer if you have other renderers available. By default you get gdi and opengl. Don’t worry, I don’t know what gdi is either.


And lastly, this is what an error looks like. My steam install broke so this is what I get now. I need to create a new prefix and just move the files over.

There is a never wersion of PlayonLinux called POL5, but it has very little scripts ported to it yet. It is, however, much easier to use. Some future updates will help with the scripts problem (I may also just be using it wrong).





This version is simplified for ease of use. One click, done. Everything is right in front of you as well so no alt-menus! Its still being worked on and isn’t completely done yet, but for the work that is there I think it is worth keeping an eye on.

PlayonLinux is really cool if you just want to handle all of this crap fast and easy and provides easy changes to everything. Recently though, I found an app that I am replacing POL with called Lutris. Lutris is basically the same as POL, providing the same tools and support as it but also providing an easy one-click install arrangement from their website http://www.lutris.net and account sync to your steam account so you don’t have to leave steam open. It also handles some emulation, and has one-click installs for linux native games such as 0AD or GLTron.

Heres what Lutris and the site look like.





Everything in my steam account has been synced to Lutris via the My Account tab, though for obvious reasons I won’t show that page. The process for using the site is simple: Sign up, install lutris, verify via email, sync your steam account, sign in on the Lutris app, select a game from your library OR search for a game in the games tab, select “Add to my Library”, hit “Install”, play your game. The site has more than Wine games, as I said, with 0AD being an example, but another one being if you had, say, amiga disk images from your copied legal floppies on your PC such as “Another World” you could search for AW on the site and install it in Lutris and it would install UAE and ask for your disk images and all of a sudden off and away you go! On the app you can also see a list of “Runners” for different things. Wine, Steam, whatever. As I said earlier you can use just this app to manage your games and never open steam if you don’t want to. It will close steam when you are done to save CPU, though I don’t know how many people will use it like that.

Personally, I have Lutris installed to handle Battle.Net and League Of Legends. League actually works fine from the site configuration, but BN has some problems launching any game. I can’t run overwatch, hearthstone, or WoW but I have run them in base Wine in the past. My guess is the Lutris setup isn’t done perfect and still needs some tweaks, which is fine. From Lutris you can configure wine, use winetricks, all of the things in POL as I said. Its very simple and easy to use.

So, for all of that stuff you have many ways to use wine and now a general config for your base wine configuration. There are many tweaks you might have to make depending on your GPU, though I never have had to make them as I use AMD GPU’s and the open drivers. I dunno about NV cards so don’t ask me for help XD

There is plenty of information available on the Arch Wiki about Wine and there is an app database available right on the wine website. Links posted below.

Enjoy some windows games ya scamp!

https://wiki.archlinux.org/index.php/wine
https://appdb.winehq.org


Right, thats it, choose my next project
#2

I'll keep eyes on this.


#3

For the sake of coverage, crossover is not wine and I have never used it, though I'm sure someone will have used it in the lounge. From what I know about it its for business software and thats pretty much it.


#4

Crossover is not Wine, but it's based entirely on it. To the extent that Codeweavers as a company makes up something like 2/3 of the commits for the Wine Project.

Everything they do goes upstream to Wine first and then trickles down into Crossover Commercial product.

Last 3 months are mostly game downloads. Seems that there's no reason it wont do the same things Wine does, while also giving you a 1st party to contact for support if you get hung up.


#5

Ah. I don't know much about it 3:


#6

Bump.


#7

Long time wine and POL user. Hadn't heard of Lutris. I'll give it a go, thanks for the informative post.


#8

Ever since I started using linux, and soon found wine was pointless, it didn't take me long to figure, until maybe it is perfect, I'll just stick to native programs. Maybe it helps though as soon as my pc journey started, it has only been on linux. Every now and then though, I do have to start my old laptop occasionally, for programs like Twitch Leecher, spending pesky itunes gift cards, and having a search engine when I break my computer.

Only thing I see as worth it to run in wine is the adobe suite, or other professional programs not on linux people depend on. In the context of games, don't support my platform of choice, well I simply won't buy the game. Only game I broke the rule for was Undertale, but it runs on my laptop, and has Linux support now.


#9

https://en.wikipedia.org/wiki/Graphics_Device_Interface ?


#10

Hey look 389 views.

Neat.

Now if only there were comments :U


#11

What's the deal with uxtheme being disabled??


#12

With UXTheme disabled it kills the steam overlay which can break a lot of games. Some games that are tiny, like Jotun or Drift Streets Japan, can run with UXTheme native. But disabling it for games like AOE2 and up can gain a lot of stability. I have it turned off because I like my games to not crash, but games that use web pages in the game I have wininet and winhttp enabled.


#13

This might be something that lets me stop dual booting my desktop...


#14

Ho crap a one click install for LoL. Is this real life. Nice tutorial/blog btw.


#15

so this happened


#16

LOL thats amazing.


#17

oof dat 16 likes tho


#18

Gunna exploit the necro rules here because of new users. Top kek, top sad if locked tho.


#19

Necro rules still apply. 4 month necro. Self bumping ones own thread is not okay. Thread is locked.


#20