Sure, though it's a bit technical.
First, some background on data types and endianness.
Although computer memory is made up of individual bits, it is not practical for computer programs to only query one bit at a time; instead, on most hardware memory is dealt with in larger chunks of varying sizes:
byte (8 bits) - this is the smallest unit of data addressable; used for ASCII characters and very small numbers.
word (16 bits) - this used to be the standard unit for storing numbers; not frequently used anymore
dword (32 bits) - the new standard unit for numbers.
As you probably know, 64-bit machines exist which can address four words (64 bits) at a time, but they are not yet mainstream.
As you can see, all of these units are some multiple of the byte. In fact, that is how they are manipulated under the hood: if you ask the machine to retrieve a word from memory, it will load two consecutive bytes. One of these bytes contains the bigger binary "decimal places"; this byte is called the most significant byte, or MSB. The other byte is the least significant byte, or LSB. So, for instance, a word representing a small number, say, 100, has an MSB that is completely 0, since 100 fits entirely inside the LSB.
Why do we care? Well, by definition a word is two consecutive bytes - but, back in the computing dark ages when companies first started manufacturing CPUs, nobody bothered forming a consensus about *which order* these two bytes should be stored in!
On Intel chips, words are stored LSB-first; that is, a word in memory looks like
LSB MSB
On the other, Apple's chips, and all network traffic, are stored MSB-first:
MSB LSB
This inconsistency causes nothing but trouble! Suppose, for instance, that the 100 above represents link's starting health in a quest. You save the quest on a PC, and the quest file looks like this:
100 0
L then fires up your quest on his Mac, and reads
100 0
but that 100 is now in the MSB instead of LSB! End result: Link has a huge amount of health (100 * 2^8, or 25600) instead of the intended 100.
Fortunately, it's not too hard to solve this problem: instead of just saving a raw memory dump of words in .qst files, we instead call Allegro methods which detect if we're running on a PC or Mac, and then flips the bytes in each word so that it conforms to PC ordering. Similarly, when a quest is loaded, the bytes are flipped back if you're running on a Mac-like machine.
This extra step during quest loading is the reason Mac quests don't become hopelessly corrupt on PCs, and vice versa. However, .wavs added an extra wrinkle.
When you load a .wav, Allegro, deep under the hood, loads all of the data in the .wav into one giant array of words, which looks like the following on a PC:
LSB MSB LSB MSB LSB MSB LSB MSB ...
Normally, that would be fine; when you saved your quest, the quest saving code would flip the bytes if necessary. But instead, because of a bug in Allegro, Allegro lies to the ZC program and tells it that the .wav data is actually an array of bytes, not of words:
BYTE BYTE BYTE BYTE BYTE BYTE...
since bytes are harmless, nothing special happens during quest saving. Then, when L loads the quest on his Mac, catastrophe strikes! All of the MSBs became LSBs, and the .wav is totally corrupt.
To fix this bug, I added code to ignore Allegro and manually flip and unflip each word in the .wav data, like is done for other quest data.
But for old quests, there's not much that can be done. SFX loaded on PCs look like
LSB MSB LSB MSB...
and SFX loaded on Macs look like
MSB LSB MSB LSB...
and there's no way to tell which format was used just by looking at the raw data.