Commit Graph

4400 Commits

Author SHA1 Message Date
PigeonBar 2bc5f50154
[Test] Fix some test flakiness involving `doKillOpponents()` (#4571)
* [Test] Fix some test flakiness involving game.doKillOpponents()

* PR Feedback

* Fix linting

---------

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2024-10-04 10:42:20 -04:00
Adrian T. a5db2e1d6d
[Misc] Update readme to include relevant links (#4573) 2024-10-04 10:42:05 -04:00
EmberCM 38c682cca7
[QoL] Add fusion options to overrides (#4298)
* Add fusion options to overrides

* Add fusions overrides to overridesHelper

---------

Co-authored-by: MokaStitcher <54149968+MokaStitcher@users.noreply.github.com>
Co-authored-by: Adrian T. <68144167+torranx@users.noreply.github.com>
Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2024-10-03 23:04:50 -07:00
NightKev db1e50dfd7
add lint rules (#3769)
Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2024-10-03 22:16:15 -07:00
torranx 644c078a6c add new lint rules....again 2024-10-04 13:08:31 +08:00
Lneacx 74ea358f18
[Beta] Fix hit check so Poison-types do not brick semi-invuln. (#4567) 2024-10-03 23:45:53 -04:00
Acelynn Zhang 9c56c15a6c
[P3] Fix persisting sleep animation when sprite is already loaded (#4562)
Ensure that a Pokémon's animation speed is reset properly after saving
and quitting. Previously, if a Pokémon was put to sleep, which slows
its framerate, saving and quitting would result in the slower framerate
persisting even though the Pokémon was no longer asleep. This fix adds
an else condition to reset the frameRate to 12 if the sprite is already
loaded upon resuming the game.

Fixes #4465
2024-10-03 17:23:04 -04:00
Mumble af51c1f2f0
[Move] Unique message for heal block, taunt, torment, and imprison (#4530)
Co-authored-by: frutescens <info@laptop>
2024-10-03 14:56:35 -04:00
flx-sta 46c84155b3
[Beta P1] Fix rare candy crashing (#4561) 2024-10-03 14:53:35 -04:00
Adrian T. 76e25a6d6f
[Move] Update Tera Starstorm (still Partial), Readd Partial tag to Tera Blast (#4549)
* fully implement tera starstorm

* add docs

* add tests

* add override keyword

* account for fusion

* swap party positions

* add partial tag to tera blast

* address comments
2024-10-03 12:58:21 -04:00
schmidtc1 c58b5e943b
[P2] Fixes party status cure moves only curing the player's pokemon, even when used by enemy pokemon (#3369)
* Fixes bug with Status Cure moves only curing player pokemon, refactors PartyStatusCureAttr, removes PartyStatusCurePhase

* Adds check for user ID, since user always cures its own status regardless of ability

* Adds unit tests for sparkly swirl

* Merge and fix conflicts

* Fix conflicts with SPLASH_ONLY

* Fix failing sparkly swirl test due to splash_only

* Adds unit tests for heal bell and aromatherapy

* Update src/data/move.ts

---------

Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>
2024-10-03 11:49:33 -04:00
flx-sta 54efd44497
[Refactor] Modifiers type inference v2 (#4294)
* refactor: apply Modifiers type inference (pattern)

Mirror from #1747

Co-authored-by: Dmitriy <kagno.dmitriy@gmail.com>

* fix: PokemonBaseStatTotalModifier.apply having a `[1]` left

* fix: HeldItemTransferModifier.apply missing `...args: unknown[]`

* Replace relative imports with absolute imports in `modifier.ts`

* chore: fix TS1016* error

[*]  A required parameter cannot follow an optional parameter.

* chore: fix namings, types and docs

suggested by @torranx

* replace: `IntegerHolder` with `NumberHolder` & `integer` with `number`

* chore: apply review suggestions

by @torranx

* chore: address review feedback

from @torranx

* update: imports in `modifier-types`

* update `lapse` calls in modifier.ts

* fix lapse call in `battle-end-phase`

* minor adjustments in `modifier.ts`

* fix `EnemyEndureChanceModifier.apply` types

* fix `EnemyAttackStatusEffectChanceModifier.apply` types

* fix `EnemyTurnHealModifier.apply` types

* fix `EnemyStatusEffectHealChanceModifier.apply` types

---------

Co-authored-by: Dmitriy <kagno.dmitriy@gmail.com>
Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2024-10-03 11:38:17 -04:00
AJ Fontaine ea9e0c7909
[Move] Implement Scale Shot (#4551)
* Scale Shot

* Docstrings for StatStageChangeAttr

* Add test for scale shot
2024-10-03 11:17:51 -04:00
Lneacx 8fc0d9a429
[P2] Fix Toxic to bypass semi-invulnerability when used by a Poison-type. (#4445)
* Fix Toxic to bypass semi-invulnerability when used by a Poison-type.

* Apply suggestion to refactor BerryPhase in Toxic move tests.

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>

* Corrected missing quotes on a BerryPhase in Toxic.test.

---------

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2024-10-03 10:35:03 -04:00
Jannik Tappert 5f700590be
[QOL] Have Friendship Value be shown in summary (#4490)
* Have Friendship Value be shown in summary

* Fix how "fill" of icon is calced

* Update src/locales/de/pokemon-summary.json

* Actually add the images

* Add correct image files

* Update src/ui/summary-ui-handler.ts

Co-authored-by: Adrian T. <68144167+torranx@users.noreply.github.com>

* Update src/ui/summary-ui-handler.ts

Co-authored-by: Adrian T. <68144167+torranx@users.noreply.github.com>

* Update src/ui/summary-ui-handler.ts

* Update src/ui/summary-ui-handler.ts

Co-authored-by: MokaStitcher <54149968+MokaStitcher@users.noreply.github.com>

* Made changed suggested in code review

* Update src/locales/en/pokemon-summary.json

---------

Co-authored-by: Adrian T. <68144167+torranx@users.noreply.github.com>
Co-authored-by: MokaStitcher <54149968+MokaStitcher@users.noreply.github.com>
2024-10-03 10:34:29 -04:00
MokaStitcher 831efeb6bf
[P2] Make weather damage round down for consistency (#4559)
* fmake weather damage consistent with the rest of the game

* [test] add  some sandstorm and hail tests
2024-10-03 10:33:12 -04:00
NightKev f634b7c044
[Misc] Disable some leftover debug code (#4546)
* Disable i18n debug in `.env` files

* Disable leftover ME debug code
2024-10-02 13:13:16 -04:00
Adrian T. ea261a039d
[Refactor] Cleanup test boilerplate script (#4547) 2024-10-02 13:08:30 -04:00
AJ Fontaine 8a2900ad29
[Refactor] Move some relevant files, tables etc to new balance folder (#4510)
* Move biomes.ts

* Move starter costs, passives, friendship, starter-candy to starters.ts

* Change relative imports to absolute imports

* Add docstrings, passives.ts

* Constants in rates.ts for egg pity, egg tier rates, hatch waves, variant chances

---------

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>
2024-10-02 06:20:19 -07:00
innerthunder 7473c31c77
[P2] Fix Tera Shell to apply to all hits of multi-strike moves (#4541)
* Apply Tera Shell to all hits for multi-hit moves

* fix undefined property error

* ugh

* Remove obsolete bangs
2024-10-01 21:58:56 -04:00
NightKev a6bcd6eeea
[Refactor] Remove obsolete comments in egg gacha and starter select UIs (#4542) 2024-10-01 21:58:16 -04:00
Frederico Santos c46507d49b [Update] Update subproject commit reference in locales 2024-10-02 01:58:28 +01:00
Frederico Santos 5e151f5604
[Refactor] External locales (#4529)
* Removed local translation files

added translations submodule

[Enhancement] Add post-merge command to update submodules in lefthook configuration

[Enhancement] Add postinstall script to install lefthook after package installation

[Enhancement] Update postinstall script to run post-merge command after lefthook installation

* Add subproject commit for locales directory

* Remove translation team assignments from CODEOWNERS

* Add recursive submodule checkout to workflow files and update README for translations

* fix: run without locales present (#4539)

some code was hard-wired with  locales having to be present. This is no longer the case now

---------

Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>
2024-10-01 23:41:09 +01:00
flx-sta 95386861bb
[Qol][Refactor] i18n lazy-loading (#4327)
* move: locales files to `/public` (from `/src`)

* install: i18next-http-backend module

* implement: i18next language lazy-loading

* remove: all `config.ts` files (for locales)

* disable: enConfig import in i18next.d.ts

* remove: console.log from utils.camelCaseToKebabCase()

* remove localization tests

we don't need to test if i18next is working.
This is the job of i18next itself

* mock i18next for tests

* fix: tests that have to use the i18next key now

instead of the english translation

* fix: absolute-avarice-encounter test

* fix: loading mystery-encounter translations

with lazy-load

* fix: 2 mystery encounter translation loading

* replace: i18next mocks any vi.fn() calls

* fix: new namespace usage in ME tests

now using "mysteryEncounters/..."

* fix: delibirdy encounter not being language specific

the encounter was checking if the modifier name includes `Berry` which is only true for english. Instead it has to check if the modifier is an instance of BerryModifier

* fix: the-expert-pokemon-breeder

the new i18n pattern requires a different namespacing which has been adopted

* fix: GTS encounter tests

* add: `MockText.on()`

* fix: berries abound test

* chore: apply review suggestion

from @DayKev

* update i18next.d.ts

* chore: fix i18next.d.ts

* fix: `dialogue-misc` switchup between `en` and `ja`

* move: `SpeciesFormKey` into enum

there was an issue with circular dependencies

* replace: `#app/enums/` with `#enums/` for `SpeciesFormKey` imports

* re-sync locales from `beta`

* rename: `ca_ES` -> `ca-ES`

* rename: `pt_BR` -> `pt-BR`

* rename: `zh_CN` -> `zh-CN`

* rename: `zh_TW` -> `zh-TW`

* fix loading Species-Form-Key in poemon-evo.

* update: i18next `supporterLngs` ...

and remove `nonExplicitSupportedLngs`

* fix: `${namespace}.` -> `${namespace}:`

thanks @MokaStitcher
2024-10-01 21:55:16 +01:00
pom-eranian 160b730921
[Hotfix] Revert "[Sprite] 451 - Skorupi Animation Fix " (#4535) 2024-10-01 15:24:08 -04:00
DustinLin 45f6b23309
[P2] Chilly Reception's Snow is called during Enemy AI Move Selection (#4528)
* fixing weather check in getCondition()

* adding enemy tests
2024-09-30 23:23:29 -04:00
innerthunder 145b80f491
[P2] Fix Substitute blocking field effects (#4504)
Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2024-09-30 13:14:38 -04:00
NightKev 8a8adad7fe
[Refactor] Clean up some `TODO`s from the `strict-null` refactor (#4267) 2024-09-30 13:11:45 -04:00
NightKev e9ee2c1179
[Refactor] Remove unused parameters in move flag functions (#4516)
Also fix tsdocs for these functions
2024-09-30 13:10:00 -04:00
NightKev 5a20416fd4
[Refactor] Remove redundant session data function in game-over-phase (#4515) 2024-09-30 13:08:16 -04:00
Blitzy de9fdc5b9c
[Balance] Increase Minimum BST Filter for Elite 4 / Champion Teams (#4501)
* Increase Champion BST

* Slight E4 BST increase

* Update trainer-config.ts

* Move E4/Champion minimum BST values to consts

* Update tsdocs for new consts

---------

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2024-09-30 13:05:02 -04:00
José Ricardo d660c217b3
[Localization] Update pt_BR translations for menu, party, and settings (#4518) 2024-09-30 13:03:32 -04:00
Yonmaru40 814aceebc9
[Localization] Zh-cn fix 9-30 (#4517)
* Update modifier-type.json

* Update delibirdy-dialogue.json

* Update department-store-sale-dialogue.json

* Update global-trade-system-dialogue.json

* Update modifier-type.json

* Update party-ui-handler.json

* Update settings.json

* Update trash-to-treasure-dialogue.json

* Update uncommon-breed-dialogue.json

* Update training-session-dialogue.json

* Update egg.json

* Update battle.json

* Update dialogue.json
2024-09-30 13:03:13 -04:00
Lugiad bab5b31476
[Localization] Expert Breeder ME - Egg bug in locales (#4524)
* Update the-expert-pokemon-breeder-dialogue.json

* Update the-expert-pokemon-breeder-dialogue.json

* Update the-expert-pokemon-breeder-dialogue.json

* Update the-expert-pokemon-breeder-dialogue.json

* Update the-expert-pokemon-breeder-dialogue.json
2024-09-30 13:02:37 -04:00
NightKev 7d2df53c51
Add `waveTurnCount` to `PokemonBattleData` (#4168)
Swap `FirstMoveCondition` to use the new `waveTurnCount` field
2024-09-29 23:45:44 -07:00
NightKev 3d3460888a
Add scoring for the Glaive Rush `BattlerTag`s (#4514) 2024-09-29 23:04:32 -07:00
innerthunder 1bae87fa56
[Move] Fully Implement Plasma Fists (#4446)
* Implement Plasma Fists

* Update arena-tag.json

* Update arena-tag.json

* Update arena-tag.json

* Update arena-tag.json

* Update arena-tag.json

* Update arena-tag.json

* Update arena-tag.json

* Update arena-tag.json

* Update arena-tag.json

* Update arena-tag.json

---------

Co-authored-by: Lugiad <adrien.grivel@hotmail.fr>
2024-09-29 22:30:33 -04:00
dependabot[bot] d8ee8ad821
Bump vite from 5.3.5 to 5.4.8 (#4413)
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 5.3.5 to 5.4.8.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v5.4.8/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v5.4.8/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2024-09-29 22:04:31 -04:00
dependabot[bot] 79e172176d
Bump rollup from 4.18.1 to 4.22.4 (#4439)
Bumps [rollup](https://github.com/rollup/rollup) from 4.18.1 to 4.22.4.
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v4.18.1...v4.22.4)

---
updated-dependencies:
- dependency-name: rollup
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-29 22:03:09 -04:00
PrabbyDD d99dbf4955
[P2] Fix for Pokemon Forms have Access to Other Forms' TM Movepools (#4398)
* fixing form issues generating tms pokemon shouldnt have

* cleaning up some code

* fixing tests and allowing rotom unique moves to be learned as tms for that rotom form

* Update src/test/field/pokemon.test.ts

Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>

* making tests simpler

---------

Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>
2024-09-29 22:00:29 -04:00
Adrian T. 4c327e9e63
[Ability] Refactor Gulp Missile and make it trigger when Cramorant faints (#4428)
* reimplement gulp missile

* cleanup + docs

* more cleanup

* add override

* update paths
2024-09-29 21:57:50 -04:00
AJ Fontaine d620b5c7fa
[Refactor] Move base shiny/HA chance to constants outside functions (#4407) 2024-09-29 21:56:05 -04:00
Madmadness65 82111bc62d
[Enhancement] Gen 7+ grunts can now be in double battles (#4489) 2024-09-29 21:55:17 -04:00
innerthunder 7339facae1
[Ability] Remove (P) from Super Luck (#4498) 2024-09-29 21:54:49 -04:00
MokaStitcher 6d89ad9569
[P2] Fix duplicate mon ID / RNG not properly resetting after game over (#4505) 2024-09-29 21:52:13 -04:00
Mumble bcec819fa9
[Move] Fully Implement Syrup Bomb (#4441)
* Syrup Bomb + Tests

* Fix typo on import

* Documentation

* Apply suggestions from code review

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>

* Removed unnecessary overlap check

* Removed obsolete comment

* learned how forceHit works

* added custom lapse message

---------

Co-authored-by: frutescens <info@laptop>
Co-authored-by: Madmadness65 <59298170+Madmadness65@users.noreply.github.com>
Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2024-09-29 21:50:11 -04:00
innerthunder d0600125dd
[P2] Fix Zippy Zap being boosted by Sheer Force (#4469) 2024-09-29 21:49:37 -04:00
MokaStitcher fd67096a6a
[P3 Bug][UI] Fix egg summary not displaying 1st mon properly (#4507) 2024-09-29 21:48:29 -04:00
Chapybara-jp 2488bf805b
[Localization] [JA] Fixing typos in ability-trigger.json
* Update ability-trigger.json

* Update ability-trigger.json

---------

Co-authored-by: Lugiad <2070109+Adri1@users.noreply.github.com>
2024-09-29 21:46:54 -04:00
fransdhinta 4160aefd93
[Feature] Show app version on title screen (#4344)
* feat: show app version on title screen

* fix: adjust app version positions

* update app version text

---------

Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>
2024-09-29 18:18:52 -07:00