View Single Post
Old 17 September 2020, 23:43   #143
pipper
Registered User
 
Join Date: Jul 2017
Location: San Jose
Posts: 675
Just browsing the ROTT source (assuming this is what you have been trying) at https://github.com/lantus/ROTT
I can see a potential problem in

Code:
int MUSIC_StopSong(void)
{
    if (!fx_initialized)
    {
        setErrorMessage("Need FX system initialized, too. Sorry.");
        return(MUSIC_Error);
    } // if

    if (musicHandle)
    {
        Mus_Unregister(musicHandle);      <<<<< DONT UNREGISTER BEFORE CALL TO Mus_Stop()
        Mus_Stop(musicHandle);
    }
    
    return(MUSIC_Ok);
} // MUSIC_StopSong
'musicHandle' will be invalid after Mus_Unregister(musicHandle).

Maybe @Lantus360 can fix that? I am currently not set up to compile his sources.
pipper is offline  
 
Page generated in 0.06558 seconds with 11 queries