Hello everyone. There's a small story to this request for help:
I'm working on a commercial project, and my musician is (understandably) very concerned about how music files don't get shoved into the encrypted archive with everything else. Thankfully, he's not particularly picky about protecting the music, he just doesn't want it out in the open for everyone to nab.
This has led me down a few different paths, but the current one I'm on is where I modify the music file in some way and then un-modify it prior to playback. Here is where my problem comes in. I was under the impression that the Audio.bgm_play method took in a filestream that was supplied by RPG::BGM's play method, but I was wrong. Apparently it only takes in a file name, which sucks because with a filestream I could just unpack the file, pass the unpacked stream to the method, and call it a day.
So after failing to understand the basics of how RPG Maker works, I decided to get risky and override some of the methods of built-in classes/modules. As it turns out, Audio.bgm_play seems to use its own file loading routine -- overriding File.open, File.new, Kernel.open, Kernel.load_data, etc. all failed to do anything. (as an aside, my test was pretty simple -- I'd just alias the method and throw in a puts to see if bgm_play was using that method)
So I'm pretty sure this avenue is a dead end, but I wanted to post this and get some feedback just in case you all know something I don't. Some of you are very thorough and enterprising so I figure running this by all of you would make sure I didn't forget any loose ends.
And, of course, if you all know of a way to make music work in the encrypted archive (yes, even though tools exist to crack it wide open), I would appreciate that as well.
Thank you!
I'm working on a commercial project, and my musician is (understandably) very concerned about how music files don't get shoved into the encrypted archive with everything else. Thankfully, he's not particularly picky about protecting the music, he just doesn't want it out in the open for everyone to nab.
This has led me down a few different paths, but the current one I'm on is where I modify the music file in some way and then un-modify it prior to playback. Here is where my problem comes in. I was under the impression that the Audio.bgm_play method took in a filestream that was supplied by RPG::BGM's play method, but I was wrong. Apparently it only takes in a file name, which sucks because with a filestream I could just unpack the file, pass the unpacked stream to the method, and call it a day.
So after failing to understand the basics of how RPG Maker works, I decided to get risky and override some of the methods of built-in classes/modules. As it turns out, Audio.bgm_play seems to use its own file loading routine -- overriding File.open, File.new, Kernel.open, Kernel.load_data, etc. all failed to do anything. (as an aside, my test was pretty simple -- I'd just alias the method and throw in a puts to see if bgm_play was using that method)
So I'm pretty sure this avenue is a dead end, but I wanted to post this and get some feedback just in case you all know something I don't. Some of you are very thorough and enterprising so I figure running this by all of you would make sure I didn't forget any loose ends.
And, of course, if you all know of a way to make music work in the encrypted archive (yes, even though tools exist to crack it wide open), I would appreciate that as well.
Thank you!