@pkmn/sim 0.7.42 → 0.7.43
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/cjs/config/formats.js +55 -13
- package/build/cjs/config/formats.js.map +1 -1
- package/build/cjs/data/abilities.js +4 -6
- package/build/cjs/data/abilities.js.map +1 -1
- package/build/cjs/data/formats-data.js +8 -8
- package/build/cjs/data/formats-data.js.map +1 -1
- package/build/cjs/data/moves.js +84 -62
- package/build/cjs/data/moves.js.map +1 -1
- package/build/cjs/sim/team-validator.js +3 -13
- package/build/cjs/sim/team-validator.js.map +1 -1
- package/build/esm/config/formats.mjs +55 -13
- package/build/esm/config/formats.mjs.map +1 -1
- package/build/esm/data/abilities.mjs +4 -6
- package/build/esm/data/abilities.mjs.map +1 -1
- package/build/esm/data/formats-data.mjs +8 -8
- package/build/esm/data/formats-data.mjs.map +1 -1
- package/build/esm/data/moves.mjs +84 -62
- package/build/esm/data/moves.mjs.map +1 -1
- package/build/esm/sim/team-validator.mjs +3 -13
- package/build/esm/sim/team-validator.mjs.map +1 -1
- package/package.json +1 -1
package/build/cjs/data/moves.js
CHANGED
|
@@ -2210,12 +2210,19 @@ exports.Moves = {
|
|
|
2210
2210
|
pp: 15,
|
|
2211
2211
|
priority: 0,
|
|
2212
2212
|
flags: { contact: 1, protect: 1, mirror: 1, slicing: 1 },
|
|
2213
|
-
|
|
2214
|
-
|
|
2213
|
+
onAfterHit(target, source, move) {
|
|
2214
|
+
if (!move.hasSheerForce && source.hp) {
|
|
2215
2215
|
for (const side of source.side.foeSidesWithConditions()) {
|
|
2216
2216
|
side.addSideCondition('spikes');
|
|
2217
2217
|
}
|
|
2218
|
-
}
|
|
2218
|
+
}
|
|
2219
|
+
},
|
|
2220
|
+
onAfterSubDamage(damage, target, source, move) {
|
|
2221
|
+
if (!move.hasSheerForce && source.hp) {
|
|
2222
|
+
for (const side of source.side.foeSidesWithConditions()) {
|
|
2223
|
+
side.addSideCondition('spikes');
|
|
2224
|
+
}
|
|
2225
|
+
}
|
|
2219
2226
|
},
|
|
2220
2227
|
secondary: {},
|
|
2221
2228
|
target: "normal",
|
|
@@ -12660,32 +12667,36 @@ exports.Moves = {
|
|
|
12660
12667
|
pp: 15,
|
|
12661
12668
|
priority: 0,
|
|
12662
12669
|
flags: { contact: 1, protect: 1, mirror: 1 },
|
|
12663
|
-
onAfterHit(target, pokemon) {
|
|
12664
|
-
if (
|
|
12665
|
-
|
|
12666
|
-
|
|
12667
|
-
|
|
12668
|
-
|
|
12669
|
-
|
|
12670
|
-
|
|
12670
|
+
onAfterHit(target, pokemon, move) {
|
|
12671
|
+
if (!move.hasSheerForce) {
|
|
12672
|
+
if (pokemon.hp && pokemon.removeVolatile('leechseed')) {
|
|
12673
|
+
this.add('-end', pokemon, 'Leech Seed', '[from] move: Mortal Spin', '[of] ' + pokemon);
|
|
12674
|
+
}
|
|
12675
|
+
const sideConditions = ['spikes', 'toxicspikes', 'stealthrock', 'stickyweb', 'gmaxsteelsurge'];
|
|
12676
|
+
for (const condition of sideConditions) {
|
|
12677
|
+
if (pokemon.hp && pokemon.side.removeSideCondition(condition)) {
|
|
12678
|
+
this.add('-sideend', pokemon.side, this.dex.conditions.get(condition).name, '[from] move: Mortal Spin', '[of] ' + pokemon);
|
|
12679
|
+
}
|
|
12680
|
+
}
|
|
12681
|
+
if (pokemon.hp && pokemon.volatiles['partiallytrapped']) {
|
|
12682
|
+
pokemon.removeVolatile('partiallytrapped');
|
|
12671
12683
|
}
|
|
12672
|
-
}
|
|
12673
|
-
if (pokemon.hp && pokemon.volatiles['partiallytrapped']) {
|
|
12674
|
-
pokemon.removeVolatile('partiallytrapped');
|
|
12675
12684
|
}
|
|
12676
12685
|
},
|
|
12677
|
-
onAfterSubDamage(damage, target, pokemon) {
|
|
12678
|
-
if (
|
|
12679
|
-
|
|
12680
|
-
|
|
12681
|
-
|
|
12682
|
-
|
|
12683
|
-
|
|
12684
|
-
|
|
12686
|
+
onAfterSubDamage(damage, target, pokemon, move) {
|
|
12687
|
+
if (!move.hasSheerForce) {
|
|
12688
|
+
if (pokemon.hp && pokemon.removeVolatile('leechseed')) {
|
|
12689
|
+
this.add('-end', pokemon, 'Leech Seed', '[from] move: Mortal Spin', '[of] ' + pokemon);
|
|
12690
|
+
}
|
|
12691
|
+
const sideConditions = ['spikes', 'toxicspikes', 'stealthrock', 'stickyweb', 'gmaxsteelsurge'];
|
|
12692
|
+
for (const condition of sideConditions) {
|
|
12693
|
+
if (pokemon.hp && pokemon.side.removeSideCondition(condition)) {
|
|
12694
|
+
this.add('-sideend', pokemon.side, this.dex.conditions.get(condition).name, '[from] move: Mortal Spin', '[of] ' + pokemon);
|
|
12695
|
+
}
|
|
12696
|
+
}
|
|
12697
|
+
if (pokemon.hp && pokemon.volatiles['partiallytrapped']) {
|
|
12698
|
+
pokemon.removeVolatile('partiallytrapped');
|
|
12685
12699
|
}
|
|
12686
|
-
}
|
|
12687
|
-
if (pokemon.hp && pokemon.volatiles['partiallytrapped']) {
|
|
12688
|
-
pokemon.removeVolatile('partiallytrapped');
|
|
12689
12700
|
}
|
|
12690
12701
|
},
|
|
12691
12702
|
secondary: {
|
|
@@ -14146,23 +14157,23 @@ exports.Moves = {
|
|
|
14146
14157
|
condition: {
|
|
14147
14158
|
onStart(pokemon) {
|
|
14148
14159
|
this.add('-start', pokemon, 'Power Shift');
|
|
14149
|
-
|
|
14150
|
-
|
|
14151
|
-
|
|
14152
|
-
|
|
14160
|
+
const newatk = pokemon.storedStats.def;
|
|
14161
|
+
const newdef = pokemon.storedStats.atk;
|
|
14162
|
+
pokemon.storedStats.atk = newatk;
|
|
14163
|
+
pokemon.storedStats.def = newdef;
|
|
14153
14164
|
},
|
|
14154
14165
|
onCopy(pokemon) {
|
|
14155
|
-
|
|
14156
|
-
|
|
14157
|
-
|
|
14158
|
-
|
|
14166
|
+
const newatk = pokemon.storedStats.def;
|
|
14167
|
+
const newdef = pokemon.storedStats.atk;
|
|
14168
|
+
pokemon.storedStats.atk = newatk;
|
|
14169
|
+
pokemon.storedStats.def = newdef;
|
|
14159
14170
|
},
|
|
14160
14171
|
onEnd(pokemon) {
|
|
14161
14172
|
this.add('-end', pokemon, 'Power Shift');
|
|
14162
|
-
|
|
14163
|
-
|
|
14164
|
-
|
|
14165
|
-
|
|
14173
|
+
const newatk = pokemon.storedStats.def;
|
|
14174
|
+
const newdef = pokemon.storedStats.atk;
|
|
14175
|
+
pokemon.storedStats.atk = newatk;
|
|
14176
|
+
pokemon.storedStats.def = newdef;
|
|
14166
14177
|
},
|
|
14167
14178
|
onRestart(pokemon) {
|
|
14168
14179
|
pokemon.removeVolatile('Power Shift');
|
|
@@ -15157,32 +15168,36 @@ exports.Moves = {
|
|
|
15157
15168
|
pp: 40,
|
|
15158
15169
|
priority: 0,
|
|
15159
15170
|
flags: { contact: 1, protect: 1, mirror: 1 },
|
|
15160
|
-
onAfterHit(target, pokemon) {
|
|
15161
|
-
if (
|
|
15162
|
-
|
|
15163
|
-
|
|
15164
|
-
|
|
15165
|
-
|
|
15166
|
-
|
|
15167
|
-
|
|
15171
|
+
onAfterHit(target, pokemon, move) {
|
|
15172
|
+
if (!move.hasSheerForce) {
|
|
15173
|
+
if (pokemon.hp && pokemon.removeVolatile('leechseed')) {
|
|
15174
|
+
this.add('-end', pokemon, 'Leech Seed', '[from] move: Rapid Spin', '[of] ' + pokemon);
|
|
15175
|
+
}
|
|
15176
|
+
const sideConditions = ['spikes', 'toxicspikes', 'stealthrock', 'stickyweb', 'gmaxsteelsurge'];
|
|
15177
|
+
for (const condition of sideConditions) {
|
|
15178
|
+
if (pokemon.hp && pokemon.side.removeSideCondition(condition)) {
|
|
15179
|
+
this.add('-sideend', pokemon.side, this.dex.conditions.get(condition).name, '[from] move: Rapid Spin', '[of] ' + pokemon);
|
|
15180
|
+
}
|
|
15181
|
+
}
|
|
15182
|
+
if (pokemon.hp && pokemon.volatiles['partiallytrapped']) {
|
|
15183
|
+
pokemon.removeVolatile('partiallytrapped');
|
|
15168
15184
|
}
|
|
15169
|
-
}
|
|
15170
|
-
if (pokemon.hp && pokemon.volatiles['partiallytrapped']) {
|
|
15171
|
-
pokemon.removeVolatile('partiallytrapped');
|
|
15172
15185
|
}
|
|
15173
15186
|
},
|
|
15174
|
-
onAfterSubDamage(damage, target, pokemon) {
|
|
15175
|
-
if (
|
|
15176
|
-
|
|
15177
|
-
|
|
15178
|
-
|
|
15179
|
-
|
|
15180
|
-
|
|
15181
|
-
|
|
15187
|
+
onAfterSubDamage(damage, target, pokemon, move) {
|
|
15188
|
+
if (!move.hasSheerForce) {
|
|
15189
|
+
if (pokemon.hp && pokemon.removeVolatile('leechseed')) {
|
|
15190
|
+
this.add('-end', pokemon, 'Leech Seed', '[from] move: Rapid Spin', '[of] ' + pokemon);
|
|
15191
|
+
}
|
|
15192
|
+
const sideConditions = ['spikes', 'toxicspikes', 'stealthrock', 'stickyweb', 'gmaxsteelsurge'];
|
|
15193
|
+
for (const condition of sideConditions) {
|
|
15194
|
+
if (pokemon.hp && pokemon.side.removeSideCondition(condition)) {
|
|
15195
|
+
this.add('-sideend', pokemon.side, this.dex.conditions.get(condition).name, '[from] move: Rapid Spin', '[of] ' + pokemon);
|
|
15196
|
+
}
|
|
15197
|
+
}
|
|
15198
|
+
if (pokemon.hp && pokemon.volatiles['partiallytrapped']) {
|
|
15199
|
+
pokemon.removeVolatile('partiallytrapped');
|
|
15182
15200
|
}
|
|
15183
|
-
}
|
|
15184
|
-
if (pokemon.hp && pokemon.volatiles['partiallytrapped']) {
|
|
15185
|
-
pokemon.removeVolatile('partiallytrapped');
|
|
15186
15201
|
}
|
|
15187
15202
|
},
|
|
15188
15203
|
secondary: {
|
|
@@ -18779,12 +18794,19 @@ exports.Moves = {
|
|
|
18779
18794
|
pp: 15,
|
|
18780
18795
|
priority: 0,
|
|
18781
18796
|
flags: { contact: 1, protect: 1, mirror: 1, slicing: 1 },
|
|
18782
|
-
|
|
18783
|
-
|
|
18797
|
+
onAfterHit(target, source, move) {
|
|
18798
|
+
if (!move.hasSheerForce && source.hp) {
|
|
18784
18799
|
for (const side of source.side.foeSidesWithConditions()) {
|
|
18785
18800
|
side.addSideCondition('stealthrock');
|
|
18786
18801
|
}
|
|
18787
|
-
}
|
|
18802
|
+
}
|
|
18803
|
+
},
|
|
18804
|
+
onAfterSubDamage(damage, target, source, move) {
|
|
18805
|
+
if (!move.hasSheerForce && source.hp) {
|
|
18806
|
+
for (const side of source.side.foeSidesWithConditions()) {
|
|
18807
|
+
side.addSideCondition('stealthrock');
|
|
18808
|
+
}
|
|
18809
|
+
}
|
|
18788
18810
|
},
|
|
18789
18811
|
secondary: {},
|
|
18790
18812
|
target: "normal",
|