General Retards Survival Guide to Run EQEMU & MQ2 on WINE &
Reply
Retards Survival Guide to Run EQEMU & MQ2 on WINE &
Retard's Survival Guide to Running EQEMU through WINE in LINUX... w/ MQ2!
V1.1 04/11/09 by 3zek






PART 1 - INTRODUCTION

This guide might be applicable to running EVERQUEST through WINE in general, however I have only tested/written it for EQEMU (aka the TITANIUM pack).

I use upper cases for most names. I don't see this causing any trouble and have made sure to try not to uppercase anything that would be case sensitive! However, LINUX is sensitive to cases so watch out as using the wrong case in a file or command will break your request. I also use single quotes (') around things. Where you see me use these single quotes, you wouldn't actually type them in.

EQEMU was one of the only reasons I didn't do the full switch to LINUX for some time now. I've got it running perfectly now and am here to share how. Note that this addresses the most common problems but unfortunately there may be issues specific to people's set-up.

Getting EQEMU going was a serious headache for me, which ultimately ended up with me having to compile my own WINE with a line of extra code in it's 'device.c' of the D3D9 library. Other people have written about getting this to work, but if you're not entirely LINUX saavy it's not that easy and can go wrong in a million places. 8)

It should be noted that I am using Ubuntu 8.04 Hardy (with the real-time kernel).

There's a few kinks still in running EQEMU once you have it going. For example, mouse-look is confined to the window boundaries of your running game which can be annoying until you get used to it. There's the occasional random crash. Running multiple instances of EQ also gets much slower I've found, though 2-boxing EQ sessions definitely still returns “acceptable” performance and I'm on a laptop, albeit a really nice one.



PART 2 - CHECKING IF YOUR WINE INSTALLATION WILL EQEMU OUT-OF-THE-BOX

A lot of people have had better luck than I though (when I say it was a total pain in the ass). Some people, for whatever reason, can do a regular binary installation of WINE and EQEMU will work off the bat.

So, if you haven't already.

1)Install WINE from binary (should be in your distro's repository or often more up to date binaries can be found on the WINE site [winehq.org]... ). After, run 'winecfg'/'Configure Wine' to set up the WINE directory and to configure WINE to run with your system. Make sure to enable “Vertex Shader Support,” EQ will need this to run.

2)Copy over your EQ installation directory into '~/.wine/drive_c/”Program Files”/' by default or wherever else the WINE tree installed to. I'm assuming you've already set up your EQ installation to work with EQEMU already (changed the login server file, etc).

3)Open a terminal and change directory to where you've just copied EQ:

'cd <wine>/drive_c/”Program Files”/<EverQuest>'

(mine for example is: '.wine/drive_c/”Program Files”/EverQuest'. Note the period at the beginning... this indicates it is a hidden folder. For this reason if you open up your graphical file browser you probably won't see it unless you select “view hidden files,” or something to that effect. Also note I've placed quotations around the directory 'Program Files', this is because LINUX does not readily recognize spaces in file paths and therefore you must use the quotation marks to specify to the command line that is the full name of the directory.)

4)Let's see if the bitch will run... in the terminal type:

'taskset -c 0 wine eqgame.exe patchme'

(It's important that you run it exactly as above... specifying the 'taskset -c 0' prefix will limit EQ to running on the single core of the CPU. WINE has trouble supporting multiple cores with many applications and will result in failure. It is also important to have the 'patchme' flag on the end to bypass the patcher since you're playing EQEMU and don't want the client to start patching automatically. Also on my box, I have found that if I try to run EQ this way by typing the '<full>/eqgame.exe', instead of changing directory and running it locally from the working directory, I will get a XML error. Weird stuff.)

If you're one of the chosen few, it should start right up and you will be able to log in and play as normal. You're as good as done; skip the troubleshooting section to the end. If not...



PART 3 - TROUBLESHOOTING

Now, here are some possible not-so-positive outcomes when you tried to run EQEMU:

1)IT DIDN'T START AT ALL.

If you were launching and have set-up exactly as I have described above, this is more than likely due to a configuration/installation issue of some sort. Maybe in your hardware, maybe just in WINE. Can't help you here... I would urge you to check your hardware/driver/WINE configs, reinstall WINE or try another version of WINE.

2)CAN'T GET PAST SERVER SELECT or CRASH AT CHARACTER SELECT

This means something is going wrong when the game application actually gets in game. This COULD be the same problem as #1 above, but also COULD be fixed by the following other issues.

If you were launching and have set-up EQ/WINE exactly as I have described above in this guide, you may need to add or edit the following lines in your 'EQCLIENT.INI' to reflect these two under '[Defaults]':

'VertexShaders=1'
'TextureCache=FALSE'

Like I said, if they are not already in there then add them. If they are already in there, edit them to be the same.

Further on the subject of the 'EQCLIENT.INI' and EQ settings, I have heard of other issues in their regards. Other things you might want to try along those lines:

A) Download and replace your current file with this clean WINE-friendly 'EQCLIENT.INI' which should have no conflicting settings: http://angeliqe.com/eqclient.ini

B) Make sure you are using the default EQ skin. The “clean” 'EQCLIENT.INI' above should have this specified already. Supposedly some skins/XML can fuck shit up w/ EQ in WINE.

Lastly but definitely not least importantly, MANY people have reported great success with utilizing a hacked 'D3DX9_30.DLL' file to run EQ under WINE. This file is hacked to help WINE properly handle something with vertex shaders which is currently handled differently than in WINDOWS/DIRECTX API. Download the following file and save it in your EQ root folder: http://angeliqe.com/d3dx9_30.dll

3)EVERYTHING IS FINE EXCEPT CHARACTER MODELS ARE MISSING.

This was personally the antagonizing issue which lead me to learn about all other issues addressed in this guide.

Unfortunately, it is also the most difficult to correct for some. HOWEVER... Many have reported that using the hacked 'D3DX9_30.DLL' file from #2 (above) has corrected the issue for them. So try that first and see if you can be spared this experience.

The alternative I regret to say, is we have to recompile WINE with 1 lousy additional line of code to correct the problem the hacked DLL *should* but doesn't fix in all cases.. Now getting WINE to compile can be an art in its own, so from here you should use GOOGLE to find a WINE compile guide specific to your LINUX distribution and version. Make sure to follow it very carefully or it won't compile right! Even if you do follow it right, there might be something not addressed which you will have to trouble shoot on your own. GOOGLE-ing errors is your best friend in this regard. Really, this is the only part that makes this so troublesome!

(PS: the guide for Ubuntu Hardy 64 (my distro here) on the WineHQ wiki site is not really right or complete and never resulted in a successful compile for me. You'll have to crawl for alternative guides in that case.)

The only thing you need to know from me and this guide, is what and where to add the additional code to fix this issue:

A) After downloading and extracting the WINE source code for your distribution/version and doing any other preperations as specified by the compile guide for your distribution/version, we are going to want to go into the source tree and open the '/<wherever>/dlls/d3d9/device.c' file in a plain-text editor.

B) Use the search feature to find the “function” (block of code) named 'Idirect3DDevice9Impl_GetDeviceCaps'. This line will only appear twice in the file, the first will be the “function” block and the second will probably be declarations and such that you need not worry about for this.

C) That “function,” or block of code should end maybe a half-page/page later with the a line that reads 'return hrc'. We want to add the following line of code immediately BEFORE the 'return hrc' line:

'pCaps->MaxVertexBlendMatrices=0x4;'

(In the most recent release of WINE when I write this, 1.1.18, the line you would be adding this code to would be line 360 of 'dlls/d3d9/device.c')

D) Make sure you didn't fuck anything else up, then save the file and close it. Continue to “build” the source as your distribution/version specific guide instructs you to. The compile process probably takes around a hour.

E) If everything compiled alright, and you continued to set WINE/EQEMU up correctly using everything I have instructed before this section... you should now have a fully functional EQEMU via WINE!



4)THERE IS NO SOUND.

First, you might just not have configured it in 'winecfg'/'Wine Configuration'.

Second, many distros are now using the PULSEAUDIO server to handle sound. This is not currently supported in WINE but there is an easy work around using the PULSEAUDIO wrapper/virtual OSS device ('padsp'):

A) Run 'winecfg' from a terminal with the following line to launch it through the PULSEAUDIO wrapper:

'padsp winecfg'

B) Now when 'winecfg' opens up, goto the sound and select 'OSS' as your device. The sound test will still fail at this time unless it was already working, so just save/close 'winecfg'.

C) Run 'winecfg' again through the PULSEAUDIO wrapper 'padsp'. If you did this correctly and the problem was indeed PULSEAUDIO support, the sound test should now pass. You're almost there.

D) Finally, for every WINE application that you would like to use with sound, you will need to run it through the PULSEAUDIO wrapper 'padsp' command. So the proper command to launch EQ in the terminal once in the EQ directory would now be as follows:

'taskset -c 0 padsp wine eqgame.exe patchme'

Voila, sound.



PART 4 - RUNNING MQ2 WITH EQEMU THROUGH WINE

If you don't know what MQ2 is, then you don't need it and you can skip this part. 8)

This is surprisingly easy. Contrary to naysayer's belief, MQ2 runs just fine through WINE with no crazy set-up or configuration:

1)Compile/get/move your MQ2 (binary) files into a folder within the '.wine/drive_c/”Program Files”/' tree. It should technically work fine anywhere else as well, but I prefer to keep my WINE stuff within that WINE virtual file system as a means of isolating potential issues.

(You will need the 2005-11-01 version of MQ2 source to run it on EQEMU from here: http://www.macroquest2.com/downloads/zips.php.) MQ2EMU.com and MQEMULATOR.net also run their own branches off of the 2005-11-01 version and update them for compatibility/functionality with EQEMU [EQ TITANIUM] specifically, so those might be the safer bet for you.)

2)Open up a terminal and change directory to where you just put the MQ2 files.

3)Run MQ2 through WINE:

'wine MacroQuest2.exe'

4)MQ2 will now load up. It should even have the tray icon if your LINUX window manager supports it (I get the tray icon in GNOME).

5)Start EQ through WINE as directed before. MQ2 should now be running as normal – you will know by the MQ2 message windows at the character select screen. If it's not there you done fucked up... do it again, try a different build, etc.



PART 5 - OUTRO AND ADDITIONAL RESOURCES

This guide is the most clear and comprehensive thing I've seen on the subject. I will also try to maintain/upgrade/correct/expand it to some degree in the short term future. However if for some reason what I've said here isn't helping, you should explore some of the same resources I did to get my stuff working:

WineHQ - Appdb - EverQuest page - http://appdb.winehq.org/objectManager.php?sClass=version&iId=2939

WineHQ - Bugzilla - Issue #8357 - http://bugs.winehq.org/show_bug.cgi?id=8357

EQEmulator.net - Forums - WINE Thread - These forums are constantly down. Including at the time of me writing this... so I can't get you the link. However if you can get onto the forums at that URL, there is a semi-helpful thread if you do a search for WINE.
Sat Apr 11, 2009 3:09 pm
Thanks for submitting this stuff
_________________
Give me your land!
Sat Apr 11, 2009 5:52 pm
Co-Founder (Retired)
General Retards Survival Guide to Run EQEMU & MQ2 on WINE &
Reply