@pkmn/sim 0.5.15 → 0.5.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/config/formats.js +39 -57
- package/build/config/formats.js.map +1 -1
- package/build/data/formats-data.js +1 -1
- package/build/data/formats-data.js.map +1 -1
- package/build/data/items.js +1 -3
- package/build/data/items.js.map +1 -1
- package/build/data/learnsets.js +2 -2
- package/build/data/learnsets.js.map +1 -1
- package/build/data/mods/gen1/formats-data.js +1 -1
- package/build/data/mods/gen1/formats-data.js.map +1 -1
- package/build/data/mods/gen1/moves.js +1 -4
- package/build/data/mods/gen1/moves.js.map +1 -1
- package/build/data/mods/gen2/moves.js +0 -3
- package/build/data/mods/gen2/moves.js.map +1 -1
- package/build/data/mods/gen3/moves.js +0 -10
- package/build/data/mods/gen3/moves.js.map +1 -1
- package/build/data/mods/gen3/scripts.js +2 -2
- package/build/data/mods/gen3/scripts.js.map +1 -1
- package/build/data/mods/gen4/moves.js +4 -5
- package/build/data/mods/gen4/moves.js.map +1 -1
- package/build/data/mods/gen4/rulesets.js +2 -1
- package/build/data/mods/gen4/rulesets.js.map +1 -1
- package/build/data/mods/gen5/rulesets.js +2 -1
- package/build/data/mods/gen5/rulesets.js.map +1 -1
- package/build/data/mods/gen7/formats-data.js +4 -4
- package/build/data/mods/gen7/formats-data.js.map +1 -1
- package/build/data/mods/gen7/rulesets.js +2 -1
- package/build/data/mods/gen7/rulesets.js.map +1 -1
- package/build/data/moves.js +59 -79
- package/build/data/moves.js.map +1 -1
- package/build/data/pokedex.js +2 -2
- package/build/data/pokedex.js.map +1 -1
- package/build/data/rulesets.js +3 -4
- package/build/data/rulesets.js.map +1 -1
- package/build/data/text/items.js +1 -0
- package/build/data/text/items.js.map +1 -1
- package/build/data/text/moves.js +5 -3
- package/build/data/text/moves.js.map +1 -1
- package/build/sim/battle-actions.js +12 -4
- package/build/sim/battle-actions.js.map +1 -1
- package/build/sim/battle.js +43 -5
- package/build/sim/battle.js.map +1 -1
- package/build/sim/dex-conditions.d.ts +1 -0
- package/build/sim/dex-conditions.js.map +1 -1
- package/build/sim/dex-moves.d.ts +1 -1
- package/build/sim/exported-global-types.d.ts +1 -0
- package/build/sim/global-types.d.ts +1 -0
- package/build/sim/team-validator.js +15 -4
- package/build/sim/team-validator.js.map +1 -1
- package/build/sim/tools/exhaustive-runner.d.ts +9 -0
- package/build/sim/tools/exhaustive-runner.js +18 -7
- package/build/sim/tools/exhaustive-runner.js.map +1 -1
- package/config/formats.ts +39 -57
- package/data/formats-data.ts +1 -1
- package/data/items.ts +1 -3
- package/data/learnsets.ts +2 -2
- package/data/mods/gen1/formats-data.ts +1 -1
- package/data/mods/gen1/moves.ts +1 -4
- package/data/mods/gen2/moves.ts +0 -3
- package/data/mods/gen3/moves.ts +0 -10
- package/data/mods/gen3/scripts.ts +3 -3
- package/data/mods/gen4/moves.ts +3 -5
- package/data/mods/gen4/rulesets.ts +2 -1
- package/data/mods/gen5/rulesets.ts +2 -1
- package/data/mods/gen7/formats-data.ts +4 -4
- package/data/mods/gen7/rulesets.ts +2 -1
- package/data/moves.ts +59 -70
- package/data/pokedex.ts +2 -2
- package/data/rulesets.ts +3 -6
- package/data/text/items.ts +2 -0
- package/data/text/moves.ts +6 -3
- package/package.json +1 -1
- package/sim/battle-actions.ts +16 -5
- package/sim/battle.ts +42 -5
- package/sim/dex-conditions.ts +1 -0
- package/sim/dex-moves.ts +1 -1
- package/sim/exported-global-types.ts +3 -0
- package/sim/global-types.ts +3 -0
- package/sim/team-validator.ts +16 -4
- package/sim/tools/exhaustive-runner.ts +30 -11
package/build/config/formats.js
CHANGED
|
@@ -236,7 +236,7 @@ exports.Formats = [
|
|
|
236
236
|
'Larvesta', 'Magby', 'Magnemite', 'Mareanie', 'Mienfoo', 'Mudbray', 'Munchlax', 'Natu', 'Onix', 'Pawniard',
|
|
237
237
|
'Ponyta', 'Ponyta-Galar', 'Porygon', 'Slowpoke-Base', 'Staryu', 'Timburr', 'Trapinch', 'Tyrunt',
|
|
238
238
|
// LC UUBL
|
|
239
|
-
'Farfetch\u2019d-Galar', 'Scorbunny', 'Shellder', 'Wingull',
|
|
239
|
+
'Archen', 'Farfetch\u2019d-Galar', 'Scorbunny', 'Shellder', 'Wingull',
|
|
240
240
|
],
|
|
241
241
|
},
|
|
242
242
|
{
|
|
@@ -330,7 +330,7 @@ exports.Formats = [
|
|
|
330
330
|
gameType: 'doubles',
|
|
331
331
|
searchShow: false,
|
|
332
332
|
ruleset: ['Standard Doubles', 'Little Cup', 'Dynamax Clause', 'Swagger Clause', 'Sleep Clause Mod'],
|
|
333
|
-
banlist: ['Corsola-Galar', 'Cutiefly', 'Ponyta-Base', 'Scyther', 'Sneasel', 'Swirlix', 'Tangela', 'Vulpix
|
|
333
|
+
banlist: ['Corsola-Galar', 'Cutiefly', 'Ponyta-Base', 'Scyther', 'Sneasel', 'Swirlix', 'Tangela', 'Vulpix-Base', 'Ally Switch'],
|
|
334
334
|
},
|
|
335
335
|
{
|
|
336
336
|
name: "[Gen 8] VGC 2022",
|
|
@@ -579,11 +579,12 @@ exports.Formats = [
|
|
|
579
579
|
ruleset: ['Standard', 'Crazyhouse Rule', 'Dynamax Clause', 'Sleep Moves Clause', 'Evasion Abilities Clause', '!Sleep Clause Mod'],
|
|
580
580
|
banlist: [
|
|
581
581
|
'Calyrex-Ice', 'Calyrex-Shadow', 'Cinderace', 'Darmanitan-Galar', 'Dialga', 'Dracovish', 'Eternatus', 'Genesect', 'Giratina',
|
|
582
|
-
'Giratina-Origin', 'Groudon', 'Ho-Oh', 'Kyogre', 'Kyurem-Black', 'Kyurem-White', 'Landorus-Base', 'Lugia',
|
|
583
|
-
'Marshadow', 'Mewtwo', 'Naganadel', 'Necrozma-Dawn-Wings', 'Necrozma-Dusk-Mane', 'Palkia', 'Pheromosa',
|
|
584
|
-
'Solgaleo', 'Spectrier', 'Urshifu-Base', 'Xerneas', 'Yveltal', 'Zacian', 'Zacian-Crowned', 'Zamazenta',
|
|
585
|
-
'Zekrom', 'Zygarde-Base', 'Arena Trap', 'Moody', 'Power Construct', 'Shadow Tag', 'Bright Powder',
|
|
586
|
-
'Baton Pass', 'Explosion', 'Final Gambit', '
|
|
582
|
+
'Giratina-Origin', 'Groudon', 'Hawlucha', 'Ho-Oh', 'Kyogre', 'Kyurem', 'Kyurem-Black', 'Kyurem-White', 'Landorus-Base', 'Lugia',
|
|
583
|
+
'Lunala', 'Magearna', 'Marshadow', 'Mewtwo', 'Naganadel', 'Necrozma-Dawn-Wings', 'Necrozma-Dusk-Mane', 'Palkia', 'Pheromosa',
|
|
584
|
+
'Rayquaza', 'Reshiram', 'Solgaleo', 'Spectrier', 'Urshifu-Base', 'Xerneas', 'Yveltal', 'Zacian', 'Zacian-Crowned', 'Zamazenta',
|
|
585
|
+
'Zamazenta-Crowned', 'Zekrom', 'Zygarde-Base', 'Arena Trap', 'Moody', 'Power Construct', 'Shadow Tag', 'Bright Powder',
|
|
586
|
+
'King\'s Rock', 'Lax Incense', 'Baton Pass', 'Explosion', 'Final Gambit', 'Healing Wish', 'Lunar Dance', 'Memento',
|
|
587
|
+
'Misty Explosion', 'Self-Destruct',
|
|
587
588
|
],
|
|
588
589
|
},
|
|
589
590
|
{
|
|
@@ -595,17 +596,18 @@ exports.Formats = [
|
|
|
595
596
|
mod: 'pokebilities',
|
|
596
597
|
ruleset: ['[Gen 8] Pokebilities', '!Obtainable Abilities', 'AAA Restricted Abilities', '2 Ability Clause', 'Sleep Moves Clause', '!Sleep Clause Mod'],
|
|
597
598
|
banlist: [
|
|
598
|
-
'Blacephalon', 'Buzzwole', 'Clefable', 'Dragapult', 'Dragonite', '
|
|
599
|
-
'
|
|
600
|
-
'
|
|
601
|
-
'Regenerator +
|
|
602
|
-
'
|
|
599
|
+
'Alakazam', 'Blacephalon', 'Buzzwole', 'Clefable', 'Dragapult', 'Dragonite', 'Gengar', 'Kartana', 'Keldeo', 'Kyurem', 'Melmetal', 'Mienshao',
|
|
600
|
+
'Noivern', 'Obstagoon', 'Perrserker', 'Rillaboom', 'Tapu Lele', 'Urshifu', 'Urshifu-Rapid-Strike', 'Victini', 'Weavile', 'Zamazenta-Crowned',
|
|
601
|
+
'Zapdos-Galar', 'Arena Trap', 'Moody', 'Shadow Tag', 'Wonder Guard', 'Chlorophyll + Desolate Land', 'Chlorophyll + Drought', 'Electric Surge + Surge Surfer',
|
|
602
|
+
'Regenerator + Emergency Exit', 'Regenerator + Multiscale', 'Regenerator + Shadow Shield', 'Regenerator + Wimp Out', 'Sand Rush + Sand Stream',
|
|
603
|
+
'Slush Rush + Snow Warning', 'Swift Swim + Drizzle', 'Swift Swim + Primordial Sea', 'Snow Cloak + Snow Warning', 'Sand Veil + Sand Stream',
|
|
604
|
+
'Regenerator > 2', 'Bright Powder', 'Lax Incense', 'Quick Claw',
|
|
603
605
|
],
|
|
604
|
-
unbanlist: ['Dracozolt'],
|
|
605
606
|
restricted: [
|
|
606
607
|
'Comatose', 'Contrary', 'Fluffy', 'Fur Coat', 'Gorilla Tactics', 'Huge Power', 'Ice Scales', 'Illusion', 'Imposter', 'Innards Out',
|
|
607
|
-
'Intrepid Sword', 'Libero', 'Neutralizing Gas', 'Parental Bond', 'Poison Heal', 'Prankster', 'Protean', 'Pure Power',
|
|
608
|
-
'Speed Boost', 'Tinted Lens', '
|
|
608
|
+
'Intrepid Sword', 'Libero', 'Magnet Pull', 'Neutralizing Gas', 'Parental Bond', 'Poison Heal', 'Prankster', 'Protean', 'Pure Power',
|
|
609
|
+
'Quick Draw', 'Sand Veil', 'Serene Grace', 'Simple', 'Snow Cloak', 'Speed Boost', 'Stakeout', 'Stench', 'Tinted Lens', 'Triage',
|
|
610
|
+
'Unburden', 'Water Bubble',
|
|
609
611
|
],
|
|
610
612
|
},
|
|
611
613
|
// Other Metagames
|
|
@@ -630,25 +632,6 @@ exports.Formats = [
|
|
|
630
632
|
'Water Bubble', 'Wonder Guard', 'Comatose + Sleep Talk', 'Rusted Sword', 'Court Change', 'Bolt Beak', 'Double Iron Bash',
|
|
631
633
|
'Octolock', 'Shell Smash',
|
|
632
634
|
],
|
|
633
|
-
onChangeSet(set) {
|
|
634
|
-
const item = this.dex.toID(set.item);
|
|
635
|
-
if (set.species === 'Zacian' && item === 'rustedsword') {
|
|
636
|
-
set.species = 'Zacian-Crowned';
|
|
637
|
-
set.ability = 'Intrepid Sword';
|
|
638
|
-
const ironHead = set.moves.indexOf('ironhead');
|
|
639
|
-
if (ironHead >= 0) {
|
|
640
|
-
set.moves[ironHead] = 'behemothblade';
|
|
641
|
-
}
|
|
642
|
-
}
|
|
643
|
-
if (set.species === 'Zamazenta' && item === 'rustedshield') {
|
|
644
|
-
set.species = 'Zamazenta-Crowned';
|
|
645
|
-
set.ability = 'Dauntless Shield';
|
|
646
|
-
const ironHead = set.moves.indexOf('ironhead');
|
|
647
|
-
if (ironHead >= 0) {
|
|
648
|
-
set.moves[ironHead] = 'behemothbash';
|
|
649
|
-
}
|
|
650
|
-
}
|
|
651
|
-
},
|
|
652
635
|
},
|
|
653
636
|
{
|
|
654
637
|
name: "[Gen 8] Almost Any Ability",
|
|
@@ -669,15 +652,6 @@ exports.Formats = [
|
|
|
669
652
|
'Innards Out', 'Intrepid Sword', 'Libero', 'Magnet Pull', 'Moody', 'Neutralizing Gas', 'Parental Bond', 'Poison Heal', 'Protean',
|
|
670
653
|
'Pure Power', 'Shadow Tag', 'Simple', 'Stakeout', 'Speed Boost', 'Water Bubble', 'Wonder Guard', 'King\'s Rock', 'Baton Pass',
|
|
671
654
|
],
|
|
672
|
-
onValidateSet(set) {
|
|
673
|
-
// Temporary fix until battle-only is implemented properly
|
|
674
|
-
if (this.toID(set.species) === 'zamazentacrowned' && this.toID(set.ability) !== 'dauntlessshield') {
|
|
675
|
-
return [`Zamazenta-Crowned can only use Dauntless Shield because it is a battle-only forme.`];
|
|
676
|
-
}
|
|
677
|
-
if (this.toID(set.species) === 'zaciancrowned' && this.toID(set.ability) !== 'intrepidsword') {
|
|
678
|
-
return [`Zacian-Crowned can only use Intrepid Sword because it is a battle-only forme.`];
|
|
679
|
-
}
|
|
680
|
-
},
|
|
681
655
|
},
|
|
682
656
|
{
|
|
683
657
|
name: "[Gen 8] Mix and Mega",
|
|
@@ -849,9 +823,6 @@ exports.Formats = [
|
|
|
849
823
|
const stat = Dex.stats.ids()[target.side.team.indexOf(target.set)];
|
|
850
824
|
const newSpecies = this.dex.deepClone(species);
|
|
851
825
|
let godSpecies = this.dex.species.get(god.species);
|
|
852
|
-
if (godSpecies.forme === 'Crowned') {
|
|
853
|
-
godSpecies = this.dex.species.get(godSpecies.changesFrom || godSpecies.baseSpecies);
|
|
854
|
-
}
|
|
855
826
|
if (typeof godSpecies.battleOnly === 'string') {
|
|
856
827
|
godSpecies = this.dex.species.get(godSpecies.battleOnly);
|
|
857
828
|
}
|
|
@@ -1722,6 +1693,17 @@ exports.Formats = [
|
|
|
1722
1693
|
}
|
|
1723
1694
|
}
|
|
1724
1695
|
},
|
|
1696
|
+
onSwitchOut(pokemon) {
|
|
1697
|
+
for (const innate of Object.keys(pokemon.volatiles).filter(i => i.startsWith('ability:'))) {
|
|
1698
|
+
pokemon.removeVolatile(innate);
|
|
1699
|
+
}
|
|
1700
|
+
},
|
|
1701
|
+
onFaint(pokemon) {
|
|
1702
|
+
for (const innate of Object.keys(pokemon.volatiles).filter(i => i.startsWith('ability:'))) {
|
|
1703
|
+
const innateEffect = this.dex.conditions.get(innate);
|
|
1704
|
+
this.singleEvent('End', innateEffect, null, pokemon);
|
|
1705
|
+
}
|
|
1706
|
+
},
|
|
1725
1707
|
onAfterMega(pokemon) {
|
|
1726
1708
|
for (const innate of Object.keys(pokemon.volatiles).filter(i => i.startsWith('ability:'))) {
|
|
1727
1709
|
pokemon.removeVolatile(innate);
|
|
@@ -2419,7 +2401,7 @@ exports.Formats = [
|
|
|
2419
2401
|
],
|
|
2420
2402
|
mod: 'gen3',
|
|
2421
2403
|
ruleset: ['Standard', 'One Boost Passer Clause'],
|
|
2422
|
-
banlist: ['Uber', 'Sand Veil', 'Soundproof', 'Assist', 'Baton Pass + Mean Look', 'Baton Pass + Spider Web', 'Smeargle + Ingrain'],
|
|
2404
|
+
banlist: ['Uber', 'Sand Veil', 'Soundproof', 'Assist', 'Baton Pass + Block', 'Baton Pass + Mean Look', 'Baton Pass + Spider Web', 'Smeargle + Ingrain'],
|
|
2423
2405
|
},
|
|
2424
2406
|
{
|
|
2425
2407
|
name: "[Gen 2] OU",
|
|
@@ -2558,7 +2540,7 @@ exports.Formats = [
|
|
|
2558
2540
|
name: "[Gen 6] Pure Hackmons",
|
|
2559
2541
|
desc: `Anything that can be hacked in-game and is usable in local battles is allowed.`,
|
|
2560
2542
|
threads: [
|
|
2561
|
-
`• <a href="https://www.smogon.com/forums/posts/
|
|
2543
|
+
`• <a href="https://www.smogon.com/forums/posts/9029427/">ORAS Pure Hackmons</a>`,
|
|
2562
2544
|
],
|
|
2563
2545
|
mod: 'gen6',
|
|
2564
2546
|
ruleset: ['-Nonexistent', 'Team Preview', 'HP Percentage Mod', 'Cancel Mod', 'Endless Battle Clause', 'EV limit = 510'],
|
|
@@ -2916,8 +2898,8 @@ exports.Formats = [
|
|
|
2916
2898
|
searchShow: false,
|
|
2917
2899
|
ruleset: ['Standard', 'Swagger Clause', 'Same Type Clause'],
|
|
2918
2900
|
banlist: [
|
|
2919
|
-
'Aegislash', 'Altaria-Mega', 'Arceus', 'Blaziken', 'Darkrai', 'Deoxys-Base', 'Deoxys-Attack', '
|
|
2920
|
-
'Giratina', 'Giratina-Origin', 'Greninja', 'Groudon', 'Ho-Oh', 'Hoopa-Unbound', 'Kangaskhan-Mega', 'Kyogre', 'Kyurem-White',
|
|
2901
|
+
'Aegislash', 'Altaria-Mega', 'Arceus', 'Blaziken', 'Darkrai', 'Deoxys-Base', 'Deoxys-Attack', 'Deoxys-Speed', 'Dialga', 'Genesect',
|
|
2902
|
+
'Gengar-Mega', 'Giratina', 'Giratina-Origin', 'Greninja', 'Groudon', 'Ho-Oh', 'Hoopa-Unbound', 'Kangaskhan-Mega', 'Kyogre', 'Kyurem-White',
|
|
2921
2903
|
'Lucario-Mega', 'Lugia', 'Mawile-Mega', 'Medicham-Mega', 'Metagross-Mega', 'Mewtwo', 'Palkia', 'Rayquaza', 'Reshiram', 'Sableye-Mega',
|
|
2922
2904
|
'Salamence-Mega', 'Shaymin-Sky', 'Slowbro-Mega', 'Talonflame', 'Xerneas', 'Yveltal', 'Zekrom',
|
|
2923
2905
|
'Shadow Tag', 'Bright Powder', 'Damp Rock', 'Focus Band', 'King\'s Rock', 'Lax Incense', 'Quick Claw', 'Razor Fang', 'Smooth Rock',
|
|
@@ -2940,8 +2922,8 @@ exports.Formats = [
|
|
|
2940
2922
|
banlist: [
|
|
2941
2923
|
'Arceus', 'Blaziken', 'Darkrai', 'Deoxys-Base', 'Deoxys-Attack', 'Deoxys-Defense', 'Dialga', 'Giratina',
|
|
2942
2924
|
'Giratina-Origin', 'Groudon', 'Ho-Oh', 'Kangaskhan-Mega', 'Kyogre', 'Kyurem-White', 'Lugia', 'Mewtwo',
|
|
2943
|
-
'Palkia', 'Rayquaza', 'Reshiram', 'Salamence-Mega', 'Shaymin-Sky', '
|
|
2944
|
-
'Focus Sash', 'Soul Dew', 'Grass Whistle', 'Hypnosis', 'Perish Song', 'Sing', 'Yawn',
|
|
2925
|
+
'Palkia', 'Rayquaza', 'Reshiram', 'Salamence-Mega', 'Shaymin-Sky', 'Snorlax', 'Xerneas', 'Yveltal',
|
|
2926
|
+
'Zekrom', 'Focus Sash', 'Soul Dew', 'Grass Whistle', 'Hypnosis', 'Perish Song', 'Sing', 'Yawn',
|
|
2945
2927
|
],
|
|
2946
2928
|
},
|
|
2947
2929
|
{
|
|
@@ -3377,11 +3359,11 @@ exports.Formats = [
|
|
|
3377
3359
|
searchShow: false,
|
|
3378
3360
|
ruleset: ['[Gen 4] PU'],
|
|
3379
3361
|
banlist: [
|
|
3380
|
-
'Ampharos', 'Armaldo', 'Bellossom', 'Dragonair', 'Gabite', 'Gastrodon', 'Glaceon', 'Glalie',
|
|
3381
|
-
'Gorebyss', 'Hippopotas', 'Kadabra', 'Machoke', 'Magmar', 'Mantine', 'Marowak', 'Metang',
|
|
3382
|
-
'Monferno', 'Mr. Mime', 'Muk', 'Murkrow', 'Pinsir', 'Politoed', 'Purugly', 'Quagsire',
|
|
3383
|
-
'Rampardos', 'Rapidash', 'Regigigas', 'Relicanth', 'Rhydon', 'Scyther', 'Sneasel', 'Snover',
|
|
3384
|
-
'Tangela', 'Torkoal', 'Victreebel', 'Xatu', 'Zangoose', 'Damp Rock',
|
|
3362
|
+
'Ampharos', 'Armaldo', 'Bellossom', 'Dragonair', 'Electabuzz', 'Gabite', 'Gastrodon', 'Glaceon', 'Glalie',
|
|
3363
|
+
'Golduck', 'Gorebyss', 'Hippopotas', 'Kadabra', 'Machoke', 'Magmar', 'Mantine', 'Marowak', 'Metang',
|
|
3364
|
+
'Misdreavus', 'Monferno', 'Mr. Mime', 'Muk', 'Murkrow', 'Pinsir', 'Politoed', 'Purugly', 'Quagsire',
|
|
3365
|
+
'Raichu', 'Rampardos', 'Rapidash', 'Regigigas', 'Relicanth', 'Rhydon', 'Scyther', 'Sneasel', 'Snover',
|
|
3366
|
+
'Solrock', 'Tangela', 'Torkoal', 'Victreebel', 'Xatu', 'Zangoose', 'Damp Rock',
|
|
3385
3367
|
],
|
|
3386
3368
|
},
|
|
3387
3369
|
{
|