I want to alter the amount of TP gained to always be equal to the characters M.Def ("Spirit" in my game).
But no matter what I tweak, the TP seems to still use it's damage based formula. Any idea how to fix this?
This is the plugin I've been using up to this point.
But no matter what I tweak, the TP seems to still use it's damage based formula. Any idea how to fix this?
Code:
Game_Battler.prototype.initTp = function() {
this.setTp(Math.randomInt(0)); // Set's Starting TP to 0
};
mdf: { // Defining mdf (Spirit)
get: function mdf() {
return this.param(5);
}
configurable: true
}
Game_Battler.prototype.chargeTpByDamage = function(mdf) {
const value = Math.floor(mdf * this.tcr); // Replaces damageRate with Spirit
this.gainSilentTp(value);
};
This is the plugin I've been using up to this point.