The forum

[Script] Motocross Madness 2

Game does crash when trying to run.

Author Replies
Dadu042 Thursday 21 March 2019 at 19:16
Dadu042

Game does crash when trying to run. Read the comments in the script.

I tried to use the informations found in http://appdb.winehq.org

 

#!/bin/bash
# Date : (2019-03-21 19-11)
# Last revision : (2019-03-21 19-11)
# Wine version used : 4.4
# Distribution used to test : Ubuntu 18.04 x64
# Script licence : GPL3
# Program licence : Retail
# Playonlinux v4.3.4
#
# Tested : CD v1.0 french (may 2000).
# Can NOT run the game, can only (with a NOCD) see the title screen, where it should launch a MPEG1 video.

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

TITLE="Motocross Madness 2"
PREFIX="motocross-madness-2"
WORKING_WINE_VERSION="4.4"
AUTHOR="Dadu042"
EDITOR="Microsoft"
GAME_URL="https://en.wikipedia.org/wiki/Motocross_Madness_2"

Set_OS "win2k"
Set_Desktop On 1024 768

POL_SetupWindow_Init
POL_Debug_Init
 
POL_SetupWindow_presentation "$TITLE" "$EDITOR" "$GAME_URL" "$AUTHOR" "$PREFIX"
 
POL_Wine_SelectPrefix "$PREFIX"
POL_System_SetArch "x86"
POL_Wine_PrefixCreate "$WORKING_WINE_VERSION"
POL_System_TmpCreate "$TITLE"

POL_Call POL_Function_NoCDWarning

POL_SetupWindow_InstallMethod "LOCAL,CD"

if [ "$INSTALL_METHOD" == "LOCAL" ]; then
        cd "$HOME"
        POL_SetupWindow_browse "$(eval_gettext 'Please select the setup file to run')" "$TITLE"
        SETUP_EXE="$APP_ANSWER"
        POL_Wine start /unix "$SETUP_EXE"
        POL_Wine_WaitExit "$TITLE"
        cd "$POL_System_TmpDir"
else
        POL_SetupWindow_cdrom
        POL_SetupWindow_check_cdrom "0000040c.256"
        POL_Wine start /unix "$CDROM/install.exe"
        POL_Wine_WaitExit "install.exe"
        cd "$POL_System_TmpDir"
fi

POL_Shortcut "MCM2.exe" "$TITLE" ""

POL_Shortcut_Document "$TITLE" "booklet.pdf"

POL_Call POL_Install_amstream
POL_Call POL_Install_quartz
POL_Call POL_Install_ffdshow
# The following function does crash as of 2019-03-21
POL_Call POL_Install_iv50

POL_System_TmpDelete
POL_SetupWindow_Close
exit 0

 

Edited by Dadu042

danber Friday 24 May 2019 at 2:25
danberAnonymous

Hey,

I have spent some time over the last couple of days investigating why the game crashes on video playback. At first I modified the game to skip the intro video but then it crashed in the menu instead when selecting race type.

Then I tried to install different codec packs with winetricks (like ffdshow) but still couldn't get it to run.

Eventually I got it working with amstream, quartz and icodecs. (dont install ffdshow)

To fix the garbled text in the help viewer I installed corefonts.

I'm new to writing scripts for POL but registered just for that purpose. Then I found your thread so I guess I won't have to ;)


Tested with:

  • wine 4.6
  • wine 4.8
  • proton 4.2

Too bad the game wasn't as fun as I remembered :D

 

Edited by danber

Dadu042 Friday 24 May 2019 at 7:45
Dadu042

Interresting :)    Please tell me what is 'icodecs' ?

You can modify the script, test it, then repost it. Once tested, I'll add it to the POL database.

 

Too bad the game wasn't as fun as I remembered :D

Human memory has known issues wink.

Edited by Dadu042

danber Friday 24 May 2019 at 10:29
danberAnonymous

Sorry, I got confused and thought POL_Install_XXXX where just a wrapper for winetricks.  :)

 

Winetricks has a verb called icodec which installs two packages that makes the game to work

1. Intel Audio/Video Compression/Decompression Software (codinstl.exe)
2. Indeo video codecs (3.2, 4 & 5)  (iv5setup.exe)

 

I found the script POL_Install_iv50 and it installs a different version of the indeo codecs than winetricks. I'm not sure exactly what is missing for the game to run but I am looking into it. Might need to create a new component installer :)

Edited by danber

danber Friday 24 May 2019 at 17:49
danberAnonymous

It took a while to understand how to create new functions and allow overrides when trying them out locally.

I made an update to winetricks to make the code easier to port to PlayOnLinux and then I created and sent in a new function here.

POL_Install_icodecs

The only change I made to your game script was to remove ffdshow and iv50 and replace them with POL_Install_icodecs.

 

#!/bin/bash
# Date : (2019-03-21 19-11)
# Last revision : (2019-03-21 19-11)
# Wine version used : 4.8
# Distribution used to test : Ubuntu 18.04 x64
# Script licence : GPL3
# Program licence : Retail
# Playonlinux v4.3.4
#
# Tested : CD v1.0 french (may 2000).
# Can NOT run the game, can only (with a NOCD) see the title screen, where it should launch a MPEG1 video.
 
[ -z "$PLAYONLINUX" ] && exit 0
source "$PLAYONLINUX/lib/sources"
 
TITLE="Motocross Madness 2"
PREFIX="motocross-madness-2"
WORKING_WINE_VERSION="4.8"
AUTHOR="Dadu042"
EDITOR="Microsoft"
GAME_URL="https://en.wikipedia.org/wiki/Motocross_Madness_2"
 
Set_OS "win2k"
Set_Desktop On 1024 768
 
POL_SetupWindow_Init
POL_Debug_Init
 
POL_SetupWindow_presentation "$TITLE" "$EDITOR" "$GAME_URL" "$AUTHOR" "$PREFIX"
 
POL_Wine_SelectPrefix "$PREFIX"
POL_System_SetArch "x86"
POL_Wine_PrefixCreate "$WORKING_WINE_VERSION"
POL_System_TmpCreate "$TITLE"
 
POL_Call POL_Function_NoCDWarning
 
POL_SetupWindow_InstallMethod "LOCAL,CD"
 
if [ "$INSTALL_METHOD" == "LOCAL" ]; then
        cd "$HOME"
        POL_SetupWindow_browse "$(eval_gettext 'Please select the setup file to run')" "$TITLE"
        SETUP_EXE="$APP_ANSWER"
        POL_Wine start /unix "$SETUP_EXE"
        POL_Wine_WaitExit "$TITLE"
        cd "$POL_System_TmpDir"
else
        POL_SetupWindow_cdrom
        POL_SetupWindow_check_cdrom "0000040c.256"
        POL_Wine start /unix "$CDROM/install.exe"
        POL_Wine_WaitExit "install.exe"
        cd "$POL_System_TmpDir"
fi
 
POL_Shortcut "MCM2.exe" "$TITLE" ""
 
POL_Shortcut_Document "$TITLE" "booklet.pdf"
 
POL_Call POL_Install_amstream
POL_Call POL_Install_quartz
POL_Call POL_Install_icodecs
 
POL_System_TmpDelete
POL_SetupWindow_Close
exit 0
danber Friday 24 May 2019 at 17:50
danberAnonymous

POL_Install_icodecs: https://www.playonlinux.com/sv/app-3524.html

 

One more thing. The filename that is used to check if the correct cd is inserted is not valid for the english release of the game. There it is named 00000409.256 instead of 0000040c.256

Do you know if there is an easy way to check for a file in a list of valid ones? Otherwise we might need to change the check to some other file.

Edited by danber

Dadu042 Friday 24 May 2019 at 20:01
Dadu042

yes I report your script to the webmaster of this website.

 

> Do you know if there is an easy way to check for a file in a list of valid ones?

No sad

Edited by Dadu042

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