#!/bin/bash
[
"$PLAYONLINUX"
=
""
] &&
exit
0
source
"$PLAYONLINUX/lib/sources"
TYTUL=
"Croc Legend of the Gobbos"
PREFIX=
"CrocI"
WORKINGWINEVERSION=
"1.1.43"
POL_SetupWindow_make_icon_for_shortcut()
{
convert
"$HOME/.local/share/icons/$2"
-geometry 32X32
"$REPERTOIRE/icones/32/$1"
rm
-f
"$REPERTOIRE/icones/$1.ico"
}
wget http:
//upload
.wikimedia.org
/wikipedia/en/9/9c/Croc_Legend_of_the_Gobbos
.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
"$TYTUL"
"Argonaut Software"
"N/A"
"NSLW"
"$PREFIX"
select_prefix
"$REPERTOIRE/wineprefix/$PREFIX"
POL_SetupWindow_message
"Please insert $TYTUL media into your disk drive."
POL_SetupWindow_cdrom
POL_SetupWindow_check_cdrom
"./Setup/Setup.exe"
POL_SetupWindow_install_wine
"1.1.2"
POL_SetupWindow_install_wine
"$WORKINGWINEVERSION"
Use_WineVersion
"$WORKINGWINEVERSION"
POL_SetupWindow_prefixcreate
PROGRAMFILES=
"Program Files"
POL_LoadVar_PROGRAMFILES
cd
"$WINEPREFIX/dosdevices"
ln
-s
"$CDROM"
e:
cd
"$WINEPREFIX/drive_c/windows/temp/"
echo
"[HKEY_LOCAL_MACHINE\\\\Software\\\\Wine\\\\Drives]"
> cdrom.reg
echo
"\\"
e:\\
"=\\"
cdrom\\
""
>> cdrom.reg
regedit cdrom.reg
sleep
5
wine start
/unix
"$CDROM/Setup/Setup.exe"
POL_SetupWindow_message
"Click \\"
Next\\
" when installation will finish."
"$TYTUL"
POL_SetupWindow_menu_list
"How much memory do your graphic card have got?"
"$TYTUL"
"32-64-128-256-384-512-768-890-1024-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
echo
"[HKEY_LOCAL_MACHINE\\\\Software\\\\Argonaut Software\\\\Croc]"
> glide.reg
echo
"\\"
Driver name\\
"=\\"
3dfx_win\\
""
>> glide.reg
regedit glide.reg
cd
"$REPERTOIRE/ressources"
if
[ ! -e
"GlideWrapper084c.exe"
];
then
fi
if
[ ! -e
"dgVoodoo1.50Beta2.zip"
];
then
fi
POL_SetupWindow_wait_next_signal
"Installation in progress..."
"Zeckensack's Glide wrapper"
wine GlideWrapper084c.exe
POL_SetupWindow_detect_exit
POL_SetupWindow_wait_next_signal
"Installation in progress..."
"Zeckensack's Glide wrapper"
cd
"$WINEPREFIX/drive_c/$PROGRAMFILES/Fox/Croc"
mv
*lide2x.dll glide2x.dll.org
unzip
"$REPERTOIRE/ressources/dgVoodoo1.50Beta2.zip"
mv
glide2x.dll glide2x.dll.dgVoodoo
POL_SetupWindow_detect_exit
cd
"$REPERTOIRE/WineVersions"
cp
"$WORKINGWINEVERSION"
"$WORKINGWINEVERSION-Croc"
rm
-f
"./$WORKINGWINEVERSION-Croc/usr/lib/wine/wined3d.dll.so"
rm
-f
"./$WORKINGWINEVERSION-Croc/usr/lib/wine/ddraw.dll.so"
cp
"./$WORKINGWINEVERSION/usr/lib/wine/wined3d.dll.so"
"./$WORKINGWINEVERSION-Croc/usr/lib/wine/wined3d.dll.so"
cp
"./$WORKINGWINEVERSION/usr/lib/wine/ddraw.dll.so"
"./$WORKINGWINEVERSION-Croc/usr/lib/wine/ddraw.dll.so"
cd
"$WINEPREFIX/drive_c/windows/temp/"
rm
-rf *
POL_SetupWindow_make_shortcut
"$PREFIX"
"$PROGRAMFILES/Fox/Croc"
"CrocRun.exe"
""
"$TYTUL"
""
""
Set_WineVersion_Assign
"$WORKINGWINEVERSION-Croc"
"$TYTUL"
POL_SetupWindow_make_icon_for_shortcut
"$TYTUL"
"*_crocrun.0.xpm"
POL_SetupWindow_make_shortcut
"$PREFIX"
"$PROGRAMFILES/GlideWrapper"
"configurator.exe"
""
"Croc Zeckensack configurator"
""
""
Set_WineVersion_Assign
"$WORKINGWINEVERSION-Croc"
"Croc Zeckensack configurator"
cat
<< EOF >
"$REPERTOIRE/configurations/configurators/$TYTUL"
#!/bin/bash
source
"$PLAYONLINUX/lib/sources"
POL_SetupWindow_Init
cd
"$REPERTOIRE/configurations/installed"
if
[ -e
"Croc Zeckensack configurator"
];
then
rm
-f
"Croc Zeckensack configurator"
mv
"$WINEPREFIX/drive_c/$PROGRAMFILES/Fox/Croc/glide2x.dll.dgVoodoo"
"$WINEPREFIX/drive_c/$PROGRAMFILES/Fox/Croc/glide2x.dll"
POL_SetupWindow_make_shortcut
"$PREFIX"
"$PROGRAMFILES/Fox/Croc"
"dgVoodooSetup.exe"
""
"Croc dgVoodoo configurator"
""
""
Set_WineVersion_Assign
"$WORKINGWINEVERSION-Croc"
"Croc dgVoodoo configurator"
elif
[ -e
"Croc dgVoodoo configurator"
];
then
rm
-f
"Croc dgVoodoo configurator"
mv
"$WINEPREFIX/drive_c/$PROGRAMFILES/Fox/Croc/glide2x.dll"
"$WINEPREFIX/drive_c/$PROGRAMFILES/Fox/Croc/glide2x.dll.dgVoodoo"
POL_SetupWindow_make_shortcut
"$PREFIX"
"$PROGRAMFILES/GlideWrapper"
"configurator.exe"
""
"Croc Zeckensack configurator"
""
""
Set_WineVersion_Assign
"$WORKINGWINEVERSION-Croc"
"Croc Zeckensack configurator"
fi
POL_SetupWindow_Close
EOF
POL_SetupWindow_message
"$TYTUL has been installed successfully"
"$TYTUL"
POL_SetupWindow_question
"Do you've got NVIDIA GeForce 4 graphic card?"
"$TYTUL"
if
[
"$APP_ANSWER"
==
"TRUE"
] ;
then
cd
"$WINEPREFIX/drive_c/windows/temp/"
echo
"[HKEY_LOCAL_MACHINE\\\\Software\\\\Argonaut Software\\\\Croc]"
> glide.reg
echo
"\\"
Driver name\\
"=\\"
d3drend\\
""
>> glide.reg
regedit glide.reg
else
POL_SetupWindow_message_image
"If you want high screen resolution you must change Glide Wrapper.\\nTo do so please run \\"
Configure this application\\
"\\nfrom main PlayOnLinux window and select latest option"
"Glide wrapper"
"$PLAYONLINUX/themes/tango/info.png"
fi
POL_SetupWindow_Close
exit