Resolve #27
This commit is contained in:
parent
ed22806774
commit
e08531263e
|
@ -1251,6 +1251,7 @@ class @BattleView extends Backbone.View
|
||||||
|
|
||||||
isIllusioned: (pokemon) =>
|
isIllusioned: (pokemon) =>
|
||||||
illusionmons = ['Zoroark', 'Zorua']
|
illusionmons = ['Zoroark', 'Zorua']
|
||||||
|
console.log(pokemon.getIllu())
|
||||||
return true if (pokemon.attributes.species in illusionmons) and pokemon.attributes.percent == 100 and @model.attributes.turn <= 1
|
return true if (pokemon.attributes.species in illusionmons) and pokemon.attributes.percent == 100 and @model.attributes.turn <= 1
|
||||||
return true if pokemon.getIllu()
|
return true if pokemon.getIllu()
|
||||||
return false
|
return false
|
||||||
|
|
Binary file not shown.
|
@ -4835,6 +4835,7 @@
|
||||||
BattleView.prototype.isIllusioned = function(pokemon) {
|
BattleView.prototype.isIllusioned = function(pokemon) {
|
||||||
var illusionmons, _ref;
|
var illusionmons, _ref;
|
||||||
illusionmons = ['Zoroark', 'Zorua'];
|
illusionmons = ['Zoroark', 'Zorua'];
|
||||||
|
console.log(pokemon.getIllu());
|
||||||
if ((_ref = pokemon.attributes.species, __indexOf.call(illusionmons, _ref) >= 0) && pokemon.attributes.percent === 100 && this.model.attributes.turn <= 1) {
|
if ((_ref = pokemon.attributes.species, __indexOf.call(illusionmons, _ref) >= 0) && pokemon.attributes.percent === 100 && this.model.attributes.turn <= 1) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -4561,6 +4561,7 @@
|
||||||
BattleView.prototype.isIllusioned = function(pokemon) {
|
BattleView.prototype.isIllusioned = function(pokemon) {
|
||||||
var illusionmons, _ref;
|
var illusionmons, _ref;
|
||||||
illusionmons = ['Zoroark', 'Zorua'];
|
illusionmons = ['Zoroark', 'Zorua'];
|
||||||
|
console.log(pokemon.getIllu());
|
||||||
if ((_ref = pokemon.attributes.species, __indexOf.call(illusionmons, _ref) >= 0) && pokemon.attributes.percent === 100 && this.model.attributes.turn <= 1) {
|
if ((_ref = pokemon.attributes.species, __indexOf.call(illusionmons, _ref) >= 0) && pokemon.attributes.percent === 100 && this.model.attributes.turn <= 1) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
"armor"
|
"armor"
|
||||||
],
|
],
|
||||||
"spriteId": 404,
|
"spriteId": 404,
|
||||||
"type": "megastone"
|
"type": "formeitem"
|
||||||
},
|
},
|
||||||
"Flygon Armor": {
|
"Flygon Armor": {
|
||||||
"description": "Increases the Defense and Special Defense stats of Flygon by 25% when held.",
|
"description": "Increases the Defense and Special Defense stats of Flygon by 25% when held.",
|
||||||
|
@ -17,7 +17,7 @@
|
||||||
"armor"
|
"armor"
|
||||||
],
|
],
|
||||||
"spriteId": 404,
|
"spriteId": 404,
|
||||||
"type": "megastone"
|
"type": "formeitem"
|
||||||
},
|
},
|
||||||
"Leavanny Armor": {
|
"Leavanny Armor": {
|
||||||
"description": "Increases the Defense and Special Defense stats of Leavanny by 25% when held.",
|
"description": "Increases the Defense and Special Defense stats of Leavanny by 25% when held.",
|
||||||
|
@ -27,7 +27,7 @@
|
||||||
"armor"
|
"armor"
|
||||||
],
|
],
|
||||||
"spriteId": 404,
|
"spriteId": 404,
|
||||||
"type": "megastone"
|
"type": "formeitem"
|
||||||
},
|
},
|
||||||
"Zekrom Armor": {
|
"Zekrom Armor": {
|
||||||
"description": "Increases the Defense and Special Defense stats of Zekrom by 25% when held.",
|
"description": "Increases the Defense and Special Defense stats of Zekrom by 25% when held.",
|
||||||
|
@ -37,7 +37,7 @@
|
||||||
"armor"
|
"armor"
|
||||||
],
|
],
|
||||||
"spriteId": 404,
|
"spriteId": 404,
|
||||||
"type": "megastone"
|
"type": "formeitem"
|
||||||
},
|
},
|
||||||
"Ability Capsule": {
|
"Ability Capsule": {
|
||||||
"description": "Allows a Pokemon with one of its two standard Abilities to change to the other when used.",
|
"description": "Allows a Pokemon with one of its two standard Abilities to change to the other when used.",
|
||||||
|
|
|
@ -26,6 +26,9 @@ oldHasTakeableItem = @Pokemon::hasTakeableItem
|
||||||
if @item.type == 'megastone'
|
if @item.type == 'megastone'
|
||||||
[ species, forme ] = @item.mega
|
[ species, forme ] = @item.mega
|
||||||
return false if @species == species
|
return false if @species == species
|
||||||
|
else if @item.type is "formeitem"
|
||||||
|
[ species, forme ] = @item.itemForme
|
||||||
|
return false if @species == species
|
||||||
return true
|
return true
|
||||||
|
|
||||||
# Powder moves no longer affect Grass-type Pokemon.
|
# Powder moves no longer affect Grass-type Pokemon.
|
||||||
|
|
Loading…
Reference in New Issue