(function() { var _Game_Party_gainGold = Game_Party.prototype.gainGold; Game_Party.prototype.gainGold = function(amount) { var variableId = 1; _Game_Party_gainGold.call(this, amount); var oldValue = $gameVariables.value(variableId); $gameVariables.setValue(variableId, oldValue + amount); }; })();
(function() {
var _Game_Party_gainGold = Game_Party.prototype.gainGold;
Game_Party.prototype.gainGold = function(amount) {
var variableId = 1;
_Game_Party_gainGold.call(this, amount);
var oldValue = $gameVariables.value(variableId);
$gameVariables.setValue(variableId, oldValue + amount);
};
})();
瞎写几行,楼主可以姑且参考一下 |