个人工具

UbuntuHelp:WorldofWarcraft

来自Ubuntu中文

Wikibot讨论 | 贡献2010年5月20日 (四) 01:02的版本

(差异) ←上一版本 | 最后版本 (差异) | 下一版本→ (差异)
跳转至: 导航, 搜索
  1. title World of Warcraft on Ubuntu

<<Include(Tag/StyleCleanup)>> This howto is for installing and playing World of Warcraft using Wine under Ubuntu. Wine is a free open source implementation of the proprietary Win32 API, and attempts to enable Windows applications and games to run on Unix-like operating systems. World of Warcraft can also be played under Ubuntu by using the Wine based CrossOver Games, Cedega and PlayOnLinux. This howto, however, does not address these three.

Before you get started

In Linux, Direct Rendering Infrastructure (DRI) facilitates faster graphics rendering, so before you begin the installation you should check whether DRI is enabled. To do this, run the following command:

glxinfo | grep rendering

You should see output similar to this:

direct rendering: Yes

If this line says "No", it means that graphics data will not be passed directly to the graphics hardware, thus significantly reducing speed at which WoW will run. This is usually caused by a configuration issue with the graphics card driver. See the troubleshooting section for elaboration. Note though that even if you do have Direct Rendering, it might not be enough. If you graphics card is an Intel GMA, your performance will be low in any case. Most people who successfully play WoW on Ubuntu are probably using an NVIDIA or ATI card with proprietary drivers.

Installing Wine

The official deb package file of Wine from WineHQ's download page, is recommended for most users, as it works almost out of the box for most people, and has a gold rating at the moment. For full instructions on installing Wine see the Wine page.

Deb package

  1. You can easily install Wine through the repositories. Ubuntu will automatically configure and install it for you. You can go to System, then Administration and Synaptic Package Manager, search for it and mark for installation.

You may also use the command line. Simply run:

sudo apt-get install wine

In Ubuntu 9.10, there is a wine1.2 package which should work better. 1.#2 Before proceeding to install World of Warcraft you must run winecfg at least once (it must setup the ~/.wine directory structure before you can install Windows applications into it). This is a very important step. In a Terminal window type the following:

 winecfg

Select your Windows type, configure disk and removable drives, etc, then press Apply and Ok. As it closes, winecfg will create a .wine directory structure in your home folder, populating with information about drives and devices installed in your system. If you fail to do this before trying to install World of Warcraft then you'll probably see errors like the following when running winecfg in the future:

 err:winecfg:apply_drive_changes   unable to define devicename of 'C:'

Compiling Wine from source

Other experienced users, who are unable to make this work or just want more control over the installation, may want to try to compile Wine from source in order to play WoW. Instructions can be found here: https://wiki.ubuntu.com/BuildingWineFromSource

Installing WoW

Original WoW

If you have access to the installation discs is to copy the contents to your hard disk and run them from there. If you have the new DVDs see the note below.

  • Create a convenient directory ( 'wow_install' on your Desktop for example)
  • Copy all of the files from the first WoW CD to this new directory.
  • For each of the remaining WoW CD's, copy just the 'Installer Tome #.mpq' files. In the end, you should have the 'DirectX' directory, and the 'autorun.inf', 'installer.ico', 'Installer Tome.mpq', and 'Installer.exe' files from disc 1, and 'Installer Tome 2.mpq', 'Installer Tome 3.mpq', 'Installer Tome 4.mpq', and 'Installer Tome 5.mpq' from the remaining discs. Note that the 'Installer.exe' file on the first disc is different from the files of the same name on the subsequent discs; if you get the wrong one the install will fail with
     
Unrecognized key "options". (AttributeParser::Parse)
  • Note that on some WoW DVD's the installer executable is hidden and you need to re-mount the disc with the 'unhide' option. To do this type in a terminal:
 sudo umount /dev/cdrom
sudo mount -t iso9660 -o ro,unhide /dev/cdrom /media/cdrom0/
  • Start the installation by opening a terminal and running these commands:
 cd /<path-to-directory>/
 wine Installer.exe

Replace <path-to-directory/> with the right path to the directory where you copied all the files above. Some dialogs during installation may appear blank or garbled, and the installer may even hang for up to 5 minutes at 100% CPU, while appearing to be doing nothing. Simply wait and click next when possible. Note: If you have not already done so, you may want to install Microsoft's|proprietary fonts, because they can solve some text related graphical glitches during installation.

Burning Crusade

The BC install is more or less the same as the base game install.

  • Create a new directory separate from the directory where you copied the original game discs. [B][/B]
  • Copy the 'Autorun.inf', 'Installer.exe', 'Installer.ico', and 'Installer Tome.mpq' files from the first Burning Crusade disc to this new directory.
  • Copy just 'Installer Tome 2.mpq', 'Installer Tome 3.mpq', and 'Installer Tome 4.mpq' from the remaining install discs.
  • Run the installer by opening a terminal and executing these commands:
 cd /<path-to-directory>/
 wine Installer.exe

Replace <path-to-directory/> with the right path to the directory where you copied all the files (the BC files, not the original WoW files).

Alternate Installation Methods

If the above isn't possible for some reason (you don't have the discs for example, or a working media drive), here's some alternate ways to install the game.

Alternative 1 (Copy from Windows):

You can also just install WoW in Windows and then copy the entire World of Warcraft folder over from your Windows installation.

Alternative 2 (Download the Entire Game):

If you have lost a CD, do not have access to a CD drive or simply would not like to bother with patching and messing with the CD's, you can download and run the installer, which is in fact the full game almost fully patched, from the blizzard downloader. They work very nicely with Wine. Installer Downloads: Original WoW - US Version Burning Crusade - US Version (requires a valid account for log in) WoW - European clients, in all languages In order to use the Blizzard Downloader effectively, you must 1) open certain ports on your computer and 2) enable port forwarding on your router.

Firewall Configuration for Blizzard Downloader

The easiest way to open these ports is to use the firewall program Firestarter.

  • From the command line, install Firestarter with this command: sudo apt-get install firestarter.
  • When it is running, select the "Policy" tab, right-click in the Allow Service area, and select Add Rule.
  • Under port, type 6112 and make sure that the "Anyone" radio button is selected. Make a note in the comments field that this port relates to Blizzard.
  • Repeat these steps for ports 3724 and for the range 6881-6999 (which will be recognized as BitTorrent ports).
Router Configuration for Blizzard Downloader

Next, configure your router to forward those ports on the router to your computer only. The steps are similar to the above, but vary slightly from router to router and may be found on Blizzard's website: [1] Once the firewall is configured and the network port forwarding is working, run the downloader with (Burning Crusade US Version example):

wine WoW-BurningCrusade-enUS-Installer-downloader.exe

Configuration

OpenGL or Direct3D

Background

The Windows version of World of Warcraft supports rendering using either Direct3D mode (the default) or OpenGL mode (it can be configured to use OpenGL). On Windows, most people just use the Direct3D mode, as it is the most tested and it has a number of features over the OpenGL mode, such as support for a hardware cursor. In wine, Direct3D is supported only through an emulation layer (known as WineD3D), that runs on top of OpenGL. At the moment, WineD3D lowers the fps enough that most people running WoW using wine tend to use the OpenGL mode instead. WoW can be set to use its OpenGL mode as follows: Find the file wtf/Config.wtf in your main WoW directory. By default it is found in /home/<username>/.wine/drive_c/Program\ Files/World\ of\ Warcraft/, where <username> is you computer login name. Note that since .wine begins with a period, you will not be able to see it, but you may still access it in a terminal. In the Nautilus file manager, you can press Ctrl + h to see hidden files. If config.wtf does not exist, run the game and log into a character, then exit WoW. The game should then have created the file. Open it using a text editor, and add the following line to it:

SET gxApi "opengl"

Hardware cursor in OpenGL

There is a workaround to get a kind of hardware cursor even in OpenGL mode. The workaround is to use a slightly modified version of Wine which will always display the X11 cursor (which is not laggy). If you are interested, there is a thread in the forums discussing it. Instructions explaining how to get started can be found in the thread.

Audio configuration

If you have a recent version of wine (for instance the wine1.2 package in Ubuntu 9.10), your audio should in many cases just work. What will be used in this case is the ALSA driver of wine. Alsa-lib will be sending all its audio out through PulseAudio, as is the case for many applications running on Ubuntu. However, if you are using an older version of Wine and/or Ubuntu, you may need to switch wine to use its OSS driver. To do this, just type winecfg in a terminal, press enter, and the wine configuration application window should appear and you should go to the audio tab. In there, choose OSS. Make sure you only have one sound output system (e.g. ALSA/OSS/ESD) ticked at a time. When an application is outputing sound through OSS, it will (by default) cause conflicts with other applications outputing audio. To solve this issue, make sure your wine is started through padsp (or aoss if you are using a very old version of Ubuntu). So for instance start wine by typing padsp wine WoW.exe rather than just wine WoW.exe.

Voice chat

With the introduction of PulseAudio in 9.10, this section is severely inaccurate -- the main problem for the user in 9.10 becomes separating the "Wine" channels between WoW and Ventrilo, as PulseAudio treats Wine as the same app (i.e. Vent and WoW are all "wine" to PA) Running voice chat applications (such as Ventrilo) in wine suffers from the same potential audio related problems as WoW. Meaning, if you have set up wine to use OSS, you need to start wine as described above (using padsp), or you will not (in most cases) be able to use Voice chat and other audio appliications (such as WoW). Using a newer version of wine combined with the ALSA driver should (in many cases) work fine anyway. As an alternative to running Ventrilo in wine, there is also Mangler.

Playing

Start from the Desktop Icon

Double click the icon you find on your Desktop titled World of Warcraft, this will start the launcher. If you have never used something requiring HTML rendering with Wine you will be prompted to download and install the Gecko rendering engine, you should do this as it will enable the WoW Launcher to display news.

Start from the Terminal

Starting from the terminal is simple, just enter:

wine "C:\Program Files\World of Warcraft\Launcher.exe"

(install when prompted about the Gecko rendering engine) Or, dive right into the game with:

wine "C:\Program Files\World of Warcraft\WoW.exe"

Gnome menu icon

You can make a Gnome menu entry for WoW by doing the following commands in a terminal:

wget http://kde-files.org/CONTENT/content-files/41569-wow-icon-scalable.svg -O WoW.svg
sudo mv WoW.svg /usr/share/pixmaps/
gksudo gedit /usr/share/applications/wow.desktop

Add this to the text editor window, which should have appeared after the third command, change <username> in the Exec= line to your computer login username, and save:

[Desktop Entry]
Encoding=UTF-8
Name=World of Warcraft
Exec=wine /home/<username>/.wine/drive_c/Program\ Files/World\ of\ Warcraft/WoW.exe
Icon=/usr/share/pixmaps/WoW.svg
Terminal=false
Type=Application
Categories=Application;Game;
StartupNotify=false

Note: Remember that you should also edit the Exec= line to reflect your WoW installation path, if you've installed to a special location.

Troubleshooting

Audio troubleshooting

If you experience stuttering, bad sound or no sound what so ever, then there are a few things you could try. In config.wtf set:

SET Sound_SoundOutputSystem "1"
SET Sound_SoundBufferSize "150"

The optimum value for Sound_SoundBufferSize varies depending on you setup.

Graphics troubleshooting

If you are having trouble with your graphics, here is a few tweaks you could try.

Config.wtf

Add the following to Config.wtf:

SET ffxDeath "0"
SET ffxGlow "0"

Note that disabling ffxGlow may also enable antialiasing for some users. If you experience a problem with missing character and object models, and/or the login windows background is black, add:

SET M2UseShaders "0"

regedit tweaks

This is a simple registry edit for Wine that either will either fix crash issues and increase frame rate in game, or it will decrease the performance and even make the game crash. You should give it a try to see what is does for you, as you may always easily remove it again, if it acts negatively for you. Open a terminal window, type regedit and press enter. This will start the Wine equivalent of the windows registry editor. If you are familiar with using the registry editor under windows then this is pretty much the same.

  1. Find this key HKEY_CURRENT_USER\Software\Wine\
  2. Highlight the wine folder in the left hand pane by clicking left on it. The icon should change to an open folder
  3. Right-click on the wine folder and select [NEW] then [KEY]
  4. Replace the text New Key #1 with OpenGL
  5. Right-click in the right hand pane and select [NEW] then [String Value]
  6. Replace New Value #1 with DisabledExtensions (Notice it's case sensitive!)

1.#7 Then double click anywhere on the line, a dialog box will open.

  1. In the value field type GL_ARB_vertex_buffer_object

More troubleshooting can be found at WorldofWarcraft/Troubleshooting.

Support and discussion

For support and discussion on the subject of this howto, please post at: http://ubuntuforums.org/showthread.php?t=579378

External links