Magic number : 97
#!/bin/bash
# Date : (????-??-?? ??-??)
# Last revision : (2010-05-23 10-00)
# Wine version used : -
# Distribution used to test : -
# Author : bastien09 (last changes by NSLW)
# Licence : Retail
# Depend : -
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"
TITLE="Total Annihilation"
PREFIX="TotalAnnihilation"
WORKINGWINEVERSION="1.1.44"
#starting the script
wget http://upload.wikimedia.org/wikipedia/en/6/6c/Total_Annihilation_Coverart.png --output-document="$REPERTOIRE/tmp/leftnotscaled.jpeg"
convert "$REPERTOIRE/tmp/leftnotscaled.jpeg" -scale 150x356\! "$REPERTOIRE/tmp/left.jpeg"
POL_SetupWindow_Init "" "$REPERTOIRE/tmp/left.jpeg"
POL_SetupWindow_presentation "$TITLE" "GT Interactive Software" "N/A" "bastien09" "$PREFIX"
#asking for CDROM and checking if it's correct one
POL_SetupWindow_message "Please insert $TITLE media into your disk drive."
cd "$CDROM"
CHECK=$(find . -iwholename ./SETUP.EXE | cut -d'/' -f2)
POL_SetupWindow_check_cdrom "$CHECK"
select_prefix "$REPERTOIRE/wineprefix/$PREFIX"
#downloading specific Wine
POL_SetupWindow_install_wine "$WORKINGWINEVERSION"
Use_WineVersion "$WORKINGWINEVERSION"
#creating application's own prefix
POL_SetupWindow_prefixcreate
#fetching PROGRAMFILES environmental variable
PROGRAMFILES="Program Files"
POL_LoadVar_PROGRAMFILES
Set_OS "win98"
#starting installation
POL_SetupWindow_wait_next_signal "Installation in progress..." "$TITLE"
wine "$CDROM/$CHECK"
POL_SetupWindow_detect_exit
#making shortcut
POL_SetupWindow_make_shortcut "$PREFIX" "CAVEDOG/TOTALA" "totala.exe" "" "$TITLE"
Set_WineVersion_Assign "$WORKINGWINEVERSION" "$TITLE"
POL_SetupWindow_message "$TITLE has been installed successfully." "$TITLE"
exit