@@ -5,115 +5,119 @@
# Author : GNU_Raziel
# Licence : Retail
+#
+#
+# Changelog:
+# 2019-04-20: repair dead URLs. Still some 3 URLs to find replacements for (cdn.sciagnij.pl). Dadu042.
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"
-
+
TWEE="0"
TITLE="The Witcher : Enhanced Edition"
PREFIX="thewitcher"
AUTHOR="GNU_Raziel"
PVERSION="1.5"
-
+
# Starting the script
POL_SetupWindow_Init
-
+
# Starting debugging API
POL_Debug_Init
-
+
POL_SetupWindow_free_presentation "$TITLE" "$(eval_gettext 'Welcome in the patch $PVERSION installer for $TITLE')"
-
+
# Checking Enhanced Edition file
if [ -e "$POL_USER_ROOT/wineprefix/$PREFIX/drive_c/ENHANCED_EDITION" ]; then
- POL_SetupWindow_message "$(eval_gettext 'This game already have Enhanced Edition\nand only need patch 1.5')" "$TITLE"
- TWEE="1"
+ POL_SetupWindow_message "$(eval_gettext 'This game already have Enhanced Edition\nand only need patch 1.5')" "$TITLE"
+ TWEE="1"
fi
-
+
# Checking if game is installed
POL_SetupWindow_checkexist()
-{
- if [ ! -e "$POL_USER_ROOT/wineprefix/$1" ]; then
- POL_SetupWindow_message "$(eval_gettext 'Game is not installed.')" "$TITLE"
- POL_SetupWindow_Close
- exit 0
- fi
+{
+ if [ ! -e "$POL_USER_ROOT/wineprefix/$1" ]; then
+ POL_SetupWindow_message "$(eval_gettext 'Game is not installed.')" "$TITLE"
+ POL_SetupWindow_Close
+ exit 0
+ fi
}
POL_SetupWindow_checkexist "$PREFIX"
-
+
# Setting prefix path
POL_Wine_SelectPrefix "$PREFIX"
-
+
# Check if it's Steam version
STEAM=`find $WINEPREFIX -name "Steam.exe"`
if [ "$STEAM" != "" ]; then
- POL_SetupWindow_message "$(eval_gettext 'Steam have is own automatic update system.')" "$TITLE"
- POL_SetupWindow_Close
- exit 0
+ POL_SetupWindow_message "$(eval_gettext 'Steam have is own automatic update system.')" "$TITLE"
+ POL_SetupWindow_Close
+ exit 0
fi
-
+
# Using specific Wine
if [ "$TWEE" == "1" ]; then
- # Asking about patch local or not
- cd "$HOME"
- POL_SetupWindow_InstallMethod "DOWNLOAD,LOCAL"
- if [ "$INSTALL_METHOD" == "LOCAL" ]; then
- POL_SetupWindow_browse "$(eval_gettext 'Select patch to execute')" "$TITLE" ""
- POL_Wine start /unix "$APP_ANSWER"
- POL_Wine_WaitExit "$TITLE"
- else
- cd "$POL_USER_ROOT/tmp"
- POL_Wine start /unix "TheWitcherPatch.1.5.exe"
- POL_Wine_WaitExit "$TITLE"
- rm "TheWitcherPatch.1.5.exe"
- fi
+ # Asking about patch local or not
+ cd "$HOME"
+ POL_SetupWindow_InstallMethod "DOWNLOAD,LOCAL"
+ if [ "$INSTALL_METHOD" == "LOCAL" ]; then
+ POL_SetupWindow_browse "$(eval_gettext 'Select patch to execute')" "$TITLE" ""
+ POL_Wine start /unix "$APP_ANSWER"
+ POL_Wine_WaitExit "$TITLE"
+ else
+ cd "$POL_USER_ROOT/tmp"
+ POL_Wine start /unix "TheWitcherPatch.1.5.exe"
+ POL_Wine_WaitExit "$TITLE"
+ rm "TheWitcherPatch.1.5.exe"
+ fi
else
- # Asking about patch local or not
- cd "$HOME"
- POL_SetupWindow_InstallMethod "DOWNLOAD,LOCAL"
- if [ "$INSTALL_METHOD" == "LOCAL" ]; then
- POL_SetupWindow_browse "$(eval_gettext 'Select first patch (EE Upgrade) to execute')" "$TITLE" ""
- POL_Wine start /unix "$APP_ANSWER"
- POL_Wine_WaitExit "$TITLE"
- POL_SetupWindow_browse "$(eval_gettext 'Select second patch (1.5) to execute')" "$TITLE" ""
- POL_Wine start /unix "$APP_ANSWER"
- POL_Wine_WaitExit "$TITLE"
- else
- cd "$POL_USER_ROOT/tmp"
- if [ "$POL_LANG" == "fr" ]; then
- elif [ "$POL_LANG" == "de" ]; then
- elif [ "$POL_LANG" == "es" ]; then
- elif [ "$POL_LANG" == "it" ]; then
- elif [ "$POL_LANG" == "ru" ]; then
- elif [ "$POL_LANG" == "pl" ]; then
- elif [ "$POL_LANG" == "hu" ]; then
- elif [ "$POL_LANG" == "cs" ]; then
- else
- fi
- POL_SetupWindow_download "$(eval_gettext 'Wait while the patch 4 is downloading...\nThis operation can take time, depending of your connexion.')" "$TITLE" "$PATCH_URL"
- POL_SetupWindow_message "$(eval_gettext 'Donwload finished.\nPatches installation will begin')" "$TITLE"
- POL_Wine start /unix "TWEE_Upgrade.exe"
- POL_Wine_WaitExit "$TITLE"
- POL_Wine start /unix "TheWitcherPatch.1.5.exe"
- POL_Wine_WaitExit "$TITLE"
- rm "TWEE_*.exe"
- rm "TheWitcherPatch.1.5.exe"
- fi
-fi
-
+ # Asking about patch local or not
+ cd "$HOME"
+ POL_SetupWindow_InstallMethod "DOWNLOAD,LOCAL"
+ if [ "$INSTALL_METHOD" == "LOCAL" ]; then
+ POL_SetupWindow_browse "$(eval_gettext 'Select first patch (EE Upgrade) to execute')" "$TITLE" ""
+ POL_Wine start /unix "$APP_ANSWER"
+ POL_Wine_WaitExit "$TITLE"
+ POL_SetupWindow_browse "$(eval_gettext 'Select second patch (1.5) to execute')" "$TITLE" ""
+ POL_Wine start /unix "$APP_ANSWER"
+ POL_Wine_WaitExit "$TITLE"
+ else
+ cd "$POL_USER_ROOT/tmp"
+ if [ "$POL_LANG" == "fr" ]; then
+ elif [ "$POL_LANG" == "de" ]; then
+ elif [ "$POL_LANG" == "es" ]; then
+ elif [ "$POL_LANG" == "it" ]; then
+ elif [ "$POL_LANG" == "ru" ]; then
+ elif [ "$POL_LANG" == "pl" ]; then
+ elif [ "$POL_LANG" == "hu" ]; then
+ elif [ "$POL_LANG" == "cs" ]; then
+ else
+ fi
+ POL_SetupWindow_download "$(eval_gettext 'Wait while the patch 4 is downloading...\nThis operation can take time, depending of your connexion.')" "$TITLE" "$PATCH_URL"
+ POL_SetupWindow_message "$(eval_gettext 'Donwload finished.\nPatches installation will begin')" "$TITLE"
+ POL_Wine start /unix "TWEE_Upgrade.exe"
+ POL_Wine_WaitExit "$TITLE"
+ POL_Wine start /unix "TheWitcherPatch.1.5.exe"
+ POL_Wine_WaitExit "$TITLE"
+ rm "TWEE_*.exe"
+ rm "TheWitcherPatch.1.5.exe"
+ fi
+fi
+
POL_SetupWindow_Close
exit 0
\ No newline at end of file