From 377345454fc008a9d0e1ae9e167ba56d00a8df4a Mon Sep 17 00:00:00 2001 From: Slayer95 Date: Mon, 14 Jul 2014 19:03:38 -0500 Subject: [PATCH] Shed Bell may be nullified by Sheer Force Also remove 'AfterMove' global event from all gens, and 'AfterMoveSelf' from Gen 3 onwards. --- data/items.js | 3 ++- data/scripts.js | 3 +-- mods/gennext/items.js | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/data/items.js b/data/items.js index 6afd5d48f1..97c8a08a80 100644 --- a/data/items.js +++ b/data/items.js @@ -3686,7 +3686,8 @@ exports.BattleItems = { fling: { basePower: 30 }, - onAfterMoveSelf: function (source, target) { + onAfterMoveSecondarySelfPriority: -1, + onAfterMoveSecondarySelf: function (source, target) { if (source.lastDamage > 0) { this.heal(source.lastDamage / 8, source); } diff --git a/data/scripts.js b/data/scripts.js index e3711ac55f..694671599b 100644 --- a/data/scripts.js +++ b/data/scripts.js @@ -44,8 +44,7 @@ exports.BattleScripts = { pokemon.moveUsed(move); this.useMove(move, pokemon, target, sourceEffect); this.singleEvent('AfterMove', move, null, pokemon, target, move); - this.runEvent('AfterMove', target, pokemon, move); - this.runEvent('AfterMoveSelf', pokemon, target, move); + if (this.gen <= 2) this.runEvent('AfterMoveSelf', pokemon, target, move); }, useMove: function (move, pokemon, target, sourceEffect) { if (!sourceEffect && this.effect.id) sourceEffect = this.effect; diff --git a/mods/gennext/items.js b/mods/gennext/items.js index e1d5e336ef..9a376d8155 100644 --- a/mods/gennext/items.js +++ b/mods/gennext/items.js @@ -78,7 +78,7 @@ exports.BattleItems = { }, "bigroot": { inherit: true, - onAfterMoveSelf: function (source, target) { + onAfterMoveSecondarySelf: function (source, target) { if (source.hasType('Grass')) { if (source.lastDamage > 0) { this.heal(source.lastDamage / 8, source);