For anyone familiar with Krosk's find file plugin for VX Ace, that's essentially what I'm trying to recreate here. I have had minor success in my attempts except for a couple of snags.
I'm only focusing on Se, since it makes it faster to troubleshoot it when focusing on the one audio type.
When there's an error, aka a missing file, rpg maker tries to default to its error message. I wanted to try and recreate Krosk's Find File so that play testers can catch the more serious bugs, and I don't have to repackage it several times because I deleted an rtp file that I forgot I was still using.
So the current issues with it are as follows:
Am I missing something, or have I gotten something wrong? Or both?
Once this is working, I can theoretically just apply it to the other audio types, then try to figure out applying it for images.
I'm only focusing on Se, since it makes it faster to troubleshoot it when focusing on the one audio type.
Code:
/*:
(pretend the about section is above this)
@param Missing Error Message
@type string
@default "%s could not be found. Please contact the dev at (your url here)."
@desc Error message if a sound file is missing.
@param Show in Console?
@type boolean
@default false
@desc Error message is shown in the console instead
*/
var ftp = ftp ||{}
var parameters = PluginManager.parameters("FTP_MissingFileSkipper");
var MissingError = parameters["Missing Error Message"];
var ConsoleMsg = parameters["Show in Console?"] == "false";
ftp.MissingFileSkipper = function () {
AudioManager._OGPlaySe = AudioManager.playSe;
AudioManager.playSe = function (se) {
if (this._isError = true) {
showMissingError(se.name);
}
else {
this._OGPlaySe(se);
}
};
showMissingError = function (filename) {
const message = MissingError.replace("%s", filename);
if (ConsoleMsg) {
console.warn(message);
}
else {
alert(message);
}
};
};
ftp.MissingFileSkipper ();
;
When there's an error, aka a missing file, rpg maker tries to default to its error message. I wanted to try and recreate Krosk's Find File so that play testers can catch the more serious bugs, and I don't have to repackage it several times because I deleted an rtp file that I forgot I was still using.
So the current issues with it are as follows:
- Even when the se file (i.e. absorb1) is put back in the right place, the plugin still displays the error message.
- When at its default false, it sends the error message to console, but when set to true it sends it to the alert msgbox. This is the exact inverse of what I want, but as far as I can tell, it looks like it's set up correctly when compared to another boolean parameter in a different plugin.
Am I missing something, or have I gotten something wrong? Or both?
Once this is working, I can theoretically just apply it to the other audio types, then try to figure out applying it for images.