"Universal Y/Z effects" does not seem to work for S3M files anymore. Listen to
Unreal by Purple Motion for example and you'll hear that the Zxx effects are interpreted as IT lowpass filter macros regardless of the "Universal Y/Z effects" setting.
Furthermore, I'd suggest this nifty way to determine whether filters should be used:
// Expliticely exclude ScreamTracker 3, it didn't have a lowpass filter.
bool useFilters = ((cwtv & 0xF000) > 0x1000);
// Don't use filters if an old version of Impulse Tracker was used to create this file.
// BABYLON.S3M by Necros has Zxx commands and was saved with IT 2.05. It will sound wrong if applying the filter commands
if((cwtv & 0xF000) == 0x3000 && cwtv < 0x3214)
useFilters = false;
So if useFilters is false, you should simply zap all MIDI Macros, and if it's true, just use the default IT macros.
By the way, you can also use the cwtv field for identifying some trackers that can save S3M files...
cwtv = 0x1
xyy = ST3 version x.yy (or other trackers that disguise as ST3)
cwtv = 0x2
xyy = Imago Orpheus version x.yy
cwtv = 0x3
xyy = Impulse Tracker version x.yy
cwtv = 0x4
xyy = Schism Tracker version x.yy if version <= 0.50 (0x4050). Otherwise, a timestamp is encoded in the xyy bits. Schism Tracker's version.c file should give a clue how to decode it, look up the method ver_decode_cwtv.
cwtv = 0x5
xyy = OpenMPT version x.yy
This should sound familar from IT's cwtv field. You are already decoding OpenMPT's version number there. Schism Tracker can also be identified using that field in IT files:
cwtv = 0x1
xyy = Schism Tracker version x.yy if version <= 0.50 (0x4050). Otherwise, a timestamp is encoded in the xyy bits (see above).