Commit Graph

1685 Commits

Author SHA1 Message Date
Guangcong Luo
78439b4a02
Update to ESLint 9 (#10926)
ESLint has a whole new config format, so I figure it's a good time to
make the config system saner.

- First, we no longer have separate eslint-no-types configs. Lint
  performance shouldn't be enough of a problem to justify the
  relevant maintenance complexity.

- Second, our base config should work out-of-the-box now. `npx eslint`
  will work as expected, without any CLI flags. You should still use
  `npm run lint` which adds the `--cached` flag for performance.

- Third, whatever updates I did fixed style linting, which apparently
  has been bugged for quite some time, considering all the obvious
  mixed-tabs-and-spaces issues I found in the upgrade.

Also here are some changes to our style rules. In particular:

- Curly brackets (for objects etc) now have spaces inside them. Sorry
  for the huge change. ESLint doesn't support our old style, and most
  projects use Prettier style, so we might as well match them in this way.
  See https://github.com/eslint-stylistic/eslint-stylistic/issues/415

- String + number concatenation is no longer allowed. We now
  consistently use template strings for this.
2025-02-25 20:03:46 -08:00
Guangcong Luo
deda1db857
Snowscape was incorrectly named Snow (#10920)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2025-02-19 21:34:55 -08:00
André Bastos Dias
6c57d481fe
Gen 7: Fix Snatch + Swallow interaction (#10916) 2025-02-18 20:55:50 -06:00
Yoshiblaze
ccd913169a
Little Colosseum: Add Eevee + Ability Renames (#10868)
* Little Colosseum: New Ability + Ability Renaming

* Little Colosseum: Ability Renaming Pt. 2

* Little Colosseum: Add Eevee

* Little Colosseum: Add Eevee Pt. 2
2025-02-12 14:25:51 -07:00
Kris Johnson
2050e9d812
Mix and Mega: Fix validation (again)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2025-02-12 00:14:26 -07:00
Kris Johnson
777178d402 Mix and Mega: Fix Mega Stones 2025-02-11 23:25:03 -07:00
André Bastos Dias
e11af8036b
Simplify Gen 5 Magic Bounce inheritance (#10880)
Some checks failed
Node.js CI / build (16.x) (push) Has been cancelled
2025-02-10 17:43:33 -06:00
André Bastos Dias
01645f6880
Disable Magic Bounce during semi-invulnerability (#10862) 2025-02-09 20:50:45 -06:00
HiZo
8994a46899
Mix and Mega: Don't free Z-Crystals (#10876) 2025-02-09 17:21:04 -07:00
missangelic
d516e024e9
ADV ZU: Implement VR update (#10875)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
https://www.smogon.com/forums/threads/adv-zu-metagame-discussion-vr-update-samples.3730430/#post-9839941
2025-02-09 11:32:17 -07:00
Leonard Craft III
ae3e1147ab Fix inheritance forColosseum Suicune event
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2025-02-07 18:42:56 -06:00
André Bastos Dias
ee08ffaae5
Fix interaction of Heal Bell and Good as Gold (#10863)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2025-02-06 22:26:24 -06:00
Kris Johnson
355f6b00f4 Mix and Mega: Fix some validation
Some checks failed
Node.js CI / build (16.x) (push) Has been cancelled
2025-02-03 23:38:17 -07:00
Kris Johnson
3281f6adb0
Mix and Mega: Expand usable items (#10865)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2025-02-03 19:18:22 -07:00
HiZo
f46a51a334
Partners in Crime: Don't activate innates while Neutralizing Gas is up (#10861)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
* Partners in Crime: Don't activate innates while Neutralizing Gas is up

* Actually return is unviable here
2025-02-03 10:58:35 -07:00
pyuk-bot
614d56b532
PiC: Don't activate abilities when a solo switch-in faints to hazards (#10857)
* PiC: Don't activate abilities when a solo switch-in faints to hazards

* Better namespacing

* Another nickel in the saveReplay jar

Co-authored-by: HiZo <96159984+HisuianZoroark@users.noreply.github.com>

---------

Co-authored-by: HiZo <96159984+HisuianZoroark@users.noreply.github.com>
2025-02-01 00:28:30 -07:00
larry-the-table-guy
b7521e5d7e
Data & Test: Fix several typos (#10845)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2025-01-29 08:18:52 -06:00
pyuk-bot
d286478fe0
OMs: Fix innate abilities and items when switching in (#10844) 2025-01-28 20:24:13 -06:00
pyuk-bot
7bb2fd1869
Overhaul 'SwitchIn' event for more accurate effect resolution order (#10766) 2025-01-28 16:51:17 -06:00
HiZo
d5c4fb5730
Remove Crazyhouse Rule (#10841)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
* Remove Crazyhouse

Causes too many problems/crashes when mashed up.

* lint
2025-01-27 17:50:29 -07:00
Kris Johnson
f79abcf51e SSB: Nerf yeet dab xd, buff Loethalion 2025-01-27 14:53:20 -07:00
André Bastos Dias
ce76114c12
Implement fainted forme regression (#10810) 2025-01-25 14:06:40 -06:00
André Bastos Dias
6d5970829a
Fix inherit for in-game mods (#10834) 2025-01-25 11:38:30 -07:00
larry-the-table-guy
912b540ed7
SSB: Fix typos in move descriptions (#10833)
* SSB: Fix typos in `moves.ts`

* SSB: Fix typos in `abilities.ts`
2025-01-25 11:37:27 -07:00
Dieter Reinert
a90e75acfc
SSB: Fix null reference error in 'Drifting' ability (#10824)
* SSB: Fix null reference error in 'Drifting' ability

Fixed a crash caused by a `TypeError` when the `defender` is `null` in the `Drifting` ability. Added necessary null checks in the `onModifyAtk` and `onModifySpA` methods to ensure `defender` is valid before accessing its properties.

**Stack Trace:**
```TS
A battle crashed: TypeError: Cannot read properties of null (reading 'activeTurns')
at Battle.onModifyAtk (/home/ps/main/data/mods/gen9ssb/abilities.ts:1725:18)
at Battle.runEvent (/home/ps/main/sim/battle.ts:845:34)
at Pokemon.getStat (/home/ps/main/sim/pokemon.ts:602:23)
at Battle.onModifyMove (/home/ps/main/data/mods/gen9ssb/moves.ts:6018:16)
at Battle.singleEvent (/home/ps/main/sim/battle.ts:585:25)
at BattleActions.useMoveInner (/home/ps/main/data/mods/gen9ssb/scripts.ts:1308:16)
at BattleActions.useMove (/home/ps/main/sim/battle-actions.ts:386:27)
at BattleActions.runMove (/home/ps/main/data/mods/gen9ssb/scripts.ts:1216:34)
at Battle.runAction (/home/ps/main/data/mods/gen9ssb/scripts.ts:443:17)
at Battle.turnLoop (/home/ps/main/sim/battle.ts:2802:9)
```

* put check on both modify events
2025-01-18 09:29:17 -07:00
shrianshChari
b368fcaa47
BW PU: Ban Swanna (#10828)
https://www.smogon.com/forums/threads/bw-pu-suspect-swanna.3757900/post-10406518
2025-01-18 09:28:26 -07:00
Yoshiblaze
fd8c5764da
GSC Doubles: Unban Celebi (#10831) 2025-01-18 09:27:40 -07:00
Mia
d3e60b31f7
Sim: Use a CSPRNG (#10806)
* Sim: Use a CSPRNG

* Add test

* fix test prng

* move prng test to others

* fix slight hack

* tf?

* Fuck this

* fucking lol

* fix crap

* i'm going to kill someone

* i hate state

* fix test

* Good work genius

* typo

* Fix exportinputlog

* Refactor for inputlog backwards compatibility

This is a pretty major refactor which is mostly unrelated to the
feature, but it does make the code a lot simpler.

* Readability pass

* Readability (again)

* Remove sodium-native dependency

* Refactor to serialize seeds in hex strings

(Also removes the Buffer dependency from PRNG, and slightly improves
comments.)

* Apparently << is 32-bit signed

* Readability

---------

Co-authored-by: Guangcong Luo <guangcongluo@gmail.com>
2025-01-11 13:56:34 -06:00
shrianshChari
d23498c164
BDSP: Update tiering for RU and NU Pokemon (#10816)
https://www.smogon.com/forums/threads/bdsp-nu-mesprit-ban-post-111.3697080/page-6#post-10400130
2025-01-11 12:36:22 -07:00
André Bastos Dias
639b930d91
Fix Protean / Embody Aspect + Neutralizing Gas interaction (#10805)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2025-01-10 14:34:53 -06:00
André Bastos Dias
2d9dc5d94f
Fix Protosynthesis + Cloud Nine interaction (#10804) 2025-01-10 00:31:04 -06:00
Alex "Mathy
11679e3cef
Gen 4: Fix Assist/Copycat/Metronome under Gravity/Heal Block (#10757)
* Gen 4: Fix Assist/Copycat/Metronome under Gravity/Heal Block

* Update data/mods/gen4/moves.ts

* Update data/mods/gen4/moves.ts

* Remove unnecessary checks

* prefer const

---------

Co-authored-by: Kris Johnson <11083252+KrisXV@users.noreply.github.com>
2025-01-04 13:17:12 -07:00
Kris Johnson
0a3b449284 DPP OU: Ban Machamp
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2025-01-03 11:02:54 -07:00
livid washed
e6a20f3414
Add January 2025 Randomized Format Spotlight (#10786)
* Add January 2025 Randomized Format Spotlight

* lint
2025-01-02 09:52:41 -07:00
Marty-D
e6b37fcd21
Gen 5 OU: Move Lucario out of OU by technicality
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
https://www.smogon.com/forums/posts/10387234/
2025-01-01 15:51:15 -05:00
Kris Johnson
faed539eb5 RBY NU-PU: Add 2025 tier shifts
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2024-12-29 20:43:27 -07:00
Kris Johnson
9d255d080a RBY ZU: Update even more tiering
Some checks failed
Node.js CI / build (16.x) (push) Has been cancelled
2024-12-17 12:03:42 -07:00
Kris Johnson
6adcea28d6 GSC ZU: Update tiering 2024-12-17 12:01:52 -07:00
Kris Johnson
6f0dd3fc82 ADV ZU: Update tiering 2024-12-17 11:57:21 -07:00
Kris Johnson
878a439114 RBY: Update PU/ZU after VR update 2024-12-17 11:49:53 -07:00
Kris Johnson
373c6fb594 RBY ZU: Unban Arbok 2024-12-17 11:44:13 -07:00
Kris Johnson
be7688483f Mix and Mega: Account for Primals too 2024-12-16 09:17:20 -07:00
Kris Johnson
2b597cd973 Mix and Mega: Fix bug with Crowned formes 2024-12-16 09:16:01 -07:00
Kris Johnson
7ae58f81d6 Mix and Mega: Fix exploit with Pokemon using their native mega stones
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2024-12-13 14:48:39 -07:00
HiZo
443339937f
Mix and Mega: Use decimeters to prevent rounding (#10750) 2024-12-13 09:19:53 -07:00
Cor'Jon
afc285628b
SSB: BreadStycks -> Breadey (#10749)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
2024-12-12 11:12:04 -07:00
Kris Johnson
2b03102954 Mix and Mega: Make Aggronite great again 2024-12-12 11:07:52 -07:00
adrivrie
890cd5c2d8
Gen 4: Fix Fling not working (#10742) 2024-12-07 17:31:01 -06:00
Caznovia
233a96b70f
Gen 4: Fix non-Multitype Arceus gain/loss of Plates interaction (#10734)
Some checks are pending
Node.js CI / build (16.x) (push) Waiting to run
* Gen 4: Fix Non-Multitype Arceus Gain/Loss of Plates Interaction

* Shortening plate function

* Fling fails when used by Multitype

* Fix Fling + Multitype interaction

* Apply suggestions from code review

* Apply suggestions from code review

---------

Co-authored-by: Kris Johnson <11083252+KrisXV@users.noreply.github.com>
2024-12-06 22:03:59 -07:00
HiZo
f27bf860d3
Twisted Dimension: Fix Trick Room interaction (#10725)
Some checks failed
Node.js CI / build (16.x) (push) Has been cancelled
* Twisted Dimension: fix Trick Room interaction

* Update scripts.ts

---------

Co-authored-by: Kris Johnson <11083252+KrisXV@users.noreply.github.com>
2024-12-04 14:29:38 -07:00