The forum

[Script] Age of Empires : Gold edition

Author Replies
supertuxtux Saturday 12 December 2009 at 16:26
supertuxtuxAnonymous

Voici un script permettant d'installer et d'éxecuter Age of Empires : Gold edition
(version comprenant Age of Empires et Age of Empires : Rise of Rome)

#!/bin/bash
 
if [ "$PLAYONLINUX" = "" ]
then
exit 0
fi
source "$PLAYONLINUX/lib/sources"

cfg_check

SCRIPT_PREFIX="AGE_OF_EMPIRES_GOLD"
SCRIPT_PREFIX_ABSOLU="$REPERTOIRE/wineprefix/$SCRIPT_PREFIX"
SCRIPT_JEU="Age of Empires : Gold edition"
SCRIPT_EDITEUR="Microsoft games studios"
SCRIPT_SITE_EDITEUR="http://www.microsoft.com/games/empires/"
SCRIPT_AUTEUR="supertuxtux"
SCRIPT_REPERTOIRE="$SCRIPT_PREFIX_ABSOLU/drive_c/Program Files/Microsoft Games/Age of Empires"
SCRIPT_TMP="$REPERTOIRE/tmp/AGE_OF_EMPIRES_GOLD"

LNG_TITRE="Installation de $SCRIPT_JEU"

LNG_DEBUT="Cliquez sur suivant pour commencer l'installation de $SCRIPT_JEU"
LNG_INSTALLATION_1="Installation en cours"
LNG_INSTALLATION_2="Cliquez sur suivant uniquement quand l'installation de\\n$SCRIPT_JEU sera terminée !"
LNG_CONFIG_1="Plusieurs dlls doivent êtres téléchargées\\nafin de permettre au mode multijoueurs de fonctionner correctement"
LNG_CONFIG_DL_1="Téléchargement de dplayx.dll"
LNG_CONFIG_DL_2="Téléchargement de dpnet.dll"
LNG_CONFIG_DL_3="Téléchargement de dpnhpast.dll"
LNG_CONFIG_DL_4="Téléchargement de dpwsockx.dll"
LNG_CONFIG_2="Les dlls ont été téléchargées et installées correctement"
LNG_FIN="Installation terminée !\\n\\nInformation :\\n- Le texte dans les menus du jeu est difficilement lisible\\n\\n- Le jeu plantera si vous essayez de consulter l'aide\\n\\n- Si vous quittez une partie multijoueurs le jeu peut planter\\n  il sera alors nécessaire de redémarrer le jeu\\n\\n- Pour augmenter la rapidité du jeu il est possible de réduire la\\n  résolution de l'écran. Pour le faire, démarrez une partie,\\n  puis allez dans le menu et cliquez sur Options"

LNG_LANCEUR="Age of Empires"
LNG_LANCEUR_EX="Age of Empires : Rise of Rome"

POL_SetupWindow_Init
POL_SetupWindow_presentation "$SCRIPT_JEU" "$SCRIPT_EDITEUR" "$SCRIPT_SITE_EDITEUR" "$SCRIPT_AUTEUR" "$SCRIPT_PREFIX"

POL_SetupWindow_install_wine "1.1.32"

mkdir -p $SCRIPT_TMP
 
mkdir -p $SCRIPT_PREFIX_ABSOLU
cd "$SCRIPT_PREFIX_ABSOLU"
select_prefixe "$(pwd)"
POL_SetupWindow_prefixcreate

Set_WineVersion_Session 1.1.32

POL_SetupWindow_cdrom
POL_SetupWindow_check_cdrom "AOEInst.Exe"

POL_SetupWindow_message "$LNG_DEBUT"
POL_SetupWindow_wait_next_signal "$LNG_INSTALLATION_1" "$LNG_TITRE"

cd $CDROM
wine "$CDROM/AOEInst.Exe"

POL_SetupWindow_detect_exit

POL_SetupWindow_message "$LNG_INSTALLATION_2" "$LNG_TITRE"
POL_SetupWindow_message "$LNG_CONFIG_1" "$LNG_TITRE"

chmod -R 755 "$SCRIPT_PREFIX_ABSOLU"
cd $SCRIPT_TMP

POL_SetupWindow_download "$LNG_CONFIG_DL_1" "$LNG_TITRE" "http://www.dllbank.com/zip/d/dplayx.dll.zip"
unzip "dplayx.dll.zip" -d "$SCRIPT_REPERTOIRE"

POL_SetupWindow_download "$LNG_CONFIG_DL_2" "$LNG_TITRE" "http://www.dllbank.com/zip/d/dpnet.dll.zip"
unzip "dpnet.dll.zip" -d "$SCRIPT_REPERTOIRE"

POL_SetupWindow_download "$LNG_CONFIG_DL_3" "$LNG_TITRE" "http://www.dllbank.com/zip/d/dpnhpast.dll.zip"
unzip "dpnhpast.dll.zip" -d "$SCRIPT_REPERTOIRE"

POL_SetupWindow_download "$LNG_CONFIG_DL_4" "$LNG_TITRE" "http://www.dllbank.com/zip/d/dpwsockx.dll.zip"
unzip "dpwsockx.dll.zip" -d "$SCRIPT_REPERTOIRE"

echo "[HKEY_CURRENT_USER\\Software\\Wine\\DllOverrides]" > $SCRIPT_TMP/dll.reg
echo "\\"dplayx\\"=\\"native,builtin\\"" >> $SCRIPT_TMP/dll.reg
echo "\\"dpnet\\"=\\"native,builtin\\"" >> $SCRIPT_TMP/dll.reg
echo "\\"dpnhpast\\"=\\"native,builtin\\"" >> $SCRIPT_TMP/dll.reg
echo "\\"dpwsockx\\"=\\"native,builtin\\"" >> $SCRIPT_TMP/dll.reg
regedit $SCRIPT_TMP/dll.reg

cp -v $CDROM/DirectX/dplaysvr.exe $SCRIPT_PREFIX_ABSOLU/drive_c/windows/system32/dplaysvr.exe
chmod 755 "$SCRIPT_PREFIX_ABSOLU/drive_c/windows/system32/dplaysvr.exe"

POL_SetupWindow_message "$LNG_CONFIG_2" "$LNG_TITRE"

convert "$CDROM/EMPIRES.ICO" -geometry 32X32 "$REPERTOIRE/icones/32/$LNG_LANCEUR"
convert "$CDROM/AOEX.ICO" -geometry 32X32 "$REPERTOIRE/icones/32/$LNG_LANCEUR_EX"

rm $SCRIPT_TMP -R

POL_SetupWindow_make_shortcut "$SCRIPT_PREFIX" "Program Files/Microsoft Games/Age of Empires" "EMPIRES.EXE" "" "$LNG_LANCEUR"
POL_SetupWindow_make_shortcut "$SCRIPT_PREFIX" "Program Files/Microsoft Games/Age of Empires" "EMPIRESX.EXE" "" "$LNG_LANCEUR_EX"

POL_SetupWindow_message_image "$LNG_FIN" "$LNG_TITRE" "$PLAYONLINUX/themes/tango/question.png"

Set_WineVersion_Assign "1.1.32" "$LNG_LANCEUR"
Set_WineVersion_Assign "1.1.32" "$LNG_LANCEUR_EX"
 
POL_SetupWindow_reboot


POL_SetupWindow_Close
 
exit



Chez moi le jeu fonctionne très bien, multijoueurs compris.
exepté parfois quelques ralentissement

il subsiste quelques problèmes :
-le texte des menus qui s'affiche en noir au lieu de blanc/jaune.
-le fait de consulter l'aide du jeu le fait systématiquement planter.
-le fait de quitter une partie multijoueurs fait parfois planter le jeu

BlondVador Saturday 12 December 2009 at 23:20
BlondVador

Merci pour ce script !

Je ne possède pas le jeu cependant, je te fais confiance.

yaouennec Friday 9 November 2012 at 21:42
yaouennecAnonymous

Salut et merci pour le boulot

l'installation semble se dérouler normalement, mais à la toute fin (quitter dans le menu installation), ça reste tourner indéfiniment.
Après avoir annuler, le jeu n'apparait pas dans la fenêtre executer.

Edited by yaouennec

Quentin PÂRIS Friday 9 November 2012 at 23:55
Quentin PÂRISAnonymous

Ce script est complètement dépassé, il ne faut plus l'utiliser ...