Forums

The Feeble Files (GoG)

Auteur Réponses
petch Samedi 7 Janvier 2012 à 11:13
petch

Bonjour à tous,
J'ai écris un script pour "The Feeble Files". Ce jeu tourne sous ScummVM, je n'ai pas noté de différence entre les versions Windows et Linux de cette VM, mais le script permet tout de même d'utiliser les deux.
Bon jeu !

https://raw.github.com/petchema/playonlinux/master/thefeeblefiles-gog
#!/bin/bash
# Date : (2012-01-06 21-20)
# Last revision : (2012-01-06 23-38)
# Wine version used : 1.3.36
# Distribution used to test : Debian Sid (Unstable)
# Author : Pierre Etchemaite petchema@concept-micro.com
# Script licence : GPL v.2
# Program licence : Retail
# Depend :

# Tested with install archives:
# setup_the_feeble_files.exe 2476028 "16f0ec3760c68d646abc6671f657361a"
# setup_the_feeble_files-1.bin 2097523968 "df8a0031ac21f2efe93da1440d0fb024"
# setup_the_feeble_files-2.bin 289111409 "27197e9622d4ee349a8f4766f949426b"

[ -z "$PLAYONLINUX" ] && exit 0
source "$PLAYONLINUX/lib/sources"

PREFIX="FeebleFiles_gog"
WORKING_WINE_VERSION="1.3.36"

TITLE="$(eval_gettext 'The Feeble Files (GoG release)')"
SHORTCUT_NAME="The Feeble Files"
SHORTCUT_DOC="$SHORTCUT_NAME - $(eval_gettext 'User manual')"

POL_SetupWindow_Init
POL_Debug_Init

POL_SetupWindow_presentation "$TITLE" "Adventure Soft" "http://www.gog.com/en/gamecard/the_feeble_files" "Pierre Etchemaite" "$PREFIX"

POL_Wine_SelectPrefix "$PREFIX"
POL_Wine_PrefixCreate "$WORKING_WINE_VERSION"

cd $HOME
POL_SetupWindow_browse "$(eval_gettext 'Please select the setup file to run.')" "$TITLE" "setup_the_feeble_files.exe"
ARCHIVE="$APP_ANSWER"

POL_SetupWindow_question "$(eval_gettext 'This game uses the ScummVM emulator, that also exists natively for Linux.\\nUse native version when present?')" "$TITLE"
NATIVESCUMMVM=''
[ "$APP_ANSWER" = "TRUE" ] && NATIVESCUMMVM=1


POL_SetupWindow_wait "$(eval_gettext 'Please wait while $TITLE is installed.')" "$TITLE"

POL_Call POL_Function_SetNativeExtension "pdf"

POL_Wine start /unix "$ARCHIVE" || POL_Debug_Fatal "$(eval_gettext 'Error while installing archive')"

POL_Wine_WaitExit "$TITLE"

if cd "$WINEPREFIX/drive_c/$PROGRAMFILES/GOG.com/The Feeble Files/"; then
    # Create setup file for native ScummVM (translating paths)
    perl -ne 'chomp; 
	      if(/^(.*path)=(.*)/) { 
		my($setting, $path)=($1, $2); 
		my $unix_path=`winepath -u '"'"'$path'"'"'`; 
		chomp $unix_path; 
		print "$setting=$unix_path\\n"; 
	      } 
	      else { 
		print "$_\\n"; 
	      }' < feeble.ini > feeble-unix.ini
fi

# GoG work!
Set_OS winxp

# "SVGA videocard" (?)
POL_SetupWindow_VMS "2"

# Doesn't hurt ;)
POL_Wine_reboot

POL_Shortcut "scummvm.exe" "$SHORTCUT_NAME" "" "-c 'C:/$PROGRAMFILES/GOG.com/The Feeble Files/feeble.ini'"
cp "$WINEPREFIX/drive_c/$PROGRAMFILES/GOG.com/The Feeble Files/game.ico" "$REPERTOIRE/icones/32/$SHORTCUT_NAME"
if [ -n "$NATIVESCUMMVM" ]; then
    # All this because InsertBeforeWine does not like slashes, so I can't specify feeble-unix.ini path directly
    POL_Shortcut_InsertBeforeWine "$SHORTCUT_NAME" "cd .."
    POL_Shortcut_InsertBeforeWine "$SHORTCUT_NAME" "exec scummvm -c 'feeble-unix.ini'"
    POL_Shortcut_InsertBeforeWine "$SHORTCUT_NAME" "cd -"
fi
POL_Shortcut "start.exe" "$SHORTCUT_DOC" "" "'C:/$PROGRAMFILES/GOG.com/The Feeble Files/manual.pdf'"

POL_SetupWindow_Close

exit

This site allows content generated by members, and we promptly remove any content that infringes copyright according to our Terms of Service. To report copyright infringement, please send a notice to dmcayonlinux.com