Permalink
Browse files

Merge pull request #50 from Marty-D/master

Oblivious Pokemon are immune to Captivate, and Captivate only works on opposite-gendered foes.
  • Loading branch information...
2 parents 22564db + 035ade1 commit 5134b7c410f85304e5e5194e55591bc4a75cc875 @Zarel committed Apr 28, 2012
Showing with 10 additions and 0 deletions.
  1. +6 −0 abilities.js
  2. +4 −0 movedex.js
View
@@ -1245,6 +1245,12 @@ exports.BattleAbilities = {
return false;
}
},
+ onTryHit: function(pokemon, target, move) {
+ if (move.id === 'captivate') {
+ this.add('-message', 'It doesn\'t affect '+pokemon.name+'... (placeholder)');
+ return null;
+ }
+ },
id: "oblivious",
name: "Oblivious",
rating: 0.5,
View
@@ -1350,6 +1350,10 @@ exports.BattleMovedex = {
name: "Captivate",
pp: 20,
priority: 0,
+ onTryHit: function(pokemon, source) {
+ if ((pokemon.gender === 'M' && source.gender === 'F') || (pokemon.gender === 'F' && source.gender === 'M')) return;
+ else return false;
+ },
boosts: {
spa: -2
},

0 comments on commit 5134b7c

Please sign in to comment.