This is my first foray into plugin development and JS in general so please be kind to what are probably very simple/obvious mistakes.
On startup, i get this error logged to the console:
and when I try to call any of the methods i get TypeError: undefined is not a function
Any help is appreciated.
Code:
//=======================================================
// SaveTone.js
//=======================================================
/*:
* @plugindesc Save and load screen tints with $gameScreen.saveTone() and $gameScreen.loadTone()
* @author haley
*
* @help This plugin does not provide plugin commands.
*/
(function() {
Game_Screen.prototype.saveTone = function() {
this._savedTone = this._tone;
};
Game_Screen.prototype.loadTone = function(duration) {
this.startTint(_savedTone, duration);
};
Game_Screen.prototype.toGrayscale = function(duration) {
var temp = tone.clone();
temp[3] = 255;
this.startTint(temp, duration);
};
};
})();
On startup, i get this error logged to the console:
and when I try to call any of the methods i get TypeError: undefined is not a function
Any help is appreciated.