An easier method to replace the SEGA chant in your hack.

Discussion in 'Tutorials' started by Speems, May 24, 2020.

  1. Speems

    Speems Well-Known Member Member

    Joined:
    Mar 14, 2017
    Messages:
    83
    Location:
    Rochester Hills, MI
    As stated above, this is the method for replacing the SEGA chant I have used for my upcoming hack Sonic Maxidrive.

    To start off, open up Audacity. Then import the bin file that contains the SEGA PCM under the Import - Raw Data option, with the following settings:
    [​IMG]
    If successful, the raw sound can be played in the app. Place the new sound effect in the project, change its rate to 16000 Hz and apply enough speed changes to compensate. The project rate has to match. You will need to amplify the new sound until its volume matches the original sound.
    [​IMG]

    When the replacement is done, export the sound under other uncompressed files with a RAW header with the unsigned 8-bit PCM encoding. After the exporting is finished, change the RAW extension to BIN when viewing the file in your file browser.
    [​IMG]
    Delete the original BIN file in your disassembly and replace it with the new BIN. The filename HAS to be the same as the original. That filename itself depends on what disassembly you're using. Build the rom and you'll be able to hear it in action!

    If the sound appears slow, you did not change the replacement sound's Hz rate during the operation. Regardless if you succeed or fail, the sound will sound staticky after building the rom. Here's a tutorial by Puto to fix it:
    http://info.sonicretro.org/SCHG_How-to:Fix_the_SEGA_Sound

    Fortunately, this problem is only in the Hivebrain disassembly and the sound in the GitHub disassembly will always work. All disassemblies for Sonic 2 will have the replacement sound work just fine, same applies with the Sonic (3) and Knuckles disassemblies.

    Also of note, the SEGA PCM is 14000 Hz in Sonic (3) and Knuckles, so if you're using those disassemblies, the same rules apply but with 14000 Hz instead of 16000. Info brought up by BL3H.

    The output size cannot exceed 32 kilobytes. If it does, the GitHub disassembly cannot build and the Hivebrain disassembly will have unfixable issues. This piece of advice comes from server member Ashuro.
     
    Last edited: Aug 13, 2022
  2. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    I think you forgot to mention that the final file should not exceed 32kb. ($8000 bytes).
     
  3. Speems

    Speems Well-Known Member Member

    Joined:
    Mar 14, 2017
    Messages:
    83
    Location:
    Rochester Hills, MI
    Oh yeah, that. I'm not sure how it would sound if it exceeded 32kb but it's always wise to have some form of size limit for the sound. My hack uses the modern Sega jingle and is 31.2 kb, just 0.8 short of the limit. Strangely it still sounded right on emulators and hardware. Used to be that SA1 clip of Sonic saying "SEGA!" that was around 7 or 8 kb after conversion. But as mentioned, always wise to be mindful of the output size ;)
     
  4. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    The hack just can't build.
    Then it's in the Github version that it happens, for the Hivebrain version I think it just shouldn't sound or work.

    Still, nice tutorial, I was able to put my own voice during the SEGA screen.
     
  5. rSheffield

    rSheffield Active Member Member

    Joined:
    Nov 21, 2021
    Messages:
    27
    Location:
    Brazil
    What would you say is the perfect amplification for it? I'm using the 2017 SEGA Sound, hence why i am asking.

    EDIT: Nevermind. i found a way on how to amplify it the correct way.
     
    Dark Shamil Khan likes this.
  6. BL3H

    BL3H Newcomer Trialist

    Joined:
    Jul 19, 2022
    Messages:
    9
    Location:
    Tails' Workshop, Angel Island
    (sry for bump)

    For Sonic 3&K, the project rate & rate of the SEGA PCM must be 14000. All other settings should be the same.
     
    Samey and Speems like this.