Skip to content

Commit

Permalink
Revert "Programmatically generate BL lists"
Browse files Browse the repository at this point in the history
This reverts commit 3bc0166.
  • Loading branch information
shrianshChari committed Sep 18, 2024
1 parent 3bc0166 commit a0dbf30
Showing 1 changed file with 24 additions and 26 deletions.
50 changes: 24 additions & 26 deletions stats/src/reports.ts
Original file line number Diff line number Diff line change
Expand Up @@ -480,6 +480,30 @@ export const Reports = new class {
}
};

const BL: {[tier in Tier]?: Set<string>} = {
UU: new Set([
'hawlucha', 'dracozolt', 'diggersby', 'durant', 'weavile', 'ninetalesalola', 'gyarados',
'primarina', 'venusaur', 'haxorus', 'aegislash', 'conkeldurr', 'gengar', 'scolipede',
'lycanrocdusk',
]),
RU: new Set([
'barbaracle', 'pangoro', 'shiftry', 'slurpuff', 'chansey', 'indeedee', 'raichualola', 'linoone',
'sharpedo', 'zoroark', 'lucario', 'reuniclus', 'sirfetchd', 'heracross', 'sigilyph',
]),
NU: new Set([
'slurpuff', 'scrafty', 'haunter', 'linoone', 'chansey', 'indeedeef', 'porygon2', 'tauros',
'exeggutoralola', 'sneasel', 'snorlax', 'zygarde10', 'tyrantrum', 'kingdra',
]),
PU: new Set([
'arctozolt', 'arctovish', 'silvally', 'noctowl', 'silvallyground', 'silvallyfire',
'silvallyflying', 'silvallyfighting', 'scyther', 'magneton', 'porygon2', 'basculin',
'hitmontop', 'silvallypsychic', 'silvallyelectric', 'silvallygrass', 'rotomfrost', 'orbeetle',
'butterfree', 'golurk', 'flapple', 'thievul', 'sawk', 'galvantula', 'silvallydark', 'exeggutor',
'mesprit', 'guzzlord', 'magmortar', 'zygarde10', 'kingler', 'absol',
]),
ZU: new Set(['silvallyelectric', 'thwackey', 'ludicolo', 'musharna', 'grapploct', 'swoobat']),
};

function usageTiers<T>(
type: 'singles' | 'doubles' | 'nationaldex' | 'littlecup' = 'singles', t: T
): UsageTiers<T> | DoublesUsageTiers<T> | NationalDexUsageTiers<T> | LittleCupUsageTiers<T> {
Expand Down Expand Up @@ -535,32 +559,6 @@ function updateTiers(
return cosmeticFormes;
}).flat());

const getBL = (tier: Tier): Tier => {
switch (tier) {
case 'OU':
return 'Uber';
case 'UU':
return 'UUBL';
case 'RU':
return 'RUBL';
case 'NU':
return 'NUBL';
case 'PU':
return 'PUBL';
case 'ZU':
return 'ZUBL';
default:
// Tier is already a banlist (is a BL or Uber)
return tier;
}
};

const BL: {[tier in Tier]?: Set<ID>} = {};
(['UU', 'RU', 'NU', 'PU', 'ZU'] as Tier[]).forEach(tier => {
BL[tier] = new Set(Array.from(gen.species).filter(specie => specie.tier === getBL(tier))
.map(specie => specie.id));
});

for (const species of gen.species) {
if (SKIP.has(species.id) ||
species.isNonstandard ||
Expand Down

0 comments on commit a0dbf30

Please sign in to comment.