mirror of
https://github.com/smogon/pokemon-showdown-client.git
synced 2026-03-21 17:50:29 -05:00
Teambuilder: Allow Tier filters on old gens (#2190)
This commit is contained in:
parent
43966190c6
commit
1a35b5c012
|
|
@ -53,7 +53,7 @@ function requireNoCache(pathSpec) {
|
|||
index = index.concat(Object.keys(Dex.data.TypeChart).map(x => toID(x) + ' type'));
|
||||
index = index.concat(['physical', 'special', 'status'].map(x => toID(x) + ' category'));
|
||||
index = index.concat(['monster', 'water1', 'bug', 'flying', 'field', 'fairy', 'grass', 'humanlike', 'water3', 'mineral', 'amorphous', 'water2', 'ditto', 'dragon', 'undiscovered'].map(x => toID(x) + ' egggroup'));
|
||||
index = index.concat(['ou', 'uu', 'ru', 'nu', 'pu', 'lc', 'nfe', 'uber', 'uubl', 'rubl', 'nubl', 'publ', 'cap', 'caplc', 'capnfe'].map(x => toID(x) + ' tier'));
|
||||
index = index.concat(['ou', 'uu', 'ru', 'nu', 'pu', 'zu', 'lc', 'nfe', 'uber', 'uubl', 'rubl', 'nubl', 'publ', 'zubl', 'cap', 'caplc', 'capnfe'].map(x => toID(x) + ' tier'));
|
||||
|
||||
let BattleArticleTitles = {};
|
||||
|
||||
|
|
|
|||
|
|
@ -234,7 +234,7 @@
|
|||
ru: "RU",
|
||||
nu: "NU",
|
||||
pu: "PU",
|
||||
zu: "(PU)",
|
||||
zu: "ZU",
|
||||
nfe: "NFE",
|
||||
lc: "LC",
|
||||
cap: "CAP",
|
||||
|
|
@ -243,7 +243,8 @@
|
|||
uubl: "UUBL",
|
||||
rubl: "RUBL",
|
||||
nubl: "NUBL",
|
||||
publ: "PUBL"
|
||||
publ: "PUBL",
|
||||
zubl: "ZUBL"
|
||||
};
|
||||
var tier = {name: tierTable[id]};
|
||||
return this.renderTierRow(tier, matchStart, matchLength, errorMessage);
|
||||
|
|
|
|||
|
|
@ -358,7 +358,6 @@ class DexSearch {
|
|||
|
||||
// For pokemon queries, accept types/tier/abilities/moves/eggroups as filters
|
||||
if (searchType === 'pokemon' && (typeIndex === 5 || typeIndex > 7)) continue;
|
||||
if (searchType === 'pokemon' && typeIndex === 3 && this.dex.gen < 9) continue;
|
||||
// For move queries, accept types/categories as filters
|
||||
if (searchType === 'move' && ((typeIndex !== 8 && typeIndex > 4) || typeIndex === 3)) continue;
|
||||
// For move queries in the teambuilder, don't accept pokemon as filters
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user