Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var Imported = Imported || {};
- Imported.TroyZ_SlipDamageMods = true;
- var TroyZ = TroyZ || {};
- TroyZ.SlipDamageMods = TroyZ.SlipDamageMods || {};
- TroyZ.SlipDamageMods.version = 1.0;
- TroyZ.SlipDamageMods.DataManager_isDatabaseLoaded = DataManager.isDatabaseLoaded;
- DataManager.isDatabaseLoaded = function() {
- if (!TroyZ.SlipDamageMods.DataManager_isDatabaseLoaded.call(this)) return false;
- if (!TroyZ.processSDMnote) {
- this.loadSDMNote($dataStates);
- TroyZ.processSDMnote = true;
- }
- return true;
- };
- DataManager.loadSDMNote = function(data) {
- for (var a = 1; a < data.length; a++) {
- var obj = data[a];
- var notedata = obj.note.split(/[\r\n]+/);
- obj.slipcankill = true;
- for (var b = 0; b < notedata.length; b++) {
- var line = notedata[b];
- if (line.match(/<(?:SLIP NO KILL)>/i)) {
- obj.slipcankill = false;
- }
- }
- }
- };
- Game_Battler.prototype.maxSlipDamage = function() {
- return $dataSystem.optSlipDeath && this.states.slipcankill ? this.hp : Math.max(this.hp - 1, 0);
- };
- // Game_Battler.prototype.maxSlipDamage = function() {
- // if ($dataSystem.optSlipDeath && this.states.slipcankill) {
- // this.hp;
- // }
- // else
- // {
- // Math.max(this.hp - 1, 0);
- // }
- // };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement