fr

Changes for Blur

Revision by GNU_Raziel (31 August 2011 17:08:45)

@@ -1,7 +1,7 @@
 #!/bin/bash
 # Date : (2010-06-09 22-00)
 # Last revision : (2011-08-10 19:41)
-# Wine version used : 1.2, 1.3.15, 1.3.23
+# Wine version used : 1.2, 1.3.15, 1.3.23, 1.3.27
 # Distribution used to test : Debian Testing x64
 # Author : GNU_Raziel
 # Licence : Retail
@@ -12,13 +12,13 @@
 
 TITLE="Blur"
 PREFIX="BlurTheGame"
-WORKING_WINE_VERSION="1.3.23"
+WORKING_WINE_VERSION="1.3.27"
 GAME_VMS="256"
 
 # Starting the script
 rm "$POL_USER_ROOT/tmp/*.jpg"
 POL_GetSetupImages "http://files.playonlinux.com/resources/setups/blur/top.jpg" "http://files.playonlinux.com/resources/setups/blur/left.jpg" "$TITLE"
-POL_SetupWindow_InitWithImages
+POL_SetupWindow_Init
 
 # Starting debugging API
 POL_Debug_Init
@@ -29,6 +29,7 @@
 POL_Wine_SelectPrefix "$PREFIX"
 
 # Downloading wine if necessary and creating prefix
+POL_System_SetArch "auto"
 POL_Wine_PrefixCreate "$WORKING_WINE_VERSION"
 
 # Choose between DVD and Digital Download version
@@ -37,40 +38,43 @@
 # Installing mandatory dependencies
 if [ "$INSTALL_METHOD" == "STEAM" ]; then
 	POL_Call POL_Install_steam
-else
-	POL_Call POL_Install_vcrun2005
 fi
 POL_Call POL_Install_vcrun2008
 POL_Call POL_Install_dxfullsetup
 POL_Call POL_Install_physx
 
+# Mandatory pre-install fix for steam
+POL_Call POL_Install_steam_flags "42640"
+
+# Begin game installation
 if [ "$INSTALL_METHOD" == "DVD" ]; then
 	# Asking for CDROM and checking if it's correct one
 	POL_SetupWindow_message "$(eval_gettext 'Please insert game media into your disk drive\nif not already done.')" "$TITLE"
 	POL_SetupWindow_cdrom
 	POL_SetupWindow_check_cdrom "setup.exe"
 	POL_Wine start /unix "$CDROM/setup.exe"
-	POL_SetupWindow_message "$(eval_gettext 'Click on "Forward" ONLY when the game installation is finished\nor you will have to redo the installation.')" "$TITLE"
+	POL_Wine_WaitExit "$TITLE"
 elif [ "$INSTALL_METHOD" == "STEAM" ]; then
 	cd "$WINEPREFIX/drive_c/$PROGRAMFILES/Steam"
-	POL_Wine start /unix "Steam.exe" -applaunch 42640
-	POL_SetupWindow_message "$(eval_gettext 'Click on "Forward" ONLY when Steam game installation\nwill be finished or you will have to redo the installation.')" "$TITLE"
+	POL_Wine start /unix "steam.exe" steam://install/42640
+	PPOL_Wine_WaitExit "$TITLE"
 else
 	# Asking then installing DDV of the game
 	cd "$HOME"
 	POL_SetupWindow_browse "$(eval_gettext 'Please select the setup file to run:')" "$TITLE"
 	SETUP_EXE="$APP_ANSWER"
-	POL_SetupWindow_wait_next_signal "$(eval_gettext 'Installation in progress...')" "$TITLE"
 	POL_Wine start /unix "$SETUP_EXE"
-	POL_Wine_WaitExit
+	POL_Wine_WaitExit "$TITLE"
 fi
 
 # Asking about memory size of graphic card
 POL_SetupWindow_VMS $GAME_VMS
 
 ## Fix for this game
+# Set Graphic Card information keys for wine
+POL_Wine_SetVideoDriver
+
 # Sound problem fix - pulseaudio related
-POL_Wine_OverrideDLL "" "mmdevapi" # Only if wine < 1.3.25
 [ "$POL_OS" = "Linux" ] && Set_SoundDriver "alsa"
 [ "$POL_OS" = "Linux" ] && Set_SoundEmulDriver "Y"
 ## End Fix
@@ -87,12 +91,16 @@
 fi
 
 # Making shortcut
-POL_Shortcut "Blur.exe" "$TITLE" "$TITLE.png" ""
+if [ "$INSTALL_METHOD" == "STEAM" ]; then
+	POL_Shortcut "steam.exe" "$TITLE" "$TITLE.png" "steam://rungameid/42640"
+else
+	POL_Shortcut "Blur.exe" "$TITLE" "$TITLE.png" ""
+fi
 
+# Game protection warning
 if [ "$INSTALL_METHOD" == "DVD" ]; then
-	# Game protection warning
 	POL_SetupWindow_message "$(eval_gettext 'You must disable anti-piracy protections of this game\nif you want to play it with wine.')" "$TITLE"
 fi
 
 POL_SetupWindow_Close
-exit
\ No newline at end of file
+exit 0
\ No newline at end of file

Revision by GNU_Raziel (26 August 2011 15:11:44)

@@ -71,12 +71,12 @@
 ## Fix for this game
 # Sound problem fix - pulseaudio related
 POL_Wine_OverrideDLL "" "mmdevapi" # Only if wine < 1.3.25
-[ "$POL_OS" = "Linux" ] || Set_SoundDriver "alsa"
-[ "$POL_OS" = "Linux" ] || Set_SoundEmulDriver "Y"
+[ "$POL_OS" = "Linux" ] && Set_SoundDriver "alsa"
+[ "$POL_OS" = "Linux" ] && Set_SoundEmulDriver "Y"
 ## End Fix
 
 ## PlayOnMac Section
-[ "$POL_OS" = "Mac" ] || Set_Managed "Off"
+[ "$POL_OS" = "Mac" ] && Set_Managed "Off"
 ## End Section
 
 # Cleaning temp

Revision by GNU_Raziel (10 August 2011 19:45:19)

@@ -1,82 +1,41 @@
 #!/bin/bash
 # Date : (2010-06-09 22-00)
-# Last revision : (2011-27-07 21-00)
+# Last revision : (2011-08-10 19:41)
 # Wine version used : 1.2, 1.3.15, 1.3.23
 # Distribution used to test : Debian Testing x64
 # Author : GNU_Raziel
 # Licence : Retail
 # Only For : http://www.playonlinux.com
- 
+
 [ "$PLAYONLINUX" = "" ] && exit 0
 source "$PLAYONLINUX/lib/sources"
- 
+
 TITLE="Blur"
 PREFIX="BlurTheGame"
 WORKING_WINE_VERSION="1.3.23"
- 
-if [ "$POL_LANG" == "fr" ]; then
-LNG_CHOOSE_MEDIA="Quelle version possédez-vous?"
-LNG_DVD="Version DVD"
-LNG_STEAM="Version Steam Store"
-LNG_DDV="Version Digital Download"
-LNG_CHOOSE_DDV="Veuillez selectionner votre executable Digital Download de $TITLE"
-LNG_INSERT_MEDIA="Veuillez insérer le disque $TITLE dans votre lecteur\nsi ce n'est pas déja fait."
-LNG_WAIT_END="Appuyez sur \"Suivant\" UNIQUEMENT quand l'installation du\njeu sera terminée sous peine de devoir recommencer l'installation."
-LNG_WAIT_STEAM_END="Appuyez sur \"Suivant\" UNIQUEMENT quand l'installation du jeu Steam\nsera terminée sous peine de devoir recommencer l'installation."
-LNG_INSTALL_ON="Installation en cours..."
-LNG_GAME_VMS="Quelle est la quantité de mémoire (Mo) de votre carte graphique ?" 
-LNG_VMS_ERROR="Ce jeu ne fonctionnera correctement qu'avec une carte graphique ayant plus de 256Mo de mémoire."
-LNG_GAME_WARNING="Vous devez contourner les protections anti-piratage de ce jeu\npour qu'il fonctionne avec wine."
-LNG_SUCCES="$TITLE a été installé avec succès."
-else
-LNG_CHOOSE_MEDIA="Which version do you have?"
-LNG_DVD="DVD Version"
-LNG_STEAM="Steam Store Version"
-LNG_DDV="Digital Download Version"
-LNG_CHOOSE_DDV="Please select your $TITLE Digital Download executable"
-LNG_INSERT_MEDIA="Please insert $TITLE media into your disk drive\nif not already done."
-LNG_WAIT_END="Click on \"Forward\" ONLY when the game installation is finished\nor you will have to redo the installation."
-LNG_WAIT_STEAM_END="Click on \"Forward\" ONLY when Steam game installation\nwill be finished or you will have to redo the installation."
-LNG_INSTALL_ON="Installation in progress..."
-LNG_GAME_VMS="How much memory does your graphics board have?" 
-LNG_VMS_ERROR="This game will work correctly only with a graphic card with more than 256MB of memory."
-LNG_GAME_WARNING="You must disable anti-piracy protections of this game\nif you want to play it with wine."
-LNG_SUCCES="$TITLE has been installed successfully."
-fi
- 
+GAME_VMS="256"
+
 # Starting the script
 rm "$POL_USER_ROOT/tmp/*.jpg"
 POL_GetSetupImages "http://files.playonlinux.com/resources/setups/blur/top.jpg" "http://files.playonlinux.com/resources/setups/blur/left.jpg" "$TITLE"
 POL_SetupWindow_InitWithImages
 
+# Starting debugging API
+POL_Debug_Init
+
 POL_SetupWindow_presentation "$TITLE" "Activision" "http://www.blurgame.com/" "GNU_Raziel" "$PREFIX"
- 
-select_prefixe "$POL_USER_ROOT/wineprefix/$PREFIX/"
 
-# Downloading specific Wine
-if [ "$MACHTYPE" == "x86_64-pc-linux-gnu" ]; then
-	POL_Call POL_Install_wine64b
-else
-	POL_SetupWindow_install_wine "$WORKING_WINE_VERSION"
-fi
-Use_WineVersion "$WORKING_WINE_VERSION"
+# Setting prefix path
+POL_Wine_SelectPrefix "$PREFIX"
 
-# Creating prefix 
-POL_SetupWindow_prefixcreate
+# Downloading wine if necessary and creating prefix
+POL_Wine_PrefixCreate "$WORKING_WINE_VERSION"
 
 # Choose between DVD and Digital Download version
-POL_SetupWindow_menu "$LNG_CHOOSE_MEDIA" "$TITLE" "$LNG_DVD~$LNG_STEAM~$LNG_DDV" "~"
- 
-if [ "$APP_ANSWER" == "$LNG_DVD" ]; then
-	GAME_MEDIAVERSION="DVD"
-elif [ "$APP_ANSWER" == "$LNG_STEAM" ]; then
-	GAME_MEDIAVERSION="STEAM"
-else
-	GAME_MEDIAVERSION="DD"
-fi
+POL_SetupWindow_InstallMethod "DVD,STEAM,LOCAL"
 
 # Installing mandatory dependencies
-if [ "$GAME_MEDIAVERSION" == "STEAM" ]; then
+if [ "$INSTALL_METHOD" == "STEAM" ]; then
 	POL_Call POL_Install_steam
 else
 	POL_Call POL_Install_vcrun2005
@@ -85,52 +44,39 @@
 POL_Call POL_Install_dxfullsetup
 POL_Call POL_Install_physx
 
-if [ "$GAME_MEDIAVERSION" == "DVD" ]; then
+if [ "$INSTALL_METHOD" == "DVD" ]; then
 	# Asking for CDROM and checking if it's correct one
-	POL_SetupWindow_message "$LNG_INSERT_MEDIA" "$TITLE"
+	POL_SetupWindow_message "$(eval_gettext 'Please insert game media into your disk drive\nif not already done.')" "$TITLE"
 	POL_SetupWindow_cdrom
 	POL_SetupWindow_check_cdrom "setup.exe"
-	wine start /unix "$CDROM/setup.exe"
-	POL_SetupWindow_message "$LNG_WAIT_END" "$TITLE"
-elif [ "$GAME_MEDIAVERSION" == "STEAM" ]; then
+	POL_Wine start /unix "$CDROM/setup.exe"
+	POL_SetupWindow_message "$(eval_gettext 'Click on "Forward" ONLY when the game installation is finished\nor you will have to redo the installation.')" "$TITLE"
+elif [ "$INSTALL_METHOD" == "STEAM" ]; then
 	cd "$WINEPREFIX/drive_c/$PROGRAMFILES/Steam"
-	wine "Steam.exe" -applaunch 42640
-	POL_SetupWindow_message "$LNG_WAIT_STEAM_END" "$TITLE"
+	POL_Wine start /unix "Steam.exe" -applaunch 42640
+	POL_SetupWindow_message "$(eval_gettext 'Click on "Forward" ONLY when Steam game installation\nwill be finished or you will have to redo the installation.')" "$TITLE"
 else
 	# Asking then installing DDV of the game
 	cd "$HOME"
-	POL_SetupWindow_browse "$LNG_CHOOSE_DDV" "$TITLE"
+	POL_SetupWindow_browse "$(eval_gettext 'Please select the setup file to run:')" "$TITLE"
 	SETUP_EXE="$APP_ANSWER"
-	POL_SetupWindow_wait_next_signal "$LNG_INSTALL_ON" "$TITLE"
-	wine start /unix "$SETUP_EXE"
-	wineserver -w
-	POL_SetupWindow_detect_exit
+	POL_SetupWindow_wait_next_signal "$(eval_gettext 'Installation in progress...')" "$TITLE"
+	POL_Wine start /unix "$SETUP_EXE"
+	POL_Wine_WaitExit
 fi
 
 # Asking about memory size of graphic card
-POL_SetupWindow_menu_list "$LNG_GAME_VMS" "$TITLE" "64-128-256-320-384-512-640-768-896-1024-1536-1792-2048-3072-4096" "-" "256"
-VMS="$APP_ANSWER"
- 
-cd "$WINEPREFIX/drive_c/windows/temp/"
-cat << EOF > vms.reg
-[HKEY_CURRENT_USER\\Software\\Wine\\Direct3D]
-"VideoMemorySize"="$VMS"
-EOF
-regedit vms.reg
-if [ "$VMS" -lt "256" ]; then
-	POL_SetupWindow_message "$LNG_VMS_ERROR" "$TITLE"
-fi
- 
-## Fix for this game
-POL_Call POL_Function_OverrideDLL "" "mmdevapi"
+POL_SetupWindow_VMS $GAME_VMS
 
+## Fix for this game
 # Sound problem fix - pulseaudio related
-[ "$PLAYONMAC" == "" ] && Set_SoundDriver "alsa"
-[ "$PLAYONMAC" == "" ] && Set_SoundEmulDriver "Y"
+POL_Wine_OverrideDLL "" "mmdevapi" # Only if wine < 1.3.25
+[ "$POL_OS" = "Linux" ] || Set_SoundDriver "alsa"
+[ "$POL_OS" = "Linux" ] || Set_SoundEmulDriver "Y"
 ## End Fix
- 
+
 ## PlayOnMac Section
-[ "$PLAYONMAC" == "" ] || Set_Managed "Off"
+[ "$POL_OS" = "Mac" ] || Set_Managed "Off"
 ## End Section
 
 # Cleaning temp
@@ -141,13 +87,12 @@
 fi
 
 # Making shortcut
-POL_SetupWindow_auto_shortcut "$PREFIX" "Blur.exe" "$TITLE" "$TITLE.png" ""
-Set_WineVersion_Assign "$WORKING_WINE_VERSION" "$TITLE"
+POL_Shortcut "Blur.exe" "$TITLE" "$TITLE.png" ""
 
-# Game protection warning
-POL_SetupWindow_message "$LNG_GAME_WARNING" "$TITLE"
-
-POL_SetupWindow_message "$LNG_SUCCES" "$TITLE"
+if [ "$INSTALL_METHOD" == "DVD" ]; then
+	# Game protection warning
+	POL_SetupWindow_message "$(eval_gettext 'You must disable anti-piracy protections of this game\nif you want to play it with wine.')" "$TITLE"
+fi
 
 POL_SetupWindow_Close
 exit
\ No newline at end of file

Revision by GNU_Raziel (27 July 2011 21:24:13)

@@ -1,7 +1,7 @@
 #!/bin/bash
 # Date : (2010-06-09 22-00)
-# Last revision : (2011-18-03 21-00)
-# Wine version used : 1.2, 1.3.15
+# Last revision : (2011-27-07 21-00)
+# Wine version used : 1.2, 1.3.15, 1.3.23
 # Distribution used to test : Debian Testing x64
 # Author : GNU_Raziel
 # Licence : Retail
@@ -12,7 +12,7 @@
  
 TITLE="Blur"
 PREFIX="BlurTheGame"
-WORKING_WINE_VERSION="1.3.15"
+WORKING_WINE_VERSION="1.3.23"
  
 if [ "$POL_LANG" == "fr" ]; then
 LNG_CHOOSE_MEDIA="Quelle version possédez-vous?"
@@ -24,27 +24,27 @@
 LNG_WAIT_END="Appuyez sur \"Suivant\" UNIQUEMENT quand l'installation du\njeu sera terminée sous peine de devoir recommencer l'installation."
 LNG_WAIT_STEAM_END="Appuyez sur \"Suivant\" UNIQUEMENT quand l'installation du jeu Steam\nsera terminée sous peine de devoir recommencer l'installation."
 LNG_INSTALL_ON="Installation en cours..."
-LNG_GAME_VMS="Quelle est la quantité de mémoire (Mo) de votre carte graphique ?\n(minimum pour ce jeu : 256)" 
+LNG_GAME_VMS="Quelle est la quantité de mémoire (Mo) de votre carte graphique ?" 
 LNG_VMS_ERROR="Ce jeu ne fonctionnera correctement qu'avec une carte graphique ayant plus de 256Mo de mémoire."
 LNG_GAME_WARNING="Vous devez contourner les protections anti-piratage de ce jeu\npour qu'il fonctionne avec wine."
 LNG_SUCCES="$TITLE a été installé avec succès."
 else
-LNG_CHOOSE_MEDIA="What version do you have?"
+LNG_CHOOSE_MEDIA="Which version do you have?"
 LNG_DVD="DVD Version"
 LNG_STEAM="Steam Store Version"
 LNG_DDV="Digital Download Version"
 LNG_CHOOSE_DDV="Please select your $TITLE Digital Download executable"
 LNG_INSERT_MEDIA="Please insert $TITLE media into your disk drive\nif not already done."
-LNG_WAIT_END="Click on \"Next\" ONLY when the game installation is finished\nor you will have to redo the installation."
+LNG_WAIT_END="Click on \"Forward\" ONLY when the game installation is finished\nor you will have to redo the installation."
 LNG_WAIT_STEAM_END="Click on \"Forward\" ONLY when Steam game installation\nwill be finished or you will have to redo the installation."
 LNG_INSTALL_ON="Installation in progress..."
-LNG_GAME_VMS="How much memory does your graphics board have?\n(minimum for this game : 256)" 
-LNG_VMS_ERROR="This game will work correctly only with a graphic card with more than 256Mo of memory."
+LNG_GAME_VMS="How much memory does your graphics board have?" 
+LNG_VMS_ERROR="This game will work correctly only with a graphic card with more than 256MB of memory."
 LNG_GAME_WARNING="You must disable anti-piracy protections of this game\nif you want to play it with wine."
 LNG_SUCCES="$TITLE has been installed successfully."
 fi
  
-#starting the script
+# Starting the script
 rm "$POL_USER_ROOT/tmp/*.jpg"
 POL_GetSetupImages "http://files.playonlinux.com/resources/setups/blur/top.jpg" "http://files.playonlinux.com/resources/setups/blur/left.jpg" "$TITLE"
 POL_SetupWindow_InitWithImages
@@ -53,7 +53,7 @@
  
 select_prefixe "$POL_USER_ROOT/wineprefix/$PREFIX/"
 
-#downloading specific Wine
+# Downloading specific Wine
 if [ "$MACHTYPE" == "x86_64-pc-linux-gnu" ]; then
 	POL_Call POL_Install_wine64b
 else
@@ -61,11 +61,11 @@
 fi
 Use_WineVersion "$WORKING_WINE_VERSION"
 
-#Creating prefix 
+# Creating prefix 
 POL_SetupWindow_prefixcreate
 
-#Choose between DVD and Digital Download version
-POL_SetupWindow_menu "$LNG_CHOOSE_MEDIA" "Actions" "$LNG_DVD~$LNG_STEAM~$LNG_DDV" "~"
+# Choose between DVD and Digital Download version
+POL_SetupWindow_menu "$LNG_CHOOSE_MEDIA" "$TITLE" "$LNG_DVD~$LNG_STEAM~$LNG_DDV" "~"
  
 if [ "$APP_ANSWER" == "$LNG_DVD" ]; then
 	GAME_MEDIAVERSION="DVD"
@@ -75,7 +75,7 @@
 	GAME_MEDIAVERSION="DD"
 fi
 
-#Installing mandatory dependencies
+# Installing mandatory dependencies
 if [ "$GAME_MEDIAVERSION" == "STEAM" ]; then
 	POL_Call POL_Install_steam
 else
@@ -86,8 +86,8 @@
 POL_Call POL_Install_physx
 
 if [ "$GAME_MEDIAVERSION" == "DVD" ]; then
-	#asking for CDROM and checking if it's correct one
-	POL_SetupWindow_message "$LNG_INSERT_MEDIA"
+	# Asking for CDROM and checking if it's correct one
+	POL_SetupWindow_message "$LNG_INSERT_MEDIA" "$TITLE"
 	POL_SetupWindow_cdrom
 	POL_SetupWindow_check_cdrom "setup.exe"
 	wine start /unix "$CDROM/setup.exe"
@@ -97,22 +97,18 @@
 	wine "Steam.exe" -applaunch 42640
 	POL_SetupWindow_message "$LNG_WAIT_STEAM_END" "$TITLE"
 else
-	#Asking then installing DDV of the game
+	# Asking then installing DDV of the game
 	cd "$HOME"
 	POL_SetupWindow_browse "$LNG_CHOOSE_DDV" "$TITLE"
 	SETUP_EXE="$APP_ANSWER"
 	POL_SetupWindow_wait_next_signal "$LNG_INSTALL_ON" "$TITLE"
 	wine start /unix "$SETUP_EXE"
-	INSTALL_ON="1"
-	until [ "$INSTALL_ON" == "" ]; do
-	sleep 5
-	INSTALL_ON=`ps aux | grep "wineserver" | grep -v "grep"`
-	done
+	wineserver -w
 	POL_SetupWindow_detect_exit
 fi
 
-#asking about memory size of graphic card
-POL_SetupWindow_menu_list "$LNG_GAME_VMS" "$TITLE" "128-256-320-384-512-640-768-896-1024-1792-2048" "-" "256"
+# Asking about memory size of graphic card
+POL_SetupWindow_menu_list "$LNG_GAME_VMS" "$TITLE" "64-128-256-320-384-512-640-768-896-1024-1536-1792-2048-3072-4096" "-" "256"
 VMS="$APP_ANSWER"
  
 cd "$WINEPREFIX/drive_c/windows/temp/"
@@ -125,23 +121,30 @@
 	POL_SetupWindow_message "$LNG_VMS_ERROR" "$TITLE"
 fi
  
+## Fix for this game
+POL_Call POL_Function_OverrideDLL "" "mmdevapi"
+
+# Sound problem fix - pulseaudio related
+[ "$PLAYONMAC" == "" ] && Set_SoundDriver "alsa"
+[ "$PLAYONMAC" == "" ] && Set_SoundEmulDriver "Y"
+## End Fix
+ 
 ## PlayOnMac Section
-[ "$PLAYONMAC" == "" ] && Set_Managed "On"
 [ "$PLAYONMAC" == "" ] || Set_Managed "Off"
 ## End Section
-Set_DXGrab "On"
- 
-#cleaning temp
+
+# Cleaning temp
 if [ -e "$WINEPREFIX/drive_c/windows/temp/" ]; then
 	rm -rf "$WINEPREFIX/drive_c/windows/temp/*"
 	chmod -R 777 "$POL_USER_ROOT/tmp/"
 	rm -rf "$POL_USER_ROOT/tmp/*"
 fi
 
+# Making shortcut
 POL_SetupWindow_auto_shortcut "$PREFIX" "Blur.exe" "$TITLE" "$TITLE.png" ""
 Set_WineVersion_Assign "$WORKING_WINE_VERSION" "$TITLE"
 
-#Game protection warning
+# Game protection warning
 POL_SetupWindow_message "$LNG_GAME_WARNING" "$TITLE"
 
 POL_SetupWindow_message "$LNG_SUCCES" "$TITLE"

Revision by GNU_Raziel (18 July 2011 17:29:42)

@@ -36,7 +36,7 @@
 LNG_CHOOSE_DDV="Please select your $TITLE Digital Download executable"
 LNG_INSERT_MEDIA="Please insert $TITLE media into your disk drive\nif not already done."
 LNG_WAIT_END="Click on \"Next\" ONLY when the game installation is finished\nor you will have to redo the installation."
-LNG_WAIT_STEAM_END="Click on \"Forward\" ONLY when Steam game installation\swill be finished or you will have to redo the installation."
+LNG_WAIT_STEAM_END="Click on \"Forward\" ONLY when Steam game installation\nwill be finished or you will have to redo the installation."
 LNG_INSTALL_ON="Installation in progress..."
 LNG_GAME_VMS="How much memory does your graphics board have?\n(minimum for this game : 256)" 
 LNG_VMS_ERROR="This game will work correctly only with a graphic card with more than 256Mo of memory."

Revision by GNU_Raziel (18 March 2011 21:06:59)

@@ -1,68 +1,88 @@
 #!/bin/bash
 # Date : (2010-06-09 22-00)
-# Last revision : (2010-06-09 22-00)
-# Wine version used : 1.2
-# Distribution used to test : Debian Squeeze (Testing)
+# Last revision : (2011-18-03 21-00)
+# Wine version used : 1.2, 1.3.15
+# Distribution used to test : Debian Testing x64
 # Author : GNU_Raziel
 # Licence : Retail
+# Only For : http://www.playonlinux.com
  
 [ "$PLAYONLINUX" = "" ] && exit 0
 source "$PLAYONLINUX/lib/sources"
  
 TITLE="Blur"
 PREFIX="BlurTheGame"
+WORKING_WINE_VERSION="1.3.15"
  
 if [ "$POL_LANG" == "fr" ]; then
 LNG_CHOOSE_MEDIA="Quelle version possédez-vous?"
 LNG_DVD="Version DVD"
+LNG_STEAM="Version Steam Store"
 LNG_DDV="Version Digital Download"
 LNG_CHOOSE_DDV="Veuillez selectionner votre executable Digital Download de $TITLE"
 LNG_INSERT_MEDIA="Veuillez insérer le disque $TITLE dans votre lecteur\nsi ce n'est pas déja fait."
 LNG_WAIT_END="Appuyez sur \"Suivant\" UNIQUEMENT quand l'installation du\njeu sera terminée sous peine de devoir recommencer l'installation."
+LNG_WAIT_STEAM_END="Appuyez sur \"Suivant\" UNIQUEMENT quand l'installation du jeu Steam\nsera terminée sous peine de devoir recommencer l'installation."
 LNG_INSTALL_ON="Installation en cours..."
 LNG_GAME_VMS="Quelle est la quantité de mémoire (Mo) de votre carte graphique ?\n(minimum pour ce jeu : 256)" 
 LNG_VMS_ERROR="Ce jeu ne fonctionnera correctement qu'avec une carte graphique ayant plus de 256Mo de mémoire."
+LNG_GAME_WARNING="Vous devez contourner les protections anti-piratage de ce jeu\npour qu'il fonctionne avec wine."
 LNG_SUCCES="$TITLE a été installé avec succès."
 else
 LNG_CHOOSE_MEDIA="What version do you have?"
 LNG_DVD="DVD Version"
+LNG_STEAM="Steam Store Version"
 LNG_DDV="Digital Download Version"
 LNG_CHOOSE_DDV="Please select your $TITLE Digital Download executable"
 LNG_INSERT_MEDIA="Please insert $TITLE media into your disk drive\nif not already done."
 LNG_WAIT_END="Click on \"Next\" ONLY when the game installation is finished\nor you will have to redo the installation."
+LNG_WAIT_STEAM_END="Click on \"Forward\" ONLY when Steam game installation\swill be finished or you will have to redo the installation."
 LNG_INSTALL_ON="Installation in progress..."
 LNG_GAME_VMS="How much memory does your graphics board have?\n(minimum for this game : 256)" 
 LNG_VMS_ERROR="This game will work correctly only with a graphic card with more than 256Mo of memory."
+LNG_GAME_WARNING="You must disable anti-piracy protections of this game\nif you want to play it with wine."
 LNG_SUCCES="$TITLE has been installed successfully."
 fi
  
-cd $REPERTOIRE/tmp
-rm *.jpg
+#starting the script
+rm "$POL_USER_ROOT/tmp/*.jpg"
 POL_GetSetupImages "http://files.playonlinux.com/resources/setups/blur/top.jpg" "http://files.playonlinux.com/resources/setups/blur/left.jpg" "$TITLE"
-
 POL_SetupWindow_InitWithImages
 
 POL_SetupWindow_presentation "$TITLE" "Activision" "http://www.blurgame.com/" "GNU_Raziel" "$PREFIX"
  
-select_prefixe "$REPERTOIRE/wineprefix/$PREFIX/"
+select_prefixe "$POL_USER_ROOT/wineprefix/$PREFIX/"
+
+#downloading specific Wine
+if [ "$MACHTYPE" == "x86_64-pc-linux-gnu" ]; then
+	POL_Call POL_Install_wine64b
+else
+	POL_SetupWindow_install_wine "$WORKING_WINE_VERSION"
+fi
+Use_WineVersion "$WORKING_WINE_VERSION"
+
+#Creating prefix 
+POL_SetupWindow_prefixcreate
 
 #Choose between DVD and Digital Download version
-POL_SetupWindow_menu "$LNG_CHOOSE_MEDIA" "Actions" "$LNG_DVD~$LNG_DDV" "~"
+POL_SetupWindow_menu "$LNG_CHOOSE_MEDIA" "Actions" "$LNG_DVD~$LNG_STEAM~$LNG_DDV" "~"
  
 if [ "$APP_ANSWER" == "$LNG_DVD" ]; then
-	GAME_MEDIAVERSION="DVD"	
+	GAME_MEDIAVERSION="DVD"
+elif [ "$APP_ANSWER" == "$LNG_STEAM" ]; then
+	GAME_MEDIAVERSION="STEAM"
 else
 	GAME_MEDIAVERSION="DD"
 fi
- 
-#fetching PROGRAMFILES environmental variable
-PROGRAMFILES="Program Files" 
-POL_LoadVar_PROGRAMFILES
 
-#Installing mandatory components
+#Installing mandatory dependencies
+if [ "$GAME_MEDIAVERSION" == "STEAM" ]; then
+	POL_Call POL_Install_steam
+else
+	POL_Call POL_Install_vcrun2005
+fi
 POL_Call POL_Install_vcrun2008
-POL_Call POL_Install_d3dx9
-POL_Call POL_Install_xact
+POL_Call POL_Install_dxfullsetup
 POL_Call POL_Install_physx
 
 if [ "$GAME_MEDIAVERSION" == "DVD" ]; then
@@ -72,9 +92,13 @@
 	POL_SetupWindow_check_cdrom "setup.exe"
 	wine start /unix "$CDROM/setup.exe"
 	POL_SetupWindow_message "$LNG_WAIT_END" "$TITLE"
+elif [ "$GAME_MEDIAVERSION" == "STEAM" ]; then
+	cd "$WINEPREFIX/drive_c/$PROGRAMFILES/Steam"
+	wine "Steam.exe" -applaunch 42640
+	POL_SetupWindow_message "$LNG_WAIT_STEAM_END" "$TITLE"
 else
 	#Asking then installing DDV of the game
-	cd $HOME
+	cd "$HOME"
 	POL_SetupWindow_browse "$LNG_CHOOSE_DDV" "$TITLE"
 	SETUP_EXE="$APP_ANSWER"
 	POL_SetupWindow_wait_next_signal "$LNG_INSTALL_ON" "$TITLE"
@@ -92,8 +116,10 @@
 VMS="$APP_ANSWER"
  
 cd "$WINEPREFIX/drive_c/windows/temp/"
-echo "[HKEY_CURRENT_USER\\Software\\Wine\\Direct3D]" > vms.reg
-echo "\"VideoMemorySize\"=\"$VMS\"" >> vms.reg
+cat << EOF > vms.reg
+[HKEY_CURRENT_USER\\Software\\Wine\\Direct3D]
+"VideoMemorySize"="$VMS"
+EOF
 regedit vms.reg
 if [ "$VMS" -lt "256" ]; then
 	POL_SetupWindow_message "$LNG_VMS_ERROR" "$TITLE"
@@ -108,11 +134,15 @@
 #cleaning temp
 if [ -e "$WINEPREFIX/drive_c/windows/temp/" ]; then
 	rm -rf "$WINEPREFIX/drive_c/windows/temp/*"
-	chmod -R 777 "$REPERTOIRE/tmp/"
-	rm -rf "$REPERTOIRE/tmp/*"
+	chmod -R 777 "$POL_USER_ROOT/tmp/"
+	rm -rf "$POL_USER_ROOT/tmp/*"
 fi
 
-POL_SetupWindow_auto_shortcut "$PREFIX" "Blur.exe" "$TITLE" "$TITLE.png" 
+POL_SetupWindow_auto_shortcut "$PREFIX" "Blur.exe" "$TITLE" "$TITLE.png" ""
+Set_WineVersion_Assign "$WORKING_WINE_VERSION" "$TITLE"
+
+#Game protection warning
+POL_SetupWindow_message "$LNG_GAME_WARNING" "$TITLE"
 
 POL_SetupWindow_message "$LNG_SUCCES" "$TITLE"
 

Revision by GNU_Raziel (14 September 2010 18:22:58)

@@ -18,6 +18,7 @@
 LNG_DDV="Version Digital Download"
 LNG_CHOOSE_DDV="Veuillez selectionner votre executable Digital Download de $TITLE"
 LNG_INSERT_MEDIA="Veuillez insérer le disque $TITLE dans votre lecteur\nsi ce n'est pas déja fait."
+LNG_WAIT_END="Appuyez sur \"Suivant\" UNIQUEMENT quand l'installation du\njeu sera terminée sous peine de devoir recommencer l'installation."
 LNG_INSTALL_ON="Installation en cours..."
 LNG_GAME_VMS="Quelle est la quantité de mémoire (Mo) de votre carte graphique ?\n(minimum pour ce jeu : 256)" 
 LNG_VMS_ERROR="Ce jeu ne fonctionnera correctement qu'avec une carte graphique ayant plus de 256Mo de mémoire."
@@ -28,6 +29,7 @@
 LNG_DDV="Digital Download Version"
 LNG_CHOOSE_DDV="Please select your $TITLE Digital Download executable"
 LNG_INSERT_MEDIA="Please insert $TITLE media into your disk drive\nif not already done."
+LNG_WAIT_END="Click on \"Next\" ONLY when the game installation is finished\nor you will have to redo the installation."
 LNG_INSTALL_ON="Installation in progress..."
 LNG_GAME_VMS="How much memory does your graphics board have?\n(minimum for this game : 256)" 
 LNG_VMS_ERROR="This game will work correctly only with a graphic card with more than 256Mo of memory."
@@ -68,14 +70,8 @@
 	POL_SetupWindow_message "$LNG_INSERT_MEDIA"
 	POL_SetupWindow_cdrom
 	POL_SetupWindow_check_cdrom "setup.exe"
-	POL_SetupWindow_wait_next_signal "$LNG_INSTALL_ON" "$TITLE"
 	wine start /unix "$CDROM/setup.exe"
-	INSTALL_ON="1"
-	until [ "$INSTALL_ON" == "" ]; do
-	sleep 5
-	INSTALL_ON=`ps aux | grep "wineserver" | grep -v "grep"`
-	done
-	POL_SetupWindow_detect_exit
+	POL_SetupWindow_message "$LNG_WAIT_END" "$TITLE"
 else
 	#Asking then installing DDV of the game
 	cd $HOME

Revision by GNU_Raziel (07 September 2010 14:30:14)

No change were made in the code

Revision by GNU_Raziel (06 September 2010 21:35:36)

@@ -0,0 +1,124 @@
+#!/bin/bash
+# Date : (2010-06-09 22-00)
+# Last revision : (2010-06-09 22-00)
+# Wine version used : 1.2
+# Distribution used to test : Debian Squeeze (Testing)
+# Author : GNU_Raziel
+# Licence : Retail
+ 
+[ "$PLAYONLINUX" = "" ] && exit 0
+source "$PLAYONLINUX/lib/sources"
+ 
+TITLE="Blur"
+PREFIX="BlurTheGame"
+ 
+if [ "$POL_LANG" == "fr" ]; then
+LNG_CHOOSE_MEDIA="Quelle version possédez-vous?"
+LNG_DVD="Version DVD"
+LNG_DDV="Version Digital Download"
+LNG_CHOOSE_DDV="Veuillez selectionner votre executable Digital Download de $TITLE"
+LNG_INSERT_MEDIA="Veuillez insérer le disque $TITLE dans votre lecteur\nsi ce n'est pas déja fait."
+LNG_INSTALL_ON="Installation en cours..."
+LNG_GAME_VMS="Quelle est la quantité de mémoire (Mo) de votre carte graphique ?\n(minimum pour ce jeu : 256)" 
+LNG_VMS_ERROR="Ce jeu ne fonctionnera correctement qu'avec une carte graphique ayant plus de 256Mo de mémoire."
+LNG_SUCCES="$TITLE a été installé avec succès."
+else
+LNG_CHOOSE_MEDIA="What version do you have?"
+LNG_DVD="DVD Version"
+LNG_DDV="Digital Download Version"
+LNG_CHOOSE_DDV="Please select your $TITLE Digital Download executable"
+LNG_INSERT_MEDIA="Please insert $TITLE media into your disk drive\nif not already done."
+LNG_INSTALL_ON="Installation in progress..."
+LNG_GAME_VMS="How much memory does your graphics board have?\n(minimum for this game : 256)" 
+LNG_VMS_ERROR="This game will work correctly only with a graphic card with more than 256Mo of memory."
+LNG_SUCCES="$TITLE has been installed successfully."
+fi
+ 
+cd $REPERTOIRE/tmp
+rm *.jpg
+POL_GetSetupImages "http://files.playonlinux.com/resources/setups/blur/top.jpg" "http://files.playonlinux.com/resources/setups/blur/left.jpg" "$TITLE"
+[ "$PLAYONMAC" == "" ] || POL_SetupWindow_Init
+[ "$PLAYONMAC" == "" ] && POL_SetupWindow_InitWithImages
+
+POL_SetupWindow_presentation "$TITLE" "Activision" "http://www.blurgame.com/" "GNU_Raziel" "$PREFIX"
+ 
+select_prefixe "$REPERTOIRE/wineprefix/$PREFIX/"
+
+#Choose between DVD and Digital Download version
+POL_SetupWindow_menu "$LNG_CHOOSE_MEDIA" "Actions" "$LNG_DVD~$LNG_DDV" "~"
+ 
+if [ "$APP_ANSWER" == "$LNG_DVD" ]; then
+	GAME_MEDIAVERSION="DVD"	
+else
+	GAME_MEDIAVERSION="DD"
+fi
+ 
+#fetching PROGRAMFILES environmental variable
+PROGRAMFILES="Program Files" 
+POL_LoadVar_PROGRAMFILES
+
+#Installing mandatory components
+POL_Call POL_Install_vcrun2008
+POL_Call POL_Install_d3dx9
+POL_Call POL_Install_xact
+POL_Call POL_Install_physx
+
+if [ "$GAME_MEDIAVERSION" == "DVD" ]; then
+	#asking for CDROM and checking if it's correct one
+	POL_SetupWindow_message "$LNG_INSERT_MEDIA"
+	POL_SetupWindow_cdrom
+	POL_SetupWindow_check_cdrom "setup.exe"
+	POL_SetupWindow_wait_next_signal "$LNG_INSTALL_ON" "$TITLE"
+	wine start /unix "$CDROM/setup.exe"
+	INSTALL_ON="1"
+	until [ "$INSTALL_ON" == "" ]; do
+	sleep 5
+	INSTALL_ON=`ps aux | grep "wineserver" | grep -v "grep"`
+	done
+	POL_SetupWindow_detect_exit
+else
+	#Asking then installing DDV of the game
+	cd $HOME
+	POL_SetupWindow_browse "$LNG_CHOOSE_DDV" "$TITLE"
+	SETUP_EXE="$APP_ANSWER"
+	POL_SetupWindow_wait_next_signal "$LNG_INSTALL_ON" "$TITLE"
+	wine start /unix "$SETUP_EXE"
+	INSTALL_ON="1"
+	until [ "$INSTALL_ON" == "" ]; do
+	sleep 5
+	INSTALL_ON=`ps aux | grep "wineserver" | grep -v "grep"`
+	done
+	POL_SetupWindow_detect_exit
+fi
+
+#asking about memory size of graphic card
+POL_SetupWindow_menu_list "$LNG_GAME_VMS" "$TITLE" "128-256-320-384-512-640-768-896-1024-1792-2048" "-" "256"
+VMS="$APP_ANSWER"
+ 
+cd "$WINEPREFIX/drive_c/windows/temp/"
+echo "[HKEY_CURRENT_USER\\Software\\Wine\\Direct3D]" > vms.reg
+echo "\"VideoMemorySize\"=\"$VMS\"" >> vms.reg
+regedit vms.reg
+if [ "$VMS" -lt "256" ]; then
+	POL_SetupWindow_message "$LNG_VMS_ERROR" "$TITLE"
+fi
+ 
+## PlayOnMac Section
+[ "$PLAYONMAC" == "" ] && Set_Managed "On"
+[ "$PLAYONMAC" == "" ] || Set_Managed "Off"
+## End Section
+Set_DXGrab "On"
+ 
+#cleaning temp
+if [ -e "$WINEPREFIX/drive_c/windows/temp/" ]; then
+	rm -rf "$WINEPREFIX/drive_c/windows/temp/*"
+	chmod -R 777 "$REPERTOIRE/tmp/"
+	rm -rf "$REPERTOIRE/tmp/*"
+fi
+
+POL_SetupWindow_auto_shortcut "$PREFIX" "Blur.exe" "$TITLE.png" "$TITLE" ""
+
+POL_SetupWindow_message "$LNG_SUCCES" "$TITLE"
+
+POL_SetupWindow_Close
+exit
\ No newline at end of file
Il n'y a rien à voir ici