Civ 4 on wine

October 5, 2008

This is a short post on how to get Civ 4 with the latest patch working on Wine.

You might want to install DirectX 9.0c first:
DirectX installation

Once Wine configured, we download some files needed to install DirectX:

/usr/bin/wget http://howto.landure.fr/gnu-linux/installer-directx-9-0c-avec-wine/mscoree.dll \
--output-document=$HOME/.wine/drive_c/windows/system32/mscoree.dll
/usr/bin/wget http://howto.landure.fr/gnu-linux/installer-directx-9-0c-avec-wine/streamci.dll \
--output-document=$HOME/.wine/drive_c/windows/system32/streamci.dll
/usr/bin/wget http://howto.landure.fr/gnu-linux/installer-directx-9-0c-avec-wine/gm.dls \
--output-document=$HOME/.wine/drive_c/windows/system32/drivers/gm.dls

And we register DirectX DLLs as native in the registry:

/usr/bin/wget http://howto.landure.fr/gnu-linux/installer-directx-9-0c-avec-wine/directx.reg \
--output-document /tmp/directx.reg
/usr/bin/regedit /tmp/directx.reg

We download DirectX 9.0c installer:

/usr/bin/wget http://howto.landure.fr/gnu-linux/installer-directx-9-0c-avec-wine/directx_mar2008_redist.exe \
--output-document=/tmp/directx_redist.exe

We extract its contents:

/bin/mkdir $HOME/.wine/drive_c/DIRECTX
/usr/bin/cabextract -d $HOME/.wine/drive_c/DIRECTX /tmp/directx_redist.exe

And we install DirectX 9 :

/usr/bin/wine "C:\DIRECTX\DXSETUP.exe"

You can now test your installation by running dxdiag:

/usr/bin/wine "C:\windows\system32\dxdiag.exe"

Note: The test is to actually run dxdiag, don’t expect all tests runned by this software to work.

Once the install done and tested, we can do a little clean up:

/bin/rm /tmp/directx_redist.exe
/bin/rm -r $HOME/.wine/drive_c/DIRECTX

First you should install Civ 4 from the cd.  Go online and download the .dll files below.  Just use google.

msxml3.dll, msxml3r.dll make these native drivers from winecfg

For version 1.61: d3dx9_26.dll

For version 1.74: d3dx9_30[31,32].dll

Now install Civ 4 from the CD. If it tells you to install DirectX try to exit out of the installer.
If that doesn’t work then you need to add the correct d3dx9_*.dll file to /windows/system32/

After you install Civ 4 from the CD download the 1.74 patch and install it.

Now you will need to install a nocd crack for 1.74. This is because the software that checks if the cd is valid doesn’t work in wine. Use google to find the cracked .exe and remember that some of them have bugs and will not work. Just try a different nocd crack.
Just copy the cracked exe over the one you installed.

Next, you should edit some settings to get the best graphics. Run winecfg and go to the graphics tab.
Turn off “Emulate a virtual desktop”, set vertex shaders to none, and turn on pixel shaders.

Now run Civ 4 and make sure it loads. If you get an error saying something about shader libraries you need to add the correct d3dx9_*.dll files. After it loads exit out so you can fix the audio and resolution.

Goto ~/My Games/
and find CivilizationIV.ini
change EnableVoice=1 to 0 and change ScreenHeight and ScreenWidth to match your resolution.

Now try to run the game. Make sure that everything is working. One problem I have is that globe view didn’t work. To fix this try setting the globe view graphics to medium or low in the in game options.

If that didn’t work then you will need to make some reg edits.
Run regedit and change the following keys.
HKCU->Software->Wine->Direct3D->:
OffscreenRenderingMode=fbo
UseGKSL=disable

Now you can enjoy Civ 4 in Wine.
Now to get KOTOR 2 working.

Civilization 4

September 11, 2008

Currently I am playing alot of civ 4.  I almost have it working in wine with verson 1.74.

I also plan on hosting my own wordpress soon so I won’t be updating this for a while.

Not that anyone reads this

Hello world!

August 8, 2008

I have always liked wordpress blogs.


Follow

Get every new post delivered to your Inbox.