#!/bin/bash
if [ "$PLAYONLINUX" = "" ]
then
exit 0
fi
source "$PLAYONLINUX/lib/sources"
cfg_check
if [ "$POL_LANG" == "fr" ]; then
LNG_MFC42_DL="Téléchargement de mfc42..."
LNG_WAIT_END="Appuyez sur \"Suivant\" UNIQUEMENT quand l'installation du jeu sera terminée\nsous peine de devoir recommencer l'installation."
else
LNG_MFC42_DL="Downloading mfc42..."
LNG_WAIT_END="Click on \"Next\" ONLY when the game installation is finished\nor you will have to redo the installation."
fi
cd $REPERTOIRE/tmp
rm *.jpg
wget $SITE/setups/halo/left.jpg
POL_SetupWindow_Init "" "$REPERTOIRE/tmp/left.jpg"
POL_SetupWindow_presentation "Halo : Combat Evolved" "Microsoft Games" "http://www.microsoft.com/games/halo/" "GNU_Raziel" "Halo"
POL_SetupWindow_cdrom
POL_SetupWindow_check_cdrom "Setup.Exe"
select_prefixe "$REPERTOIRE/wineprefix/Halo/"
POL_SetupWindow_prefixcreate
cp $CDROM/mgspid.dll $WINEPREFIX/drive_c/windows/system32/
cp $CDROM/PidGen.dll $WINEPREFIX/drive_c/windows/system32/
if [ ! -e $REPERTOIRE/ressources/ ]; then
mkdir -p $REPERTOIRE/ressources/
fi
cd $REPERTOIRE/ressources/
if [ ! -e $REPERTOIRE/ressources/mfc42.dll.zip ]; then
POL_SetupWindow_download "$LNG_MFC42_DL" "Halo : Combat Evolved" "http://www.dllbank.com/zip/m/mfc42.dll.zip"
fi
cd $WINEPREFIX/drive_c/windows/system32/
unzip $REPERTOIRE/ressources/mfc42.dll.zip
regsvr32 mfc42.dll
Set_OS "winxp"
fonts_to_prefixe
wine d:\\Setup.Exe
POL_SetupWindow_message "$LNG_WAIT_END" "Max Payne 2 : The Fall of Max Payne"
Set_Managed "On"
Set_DXGrab "On"
POL_SetupWindow_reboot
POL_SetupWindow_make_shortcut "Halo" "Program Files/Microsoft Games/Halo" "halo.exe" "Halo.xpm" "Halo : Combat Evolved"
POL_SetupWindow_Close
exit