Mod Archive Forums Mod Archive Forums
Advanced search  

News:

Please note: Your main modarchive.org account will not work here, you must create a forum account to post on the forums.

Pages: [1]   Go Down

Author Topic: Broken module  (Read 3840 times)

0 Members and 1 Guest are viewing this topic.

sherekhan

  • New User
  • Offline Offline
  • Posts: 36
    • View Profile
Broken module
« on: October 29, 2020, 15:36:52 »

Listening to some old 4-Mat chip modules I came across one that seems to be broken:

trap (pt.2)
https://modarchive.org/index.php?request=view_by_moduleid&query=77810

There is also a trap (pt.1) at https://modarchive.org/index.php?request=view_by_moduleid&query=77809
This seems to be fine.

But part 2 is completely silent when I try to play it. I even tried to play in in EaglePlayer and Protracker on Amiga, but complete silence until you get a couple of minutes in, and you hear a single drum. Inspecting the samples in Protracker, it seems that only the first sample (the drum) is loaded. The rest are allocated and do take space, but they are all completely flat.

Loading the same module in OctaMED, the picutre changes somewhat: Now all samples seem to be populated, but the first sample is full of garbage, and the rest do no look correct either.

My guess is there is a broken data pointer somewhere in the MOD. Somebody more versed in the MOD file format could possibly fix this by correcting the relevant values. I did manage to fix it another way, though. Judging from the instrument names, pt.1 and pt.2 uses the same samples. The only reason the song is split in two is probably because of the number of patterns required to track the entire song. So I did the following:

1) Loaded pt.2 into OctaMED
2) Saved pt.2 as a MED song without samples
3) Loaded pt.1 in OctaMED. Now I have the song and all instruments loaded.
4) With pt.1 still loaded, I Loaded the MED I made in step of pt.2. It contains no samples, but I already have the samples loaded from pt.1, so OctaMED will just keep those in place and only load the song data.
5) Save as MOD.

BTW, the song is a conversion of a C64 SID by Ben Dagliesh, for the game Trap. The game even featured a special 2xSID stereo version recorded on side B of the tape!
Logged

Saga Musix

  • TMA Moderator
  • Top Poster
  • ****
  • Offline Offline
  • Posts: 2571
  • I love OpenMPT! And Modules! And TMA! And Pie! :>
    • View Profile
    • Saga Musix - free module music and more!
Re: Broken module
« Reply #1 on: October 29, 2020, 18:37:45 »

There's no pointers in the MOD format at all. There is no data present after the first sample in that particular MOD file, which is why you hear silence in most players. OctaMED probably just blindly allocates some memory and doesn't clear it, so you hear whatever data is left in memory for those samples (so if you first listened to part 1, changes are high that some of its sample data still lingers in memory when loading part 2 afterwards). Even if it's just random garbage in memory, most of those samples will still sound "kind of okay" as they are chipped.
To preserve the file as much as possible, I went ahead and spliced the samples from part 1 into part 2 with a hex editor. That should keep the file as pristine as possible.

Edit: Here's the fixed file: https://modarchive.org/module.php?190644
« Last Edit: October 29, 2020, 18:49:03 by Saga Musix »
Logged
» My TMA artist profile
» Visit my music site: https://sagamusix.de/ [de, en]
» Visit my programming website: https://sagagames.de/ [de]
» Open ModPlug Tracker
Pages: [1]   Go Up