Battles: Fix crash relating to getPokemon

_Some_ past gens apparently don't specify slots for active pokemon
sometimes...
This commit is contained in:
Guangcong Luo
2016-10-03 23:43:36 -04:00
parent 6db0bf24dc
commit 853fd51283

View File

@@ -5811,7 +5811,7 @@ var Battle = (function () {
if (!details) {
if (siden < 0) return null;
if (this.sides[siden].active[slot]) return this.sides[siden].active[slot];
isInactive = true;
if (slot >= 0) isInactive = true;
}
var searchid = '';