El Foro

Colin Mcrae Rally 2005

Autor Respuestas
Jump to the page: 1 - 2
thib25 Sunday 4 October 2009 at 16:58
thib25Anonymous

Bonjour, je vous présente mon script pour installer Colin Mcrae Rally 2005 (si vous ne l'aviez pas deviné :D).
Alors il fonctionne correctement avec Wine 1.1.30 sous Ubuntu 9.04 avec une carte graphique ATi.

Voici quelques images :







Et voici le script :
[#!/bin/bash
# Date : (2009-08-23 13-00)
# Last revision : (2009-10-04 15-15)
# Wine version used : 1.1.30
# Distribution used to test : Ubuntu 9.04
# Author : thib25
# Licence : Retail
 
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"

NAME="Colin Mcrae Rally 2005"
PREFIX="CMR2005"
URL="ftp://10a0fa3baed3326cb49264550be4768b:1251047489@ftpclubic22.clubic.com/patch/colin_mcrae_rally_2005_patch_v1.1_multi-langues_13070.exe"

if [ "$POL_LANG" == "fr" ]; then
INSTALLATION="Installation en cours..."
else
INSTALLATION="Installation in progress..."
fi

wget http://bookinalex.b.o.pic.centerblog.net/tced3etm.jpg --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 "$NAME" "Codemasters" "www.codemasters.com" "thib25" "$PREFIX"

POL_SetupWindow_cdrom
POL_SetupWindow_check_cdrom "setup.exe"

select_prefixe "$REPERTOIRE/wineprefix/$PREFIX/"
POL_SetupWindow_prefixcreate

POL_SetupWindow_wait_next_signal "$INSTALLATION" "$NAME"
cd "$CDROM"
wine "setup.exe"
POL_SetupWindow_detect_exit

POL_SetupWindow_make_shortcut "$PREFIX" "Program Files/Codemasters/Colin McRae Rally 2005" "cmr5.exe" "" "$NAME"

POL_SetupWindow_Close
exit


Les critiques sont les bienvenues ;-). Sinon je vais voir pour corriger quelques uns de mes scripts qui sont déjà validés et en créer d'autres pour des jeux comme GTR Evolution, Race The WTCC Game, RFactor.

Editado por: thib25

Berillions Sunday 4 October 2009 at 17:35
Berillions

Change le type d'affichage pour ton script.
Au lieu de prendre le code console, prend plutôt le code "PlayOnLinux", pour que ce soit plus clair.

1) Tu as crée un argument URL pour la patch 1.1 du jeu mais tu ne l'utilises pas.
Pour coder la demande d'installation d'un patch, tu peux regarder sur un de mes script.
Ici : http://www.playonlinux.com/repository/?script=471

2) Pour lancer l'executable d'installation, tu peux remplacer
cd "$CDROM"
wine "setup.exe" 
par
wine "$CDROM/setup.exe" 

3) Rajoute cette partie du code en haut de ton script :
PROGRAMFILES=`wine cmd /c echo "%ProgramFiles%"`
PROGRAMFILES=${PROGRAMFILES:3}  
Grâce à cela, remplace :
POL_SetupWindow_make_shortcut "$PREFIX" "Program Files/Codemasters/Colin McRae Rally 2005" "cmr5.exe" "" "$NAME" 
par :
POL_SetupWindow_make_shortcut "$PREFIX" "$PROGRAMFILES/Codemasters/Colin McRae Rally 2005" "cmr5.exe" "" "$NAME" 



4) Pour pouvoir jouer à ce jeu, faut-il un crack no-cd?
Si c'est le cas, rajoute ceci à la fin de ton script :

POL_SetupWindow_message_image "Please note that this game has a copy protection system\\nand sadly, it prevents Wine from running the game.\\n\\nPlayOnLinux will not provide any help concerning any illegal\\nstuff." "Note about copy protection" "$PLAYONLINUX/themes/tango/warning.png"

thib25 Sunday 4 October 2009 at 17:56
thib25Anonymous

Merci de m'avoir répondu. Alors pour l'URL de l'update que j'avais fais quelque chose pour l'installer était HS alors j'ai préféré le supprimer. Sinon je vais voir pour appliquer tes modifications. Par contre pour moi il n'y a pas besoin de CD j'ai une version "MINDSCAPE" acheté récemment à 5 euros en neuf avec le nouveau logo Codemasters après pour les autres je sais pas du tout :incertain:.
Berillions Sunday 4 October 2009 at 18:01
Berillions

Qu'est-ce qu'une version Mindscape? :x

thib25 Sunday 4 October 2009 at 18:09
thib25Anonymous

C'est ça http://www.mindscape.com/Products/ProductInfo.aspx?pid=3535. En fait c'est une version avec un autorun qui a été modifié pour lancer un programme qui demande d'enregistrer le logiciel chez eux mais bon on peut lancer le setup normal ce que j'ai fais dans ce script. Alors après je sais pas si le jeu a été modifié pour ne pas avoir besoin du cd :incertain:.

EDIT : Sinon voici mon nouveau script :

#!/bin/bash
# Date : (2009-08-23 13-00)
# Last revision : (2009-10-04 15-15)
# Wine version used : 1.1.30
# Distribution used to test : Ubuntu 9.04
# Author : thib25
# Licence : Retail
 
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"

PROGRAMFILES=`wine cmd /c echo "%ProgramFiles%"`
PROGRAMFILES=${PROGRAMFILES:3}
NAME="Colin Mcrae Rally 2005"
PREFIX="CMR2005"
URL="ftp://downloads.codemasters.com/patch/colin_mcrae%20rally_2005%20patch_installer.exe"

if [ "$POL_LANG" == "fr" ]; then
INSTALLATION="Installation en cours..."
INSTALLATIONPATCH="Installation de la mise à jour en cours..."
DTPATCH="Installer la mise à jour ?"
DPATCH="Voulez-vous installer la mise à jour pour $TITLE ?"
DOWNLOADT="Téléchargement de la mise à jour"
DOWNLOAD="Téléchargement de la mise à jours en cours..."
PATCHE="La mise à jour à été installée avec succès"
else
INSTALLATION="Installation in progress..."
INSTALLATIONPATCH="Installation of the update in progress..."
DTPATCH="Install the update ?"
DPATCH="Do you want to install the update for $TITLE ?"
PATCHE="The update has been installed successfully"
DOWNLOADT="Download of the update"
DOWNLOAD="Download of the update in progress..."
fi

wget http://bookinalex.b.o.pic.centerblog.net/tced3etm.jpg --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 "$NAME" "Codemasters" "www.codemasters.com" "thib25" "$PREFIX"

POL_SetupWindow_cdrom
POL_SetupWindow_check_cdrom "setup.exe"

select_prefixe "$REPERTOIRE/wineprefix/$PREFIX/"
POL_SetupWindow_prefixcreate

POL_SetupWindow_wait_next_signal "$INSTALLATION" "$NAME"
wine "$CDROM/setup.exe"
POL_SetupWindow_detect_exit

POL_SetupWindow_question "$DPATCH" "$DTPATCH" 
CHOICE=$APP_ANSWER

if [ "$APP_ANSWER" == "FALSE" ] ;then
cd "$REPERTOIRE/Temp"
POL_SetupWindow_download "$DOWNLOADT" "$DOWNLOAD" "$URL"
POL_SetupWindow_wait_next_signal "$INSTALLATIONPATCH" "$NAME"
wine "colin_mcrae rally_2005 patch_installer.exe"
POL_SetupWindow_detect_exit
fi

POL_SetupWindow_make_shortcut "$PREFIX" "$PROGRAMFILES/Codemasters/Colin McRae Rally 2005" "cmr5.exe" "" "$NAME"

POL_SetupWindow_Close
exit

Je ne l'ai pas encore testé mais a ne va pas tarder

Editado por: thib25

Berillions Sunday 4 October 2009 at 18:52
Berillions

Petite faute dans ton script.

En effet, tu demandes à l'utilisateur s'il veut installer la mise à jour mais le problème, tu télécharges la mise à jour puis tu l'installes si l'utilisateur répond "NON" à la question.

Remplace
if [ "$APP_ANSWER" == "FALSE" ] ;then
par
if [ "$APP_ANSWER" == "TRUE" ] ;then

Editado por: Berillions


thib25 Sunday 4 October 2009 at 18:59
thib25Anonymous

Oups !!! Grosse étourderie.
Berillions Sunday 4 October 2009 at 19:03
Berillions

1) Autre chose,
Tu écris ;
POL_SetupWindow_question "$DPATCH" "$DTPATCH" 
Pourquoi avoir mis $DTPATCH vu que c'est la même question que $DPATCH.
Mets voir plutôt :
POL_SetupWindow_question "$DPATCH" "$NAME" 

2)Il y a également une faute dans $DPATCH. Tu mets :
DPATCH="Voulez-vous installer la mise à jour pour $TITLE ?"
Or, TITLE n'existe pas dans tes décalaration. C'est plutôt :
DPATCH="Voulez-vous installer la mise à jour pour $NAME ?"

3)Pas besoin de mettre CHOICE=$APP_ANSWER. Vu qu'ensuite tu fais un :
if [ "$APP_ANSWER" == "TRUE" ] ;then

4)Faute également içi :
cd "$REPERTOIRE/Temp"
Le dossier "$REPERTOIRE/Temp" n'existe pas, c'est plutôt "$REPERTOIRE/tmp"

5)Même chose que pour DTPATCH,
POL_SetupWindow_download "$DOWNLOAD" "$NAME" "$URL"
au lieu de
POL_SetupWindow_download "$DOWNLOADT" "$DOWNLOAD" "$URL"

6)J'ai également rajouté un
rm -rf NomDuPatch
pour ne pas s'emcombrer de fichier dont on a plus l'utilité.

Donc voici une version corrigée :
POL_SetupWindow_question "$DPATCH" "$NAME" 
 
if [ "$APP_ANSWER" == "TRUE" ] ;then
cd "$REPERTOIRE/tmp"
POL_SetupWindow_download "$DOWNLOAD" "$NAME" "$URL"
POL_SetupWindow_wait_next_signal "$INSTALLATIONPATCH" "$NAME"
wine "./colin_mcrae rally_2005 patch_installer.exe"
POL_SetupWindow_detect_exit
rm -f "./colin_mcrae rally_2005 patch_installer.exe"
fi

Editado por: Berillions


cendre Sunday 4 October 2009 at 20:57
cendre

Bon je vais vous le dire une fois pour toute parce que entre NSLW et toi, ca a l'air d'etre une mode ^^".

PROGRAMFILES=`wine cmd /c echo "%ProgramFiles%"`
PROGRAMFILES=${PROGRAMFILES:3}

Ca sert strictement a rien de mettre, on a eu dans le passe ce genre de probleme et maintenant (depuis un moment meme) playonlinux force le nom de program files lors de la creation du prefixe, donc on ne peut plus trouver des noms differents maintenant :) .
Berillions Sunday 4 October 2009 at 21:07
Berillions

Bah euh, c'est tout même NSLW qui m'a demandé de les rajouter dans mes 1er scripts.... :p

Donc, dans la création du shortcut dans son script, il suffit de mettre :
POL_SetupWindow_make_shortcut "$PREFIX" "Program Files/Codemasters/Colin McRae Rally 2005" "cmr5.exe" "" "$NAME"

Si c'est le cas, je saurais pour la prochaine fois... :p

cendre Sunday 4 October 2009 at 21:40
cendre

Bah il a cru bien faire et ignorais qu'on avais deja eu a faire au probleme dans le passe :)

Ouais, c'est pas la peine de t'embêter a gerer ca :) .
Berillions Sunday 4 October 2009 at 22:35
Berillions

ok. C'est noté pour mes prochains scripts. :)

thib25 Monday 5 October 2009 at 13:02
thib25Anonymous

Alors voilà la version corrigée :

#!/bin/bash
# Date : (2009-08-23 13-00)
# Last revision : (2009-10-04 15-15)
# Wine version used : 1.1.30
# Distribution used to test : Ubuntu 9.04
# Author : thib25
# Licence : Retail
 
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"

NAME="Colin Mcrae Rally 2005"
PREFIX="CMR2005"
URL="ftp://downloads.codemasters.com/patch/colin_mcrae%20rally_2005%20patch_installer.exe"

if [ "$POL_LANG" == "fr" ]; then
INSTALLATION="Installation en cours..."
INSTALLATIONPATCH="Installation de la mise à jour en cours..."
DPATCH="Voulez-vous installer la mise à jour pour $NAME ?"
DOWNLOADT="Téléchargement de la mise à jour"
DOWNLOAD="Téléchargement de la mise à jours en cours..."
PATCHE="La mise à jour à été installée avec succès"
else
INSTALLATION="Installation in progress..."
INSTALLATIONPATCH="Installation of the update in progress..."
DPATCH="Do you want to install the update for $NAME ?"
PATCHE="The update has been installed successfully"
DOWNLOADT="Download of the update"
DOWNLOAD="Download of the update in progress..."
fi

wget http://bookinalex.b.o.pic.centerblog.net/tced3etm.jpg --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 "$NAME" "Codemasters" "www.codemasters.com" "thib25" "$PREFIX"

POL_SetupWindow_cdrom
POL_SetupWindow_check_cdrom "setup.exe"

select_prefixe "$REPERTOIRE/wineprefix/$PREFIX/"
POL_SetupWindow_prefixcreate

POL_SetupWindow_wait_next_signal "$INSTALLATION" "$NAME"
wine "$CDROM/setup.exe"
POL_SetupWindow_detect_exit

POL_SetupWindow_question "$DPATCH" "$NAME" 

if [ "$APP_ANSWER" == "TRUE" ] ;then
cd "$REPERTOIRE/Temp"
POL_SetupWindow_download "$DOWNLOADT" "$DOWNLOAD" "$URL"
POL_SetupWindow_wait_next_signal "$INSTALLATIONPATCH" "$NAME"
wine "colin_mcrae rally_2005 patch_installer.exe"
POL_SetupWindow_detect_exit
POL_SetupWindow_message "$PATCHE" "$NAME"
fi

POL_SetupWindow_make_shortcut "$PREFIX" "Program Files/Codemasters/Colin McRae Rally 2005" "cmr5.exe" "" "$NAME"

POL_SetupWindow_Close
exit

Par contre j'ai un problème pour le téléchargement de l'update : POL me dit que le serveur est indisponible pourtant le lien est valide. Je comprends pas moi :incertain:.
Berillions Monday 5 October 2009 at 19:27
Berillions

Salut Thib25,

J'ai testé une partie de ton script, plus particulièrement celle ou tu dois télécharger le patch. Pour ma part, tout fonctionne bien, je le télécharge.

Mais, tu n'as pas corrigé toutes les fautes que je t'ai signalé plus haut. :p

A savoir :
cd "$REPERTOIRE/Temp"
Qui est à l'interieur de ton instruction If. Le répertoire Temp n'existe pas, c'est tmp donc remplace par ceci :
cd "$REPERTOIRE/tmp"

Ensuite pour cette ligne :
POL_SetupWindow_download "$DOWNLOADT" "$DOWNLOAD" "$URL"
Pas besoin de mettre $DOWNLOADT et $DOWNLOAD. Pourquoi dire la même chose deux fois. Autant mettre :
POL_SetupWindow_download "$DOWNLOAD" "$NAME" "$URL"

Pour ce cas, c'est toi qui décide, je ne fais que donner mon avis. Sinon, c'est du tout bon.
J'essayerais d'obtenir le jeu pour tester mais je promets rien.

thib25 Monday 5 October 2009 at 21:53
thib25Anonymous

Bon bah les problèmes doivent venir de moi déjà car j'arrive pas à télécharger en plus quand je crée un raccourci une boîte de dialogue me marque erreur. Vivement l'arrivé d'Ubuntu 9.10 pour que je fasse une réinstallation bien propre et que j'essaye de passer plus de temps sous Linux que sous Windows. Sinon je verrais pour faire les modifs demain et tester ça en plein écran en 1680 x 1050 car pour l'instant j'ai seulement testé en 800x600 en mode fenêtré.
thib25 Thursday 8 October 2009 at 18:31
thib25Anonymous

Bon j'ai mis à jour mon script :
#!/bin/bash
# Date : (2009-08-23 13-00)
# Last revision : (2009-10-04 15-15)
# Wine version used : 1.1.30
# Distribution used to test : Ubuntu 9.04
# Author : thib25
# Licence : Retail
 
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"

NAME="Colin Mcrae Rally 2005"
PREFIX="CMR2005"
URL="ftp://downloads.codemasters.com/patch/colin_mcrae%20rally_2005%20patch_installer.exe"

if [ "$POL_LANG" == "fr" ]; then
INSTALLATION="Installation en cours..."
INSTALLATIONPATCH="Installation de la mise à jour en cours..."
DPATCH="Voulez-vous installer la mise à jour pour $NAME ?"
DOWNLOAD="Téléchargement de la mise à jours en cours..."
PATCHE="La mise à jour à été installée avec succès"
else
INSTALLATION="Installation in progress..."
INSTALLATIONPATCH="Installation of the update in progress..."
DPATCH="Do you want to install the update for $NAME ?"
PATCHE="The update has been installed successfully"
DOWNLOAD="Download of the update in progress..."
fi

wget http://bookinalex.b.o.pic.centerblog.net/tced3etm.jpg --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 "$NAME" "Codemasters" "www.codemasters.com" "thib25" "$PREFIX"

POL_SetupWindow_cdrom
POL_SetupWindow_check_cdrom "setup.exe"

select_prefixe "$REPERTOIRE/wineprefix/$PREFIX/"
POL_SetupWindow_prefixcreate

POL_SetupWindow_wait_next_signal "$INSTALLATION" "$NAME"
wine "$CDROM/setup.exe"
POL_SetupWindow_detect_exit

POL_SetupWindow_question "$DPATCH" "$NAME" 

if [ "$APP_ANSWER" == "TRUE" ] ;then
cd "$REPERTOIRE/tmp"
POL_SetupWindow_download "$DOWNLOAD" "$NAME" "$URL"
POL_SetupWindow_wait_next_signal "$INSTALLATIONPATCH" "$NAME"
wine "colin_mcrae rally_2005 patch_installer.exe"
POL_SetupWindow_detect_exit
POL_SetupWindow_message "$PATCHE" "$NAME"
fi

POL_SetupWindow_make_shortcut "$PREFIX" "Program Files/Codemasters/Colin McRae Rally 2005" "cmr5.exe" "" "$NAME"

POL_SetupWindow_Close
exit

Le téléchargement fonctionne correctement sur mon pc mais il ne lance pas l'update je crois qu'il ne cherche pas dans le bon dossier. Sinon il faut que je pense à supprimer le fichier du patch après l'installation.
Berillions Thursday 8 October 2009 at 19:06
Berillions

Est-ce que tu peux re-tester ton script après avoir remplacé :
wine "colin_mcrae rally_2005 patch_installer.exe"
par :
wine "./colin_mcrae rally_2005 patch_installer.exe"
Merci ;-)

thib25 Friday 9 October 2009 at 18:08
thib25Anonymous

Non ça marche toujours pas, dans la console ça marque :
wine: cannot find './colin_mcrae rally_2005 patch_installer.exe'
Je vais voir pour réessayer mais le problème c'est que l'installation du jeu dure 1/2 heure alors je suis pas motivé pour réinstaller à chaque fois.
thib25 Friday 9 October 2009 at 18:29
thib25Anonymous

Finalement, j'ai trouvé le problème, le fichier téléchargé voit son nom modifié quand le téléchargement est finit. Alors j'ai modifié le script et maintenant c'est censé fonctionner correctement.

#!/bin/bash
# Date : (2009-08-23 13-00)
# Last revision : (2009-10-04 15-15)
# Wine version used : 1.1.30
# Distribution used to test : Ubuntu 9.04
# Author : thib25
# Licence : Retail
 
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"

NAME="Colin Mcrae Rally 2005"
PREFIX="CMR2005"
URL="ftp://downloads.codemasters.com/patch/colin_mcrae%20rally_2005%20patch_installer.exe"

if [ "$POL_LANG" == "fr" ]; then
INSTALLATION="Installation en cours..."
INSTALLATIONPATCH="Installation de la mise à jour en cours..."
DPATCH="Voulez-vous installer la mise à jour pour $NAME ?"
DOWNLOAD="Téléchargement de la mise à jours en cours..."
PATCHE="La mise à jour à été installée avec succès"
else
INSTALLATION="Installation in progress..."
INSTALLATIONPATCH="Installation of the update in progress..."
DPATCH="Do you want to install the update for $NAME ?"
PATCHE="The update has been installed successfully"
DOWNLOAD="Download of the update in progress..."
fi

wget http://bookinalex.b.o.pic.centerblog.net/tced3etm.jpg --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 "$NAME" "Codemasters" "www.codemasters.com" "thib25" "$PREFIX"

POL_SetupWindow_cdrom
POL_SetupWindow_check_cdrom "setup.exe"

select_prefixe "$REPERTOIRE/wineprefix/$PREFIX/"
POL_SetupWindow_prefixcreate

POL_SetupWindow_wait_next_signal "$INSTALLATION" "$NAME"
wine "$CDROM/setup.exe"
POL_SetupWindow_detect_exit

POL_SetupWindow_question "$DPATCH" "$NAME" 

if [ "$APP_ANSWER" == "TRUE" ] ;then
cd "$REPERTOIRE/tmp"
POL_SetupWindow_download "$DOWNLOAD" "$NAME" "$URL"
POL_SetupWindow_wait_next_signal "$INSTALLATIONPATCH" "$NAME"
wine "./colin_mcrae%20rally_2005%20patch_installer.exe"
POL_SetupWindow_detect_exit
POL_SetupWindow_message "$PATCHE" "$NAME"
rm -rf colin_mcrae%20rally_2005%20patch_installer.exe
fi 

POL_SetupWindow_make_shortcut "$PREFIX" "Program Files/Codemasters/Colin McRae Rally 2005" "cmr5.exe" "" "$NAME"

POL_SetupWindow_Close
exit
thib25 Friday 9 October 2009 at 20:37
thib25Anonymous

ça y'est le script fonctionne parfaitement bien par contre maintenant avec le patch j'arrive pas à démarrer le jeu à cause de la protection. Je pense qu'il va falloir que je met un message comme quoi il faut un patch NO-CD.

Voilà le script :
#!/bin/bash
# Date : (2009-08-23 13-00)
# Last revision : (2009-10-04 15-15)
# Wine version used : 1.1.30
# Distribution used to test : Ubuntu 9.04
# Author : thib25
# Licence : Retail
 
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"

NAME="Colin Mcrae Rally 2005"
PREFIX="CMR2005"
URL="ftp://downloads.codemasters.com/patch/colin_mcrae%20rally_2005%20patch_installer.exe"

if [ "$POL_LANG" == "fr" ]; then
INSTALLATION="Installation en cours..."
INSTALLATIONPATCH="Installation de la mise à jour en cours..."
DPATCH="Voulez-vous installer la mise à jour pour $NAME ?"
DOWNLOAD="Téléchargement de la mise à jours en cours..."
PATCHE="La mise à jour à été installée avec succès"
MESSAGE="Veuillez noter que ce jeu a besoin d'un patch no-cd pour pouvoir être lancer.\\nPlayOnLinux ne vous fournira aucune aide ou lien pour ce crack."
else
INSTALLATION="Installation in progress..."
INSTALLATIONPATCH="Installation of the update in progress..."
DPATCH="Do you want to install the update for $NAME ?"
PATCHE="The update has been installed successfully"
DOWNLOAD="Download of the update in progress..."
MESSAGE="Please note that this game need a no-cd patch to work.\\nPlayOnLinux will not provide any help or link for this crack."
fi

wget http://bookinalex.b.o.pic.centerblog.net/tced3etm.jpg --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 "$NAME" "Codemasters" "www.codemasters.com" "thib25" "$PREFIX"

POL_SetupWindow_cdrom
POL_SetupWindow_check_cdrom "setup.exe"

select_prefixe "$REPERTOIRE/wineprefix/$PREFIX/"
POL_SetupWindow_prefixcreate

POL_SetupWindow_wait_next_signal "$INSTALLATION" "$NAME"
wine "$CDROM/setup.exe"
POL_SetupWindow_detect_exit

POL_SetupWindow_question "$DPATCH" "$NAME" 

if [ "$APP_ANSWER" == "TRUE" ] ;then
cd "$REPERTOIRE/tmp"
POL_SetupWindow_download "$DOWNLOAD" "$NAME" "$URL"
POL_SetupWindow_wait_next_signal "$INSTALLATIONPATCH" "$NAME"
wine "./colin_mcrae%20rally_2005%20patch_installer.exe"
POL_SetupWindow_detect_exit
POL_SetupWindow_message "$PATCHE" "$NAME"
rm -rf colin_mcrae%20rally_2005%20patch_installer.exe
fi 

POL_SetupWindow_make_shortcut "$PREFIX" "Program Files/Codemasters/Colin McRae Rally 2005" "cmr5.exe" "" "$NAME"
POL_SetupWindow_message_image "$MESSAGE" "$NAME" "$PLAYONLINUX/themes/tango/warning.png"

POL_SetupWindow_Close
exit

Le problème maintenant c'est que le message s'ouvre puis se ferme à la vitesse de la lumière :^^:.

Editado por: thib25