Getting sound to work with the age of empires 2 no-cd patch
This article is about getting sound working with the no-cd patch for age of empires 2 – The Conquerors expansion pack. I like to play games on my PC but I don’t like having to keep changing cds so I use no cd patches to get the games to run without the cd. The problem with this is sometimes, the music for the games is stored on the cd, to solve this problem I will be using some popular comand line applications and a script
Under Windows
The first thing you need to do is get the mp3, you can get this here;
Then you have to get two command line utilities;
smplayer – get the “package with installer” version
This application will be used to play the mp3 file. Create the following folders;
c:\scripts and c:\scripts\command
we then need to add the c:\scripts\command directory to your users path so that the programs stored there can be used by our script. to do this;
Start > Settings > Control Panel > System > Advanced > Environment Variables
change from
%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;
to;
%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\scripts\command
note that all we are doing here is adding “;C:\scripts\command” to the end.
Now that this step is done install smplayer as you would any other program. Then go to the directory you installed it in and copy the contents of the mplayer folder to your c:\scripts\command folder;
Now that mplayer is installed you can go to the next step. If you want to check that mplayer is installed correctly and that the path is set, open a dos prompt and type mplayer you should get this;
pskill
PSkill is a command line application that can be used to shutdown applications via the terminal, in this case we will be using it to stop mplayer at the end of the game, get it here;
To install it unzip the file and copy the contents of it’s folder to the c:\scripts\command folder. The first time you use it it will ask yo to accept a eula. execute the “pskill” command (in dos) to get this out of the way now.
Move the mp3
Now that’s done, you should create the following folder;
c:\scripts\data
and move the mp3 to there and rename it to “aoe.mp3″
Create the script
To create the final script, open notepad and write the following;
start mplayer -loop 0 c:\scripts\data\aoe.mp3
cd "\Program Files\Microsoft Games\Age of Empires II\age2_x1\"
age2_x1.exe -nostartup
pskill mplayer
Then save the file as “c:\scripts\aoe.bat”, this saves the file as a windows batch script. It is possible that the game is under a different directory to this to find the directorty it’s under right click the games shortcut, select properties and click find target.
The script works like this; it starts playing the file with mplayer in a separate process (that’s why “start” is used), then it starts the game once the games window is closed it kills mplayer stopping the music.
Now remove the shortcut for the game from the desktop and replace it with a shortcut to the script, rename the shortcut to the script with the name of the original shortcut “The Conquerors” for example. Then right click the shortcut, select properties and select the change Icon option;
If an error comes up just click ok and when asked to select an icon, just go to the games directory and select the right icon (.ico file) and click apply/ok and you should end up with the game working with the background it’s not perfect but it beats playing in silence.
Under Linux
Install mplayer with you distros package manager or from source, download the mp3 file;
install the game with wine and use a script similar to this to play
Edit the script to suit your situation. You can probably setup the icon with your DE but I use a window manager so I’m not too concerned with icons.














Trackback by Webmaster
Please e-mail me your contacts. I have a question webmaster@spottovo.ru” rel=”nofollow”>……
Thank you!!!…