Ohhh can't wait to use this once it's more complete. I can just imagine horror hacks making use of this and fading in the volume as you move.
Have you ever played a hack, heard a sound effect and wondered "wow I wonder where's that coming from haha", or have you ever just played Megaman X and liked how its sound effects came from different directions? ...no? ...oh okay.
...fear no more! this patch does just that!
The way this works is that whenever a sound effect is sent to the sound driver to be played, an optional second byte can be sent along with it which specifies its direction, when the sound driver (AMK) receives a sound effect, it also checks if a second "panning" byte came along with it, if it did, it'll recalculate its volume and pan it automatically, this means that it's compatible with both mono and stereo sound effects, vanilla or custom. All of this allows for a more "immersive" experience, perfect for more ambient-ish or spooky hacks.
Example video showcasing most vanilla SMW sound effects.
DOWNLOAD
Current limitations:
-Multiple sprites that play sound effects at the same time (chucks, grinders) will only have the panning from the most recent sprite.
-No perfectly centered panning.
The latter can be easily implemented, I'm just burned out from this patch. The former is more complicated though, as it would require checking which sprites are playing sound effects in the current frame and averaging their positions, and also checking if a newer, different sound effect was played in the same port (essentially overwritting everything).
Note that this requires a lot of wrappers so that it works with vanilla sprites, blocks and the player, therefore it needs free or unused space in banks 0 through 3 and because of this it may be incompatible with some resources, however, this can be changed through the defines included in the .asm file.
...fear no more! this patch does just that!
The way this works is that whenever a sound effect is sent to the sound driver to be played, an optional second byte can be sent along with it which specifies its direction, when the sound driver (AMK) receives a sound effect, it also checks if a second "panning" byte came along with it, if it did, it'll recalculate its volume and pan it automatically, this means that it's compatible with both mono and stereo sound effects, vanilla or custom. All of this allows for a more "immersive" experience, perfect for more ambient-ish or spooky hacks.
Example video showcasing most vanilla SMW sound effects.
DOWNLOAD
Current limitations:
-Multiple sprites that play sound effects at the same time (chucks, grinders) will only have the panning from the most recent sprite.
-No perfectly centered panning.
The latter can be easily implemented, I'm just burned out from this patch. The former is more complicated though, as it would require checking which sprites are playing sound effects in the current frame and averaging their positions, and also checking if a newer, different sound effect was played in the same port (essentially overwritting everything).
Note that this requires a lot of wrappers so that it works with vanilla sprites, blocks and the player, therefore it needs free or unused space in banks 0 through 3 and because of this it may be incompatible with some resources, however, this can be changed through the defines included in the .asm file.