Help with hacking Sonic 1 Music

Discussion in 'Discussion and Q&A Archive' started by LucasMadword, Jul 18, 2015.

  1. LucasMadword

    LucasMadword That one nerd. You know the one. Member

    Joined:
    Jul 18, 2015
    Messages:
    29
    Hello! This is my first time posting on the forums, so I hope I get this all right  :smile:

    So, I've been working on a hack, and it is coming along really well. I've done quite a bit of work on it (using the disassembly) and it looks really good! But, I need help with replacing the music in the game.

    I found a tutorial by nineko about music hacking using multiple tools. Here is the post. Now, I've gotten to Chapter 3, and found myself scratching my head as to what to do next. The post says to use XM3SMPS to convert the file to the correct format. I've tried XM3SMPS, XM3SMPS/OERG and XM4SMPS, but all of these programs don't work on my system. 3 and 3/OERG don't start at all, and 4 crashes as soon as I import the XM file. 

    What should I do? I want to be able to convert music myself (so I can convert it at will, and change it as I see fit), but the programs don't run on my system. I've tried running it on an XP virtual machine, and they don't work on there either. 

    Just to clarify: using the default Sonic 1 sound driver along with the Hivebrain disassembler. 

    The XM file I am trying to convert: DeviantArt Link.

    Thanks,

    LucasMadword

    Edited for formatting. 
     
    Last edited by a moderator: Jul 18, 2015
  2. LucasMadword

    LucasMadword That one nerd. You know the one. Member

    Joined:
    Jul 18, 2015
    Messages:
    29
    I've decided to use Mid2SMPS instead, and I've been able to convert the file! Nevermind then.

    But, I have also decided that I should write my own tutorial for Mid2SMPS as I haven't found one while searching the internet. I think it would be of use for many. 
     
  3. nineko

    nineko I am the Holy Cat Member

    Joined:
    Mar 24, 2008
    Messages:
    1,902
    Location:
    italy
    Well yeah I suggested xm3smps in my tutorial for two reasons, partially because I'm biased towards my own programs. However, any mean to obtain songs in SMPS format will work just fine, be it mid2smps, a port from other games, black magic, direct hex editing, ...

    For the record, if you run a modern Windows, you probably lack some libraries which are needed by xm3smps to run, such as msvbvm50 or that other one I cba to look up since it's on another computer.

    Feel free to ask further questions if you feel that my tutorial is incomplete or needs to be better explained.
     
  4. LucasMadword

    LucasMadword That one nerd. You know the one. Member

    Joined:
    Jul 18, 2015
    Messages:
    29
    Haha yeah. Bias is good though (sometimes)! 

    I did install the libraries that it said I needed, but it still didn't work (even when trying it on XP). So, I'm not sure what's going on there (probably my fault, everything is my fault). But, your tutorial was really good (it'd be better if I could run the final program, but still  :wink: ). I understood how to do everything in it, so that's a plus! 

    Thanks for the reply, nineko! 
     
  5. ProjectFM

    ProjectFM Optimistic and self-dependent Member

    Joined:
    Oct 4, 2014
    Messages:
    912
    Location:
    Orono, Maine
    I feel bad for you because XM3SMPS/oerg has become my primary tool for creating custom SMPS music. If you ever do get it working, I recommend using it. It allows for tons of customization and can be used to make some great stuff.
     
  6. Animemaster

    Animemaster Lets get to work! Member

    Joined:
    Mar 20, 2009
    Messages:
    1,229
    Location:
    UK
    The reason why xm4smps crashes is probably due to a version issue with Modplugtracker. I find that certain versions (newer ones), xm4 doesn't like for some reason. I have a really back ass wards way of doing things but, I have 1.17 modplugtracker which xm4 seems fine with, but because the 1.17 is older it ironically does not have the convert to xm. So? i use a newer version just for that. Yeah I know it could be easier but I'm kinda lazy and at the same time I don't have the time to try out new things as of yet. Not sure about Xm3 though, I had a similar problem but then it just worked so I'm not sure what I did.
     
  7. nineko

    nineko I am the Holy Cat Member

    Joined:
    Mar 24, 2008
    Messages:
    1,902
    Location:
    italy
    FYI, I use Mod Plug Tracker 1.16.0203, which can import MIDI files and save correct XM files just fine. I'm not sure why 1.17 would lack either of those capabilities. I didn't check the XM file in the OP with xm3smps because as I said it's on another pc and I'm too lazy to retrieve it just for that, though I checked it in MPT and it's filled with the timing issues which can be removed by following this other tutorial.

    By the way, I'm not sure why xm4smps would refuse to load any XM, but I'm not familiar with its internals since Puto wrote it, but I know him and I'm sure he did a very good job so there probably is another explanation. On the other hand, I can say that xm3smps's loader is bad as hell (as you know, I wrote its main core in like a couple of hours and never bothered to optimise it), not in the sense that it would refuse to load weird XM files (it's actually quite robust with unusual values), but it could be way faster and way more flexible. I learnt many tricks since then, an xm3smps written today would be an entirely different story. Fortunately there is no need for it because mid2smps is the new big thing.
     
    Last edited by a moderator: Jul 19, 2015
  8. Unused Account

    Unused Account Well-Known Member Member

    Joined:
    May 10, 2013
    Messages:
    153
    ​A tutorial for Mid2SMPS would be nice, I'm no good at using it. I usually just find one thing I can do and stick to it but I'm trying to widen my romhack and make it unique.
     
  9. amphobius

    amphobius spreader of the pink text Member

    Joined:
    Feb 24, 2008
    Messages:
    970
    Location:
    United Kingdom
    Sorry for the late reply, but I feel that I should mention I have been working on a guide for mid2smps for some time now. It should be ready in time for the Hacking Contest, but it'll only cover what I know. Please tell me if there's any subjects you'd like me to cover, though.