Page 4 of 6 FirstFirst ... 2 3 4 5 6 LastLast
Results 31 to 40 of 55

Thread: Can this feature be revived?

  
  1. #31
    Demon Spawn
    Join Date
    Jul 2016
    Location
    United Kingdom
    Posts
    186

    Default Re: Can this feature be revived?

    I've still got the actual sounds played that I extracted from the bullfrog soundfont (I need to get around to extracting the sounds from the other soundfonts). Is there any point in uploading them here?

  2. #32

    Default Re: Can this feature be revived?

    Probably not, but it can't hurt.

  3. #33
    Demon Spawn
    Join Date
    Jul 2016
    Location
    United Kingdom
    Posts
    186

    Default Re: Can this feature be revived?

    Quote Originally Posted by YourMaster View Post
    Probably not, but it can't hurt.
    It won't upload for some reason...

  4. #34
    Demon Spawn
    Join Date
    Jul 2016
    Location
    United Kingdom
    Posts
    186

    Default Re: Can this feature be revived?

    I came across this:

    https://github.com/dkfans/keeperfx-s...r/src/sounds.c

    and saw this code:

    Code:
    void randomize_sound_font(void)
    {
        StopMusic();
        switch (UNSYNC_RANDOM(3))
        {
        case 0:
            if (LoadAwe32Soundfont("bullfrog"))
              StartMusic(1, 127);
            break;
        case 1:
            if (LoadAwe32Soundfont("atmos1"))
              StartMusic(1, 127);
            break;
        case 2:
            if (LoadAwe32Soundfont("atmos2"))
              StartMusic(1, 127);
            break;
        }
    }
    Is there any way I can view the LoadAwe32Soundfont code? Or find out what accesses it (or this procedure)?

  5. #35
    Demon Spawn
    Join Date
    Jul 2016
    Location
    United Kingdom
    Posts
    186

    Default Re: Can this feature be revived?

    Quote Originally Posted by YourMaster View Post
    You understand correctly, there has been no progress on this at all.
    Not sure this counts as progress but:

    I've just got KeeperFX running on my Windows 10 x64 system, and used the same method as before (except with the wav sounds in the sounds.rar file uploaded before, rather than an actual SoundFont); I installed the WMPkeys plugin for Windows Media Player, set up a hotkey for starting and pausing, opened one of those wav files (and made sure it's set to loop), loaded KeeperFX and hit the hotkey when a game begins. The sounds played like they did on my AWE64 Gold system. It's not as good as that (I only get part of the sequence, as before), but it imitates a partial functioning of this feature, and is the best we can do for now.
    Last edited by AdamP; October 29th, 2018 at 03:32.

  6. #36

    Default Re: Can this feature be revived?

    Quote Originally Posted by AdamP View Post
    It won't upload for some reason...
    Try another upload website, like mega or mediafire.

    Quote Originally Posted by AdamP View Post
    I came across this:

    https://github.com/dkfans/keeperfx-s...r/src/sounds.c

    and saw this code:

    Code:
    void randomize_sound_font(void)
    {
        StopMusic();
        switch (UNSYNC_RANDOM(3))
        {
        case 0:
            if (LoadAwe32Soundfont("bullfrog"))
              StartMusic(1, 127);
            break;
        case 1:
            if (LoadAwe32Soundfont("atmos1"))
              StartMusic(1, 127);
            break;
        case 2:
            if (LoadAwe32Soundfont("atmos2"))
              StartMusic(1, 127);
            break;
        }
    }
    Is there any way I can view the LoadAwe32Soundfont code? Or find out what accesses it (or this procedure)?
    I believe that code says that when it tries to load a soundfont it just plays generic music file 127.
    You can enter LoadAwe32Soundfont in the searchbox of github (on the main branch) and see all the places it is referenced. It's not much, so I assume more is in the not-rewritten yet parts.

  7. #37
    Demon Spawn
    Join Date
    Jul 2016
    Location
    United Kingdom
    Posts
    186

    Default Re: Can this feature be revived?

    Quote Originally Posted by YourMaster View Post
    Try another upload website, like mega or mediafire.



    I believe that code says that when it tries to load a soundfont it just plays generic music file 127.
    You can enter LoadAwe32Soundfont in the searchbox of github (on the main branch) and see all the places it is referenced. It's not much, so I assume more is in the not-rewritten yet parts.
    Well, I looked at https://github.com/dkfans/keeperfx-s...bflib_sndlib.c and saw this:

    Code:
    int __stdcall LoadAwe32Soundfont(const char *fname)
    {
        HMODULE hModule;
        hModule=GetModuleHandle("WSND7R");
        FARPROC proc;
        proc=GetProcAddress(hModule,"[email protected]");
        if (proc==NULL)
        { ERRORLOG("Can't get address of LoadAwe32Soundfont function; skipped."); return 0; }
        return ((FARPROCS)proc)(fname);
    }
    It looks like LoadAwe32Soundfont is part of WSND7R.DLL. I looked at it, and from what I can tell, all the SoundFont loading stuff is AWE32/64-specific. I tried updating (I think) the WSND7R.DLL and AWEMAN32.DLL files, but it still doesn't work . The game also doesn't seem to load the midi unless a SoundFont is successfully loaded (I'm no expert in C, but from what I can tell looking at the randomize_sound_font procedure, it only plays the midi if the loading of the SoundFont is successful, which it of course won't be on modern systems (those also appear to be the only calls to StartMusic)); maybe the calls to LoadAwe32Soundfont should be removed so the game just plays the midi anyway? Then, hopefully it'll work if a SoundFont is manually loaded.
    Last edited by AdamP; October 30th, 2018 at 05:17.

  8. #38
    Demon Spawn
    Join Date
    Jul 2016
    Location
    United Kingdom
    Posts
    186

    Default Re: Can this feature be revived?

    I have good news!

    I have figured out how to use SynthFont to change the midi event keys of when the sounds play. I edited the midi data to change the drips and screams etc. I also checked music.dat with a hex editor, and there's definitely only the one midi file in there, so my suspicion that there are several midi files is false. I can only assume that the game somehow changes these keys dynamically. And yes, I can write this modified midi tune to wav or ogg format. I shall therefore in due course be making modified files and adding them to the converted wave files I've already posted here. It may not be exactly as the game, but I think it's as good as it's gonna get .

  9. #39
    Demon Spawn
    Join Date
    Jul 2016
    Location
    United Kingdom
    Posts
    186

    Default Re: Can this feature be revived?

    To anyone who's reading this thread, I think I'm close to getting this working! (albeit in a remade form) Watch this space!

  10. #40

    Default Re: Can this feature be revived?

    Should touch base with the unofficial patch dude, I'd love for this to be in an update.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •