Commit Graph

3359 Commits

Author SHA1 Message Date
NightKev ef5e0d4c24
[Refactor] Code readability update (#3085)
* Clean up/clarify `src/field/pokemon.ts` a bit

Code provided by DerTapp on Discord

* Update `PokemonSpeciesForm.getAbilityCount()`

* Update `PokemonSpeciesForm.getAbility()`

* Add explicit `Abilities.NONE` checks

* Add tests

* Add jsdoc and implement test suggestions
2024-07-23 14:59:59 -04:00
AJ Fontaine 4a04ef50c3
[Balance] More TM fixes (#3081)
* More TM fixes

* Leaf Storm

* Removed sexy matcha
2024-07-23 17:08:27 +01:00
flx-sta 5cb1125bca
fix `Overrides` capitalization (#3111) 2024-07-23 17:07:32 +01:00
NightKev a0502fb0b5
[Refactor] Replaces the single and double battles overrides with a single override (#3104)
`SINGLE_BATTLE_OVERRIDE` and `DOUBLE_BATTLE_OVERRIDE` are now `BATTLE_TYPE`

Also updates all uses of the old overrides with the new one
2024-07-23 11:19:47 -04:00
Tempoanon 11c5c0a3d9
[Move] Aeroblast is a wind move (#3109)
* Hardcoded Pokemon should have proper names

* Aeroblast is a wind move
2024-07-23 11:17:32 -04:00
innerthunder 1d39f8d638
[Bug] Fix Thousand Arrows not hitting targets under the effects of Magnet Rise (#3100)
* Fix Thousand Arrows not hitting through Magnet Rise

* Add integration test for Thousand Arrows vs. Magnet Rise

* ESLint

* Remove unnecessary checks in integration tests
2024-07-23 10:19:48 -04:00
chaosgrimmon 630deb92e5
[Sprite] Mega Latis using opposite's eye colour (#3102)
* [Sprite] Mega Latis using opposite eyes

Taken from counterpart Lati

* [Sprite] Update Mega Latios eyes

* [Sprite] Update Mega Latias eyes

* [Sprite] Mega Latias duplicated palette value

Colour taken from non-exp Mega Latias
2024-07-23 10:16:21 -04:00
Adrian T. 799458c946
[Bug] Fix hustle not applying attack boost (#3101) 2024-07-23 10:15:58 -04:00
schmidtc1 e84649854d
[Bug] Enemy pokemon's Harvest creates berry icons on the player's side when triggered (#3077) 2024-07-22 20:42:55 -04:00
José Ricardo Fleury Oliveira d3c9392721
Localization(pt): Updated move.ts (#3078)
* Localization(pt): Updated move.ts and fixed King's Shield

* more fixes
2024-07-22 20:00:47 -04:00
NightKev 86ebd0c5e5
[Bug] Ability changing on evolution fix (#2995)
* Prevent Pokemon with their second ability from evolving into their HA

* Add check for fusions too
2024-07-22 19:57:30 -04:00
Opaque02 32d1b6b914
[QoL] Starter UI selection update to allow removing specific pokemon from party (#1983)
* Initial commits with logic to remove starters if they're in your party. Still need to make it work so that the starter selection cursor disappears when a starter is unselected

* Updated code to be able to remove pokemon, including the side icons and cursor locations

* Fixed popstarter to work with any index

* Updating code to allow navigation of starter icons

* Updating code to allow navigation of party starter icons

* Updaing navigation of party icons

* Updated logic to fix incorrect icon in top left of pokemon options when navigating the starter icons

* Updated logic to include the ability to navigate and interact with the starter icons

* Forgot to push the actual starter-select-ui-handler. Might be a bit hard to test things out without that :)

* Removed some unnecessary comments

* Fixed small bug with not being able to move from the far right to the gen selection when the starter icons were empty

* Updated code to not be using a method to generate the party menu and made it more like it used to be. This should help with merge conflicts in the future

* I committed the merged version but forgot to make the starter-select-ui-handler staged after making the changes

* Accidentally broke challenges that had a specific typing requirement with last commit. This should fix it

* Changed how navigation worked based on popular demand

* Fixed code review comments

* Accidentally left in a whole block of commented code. Intentionally removing it now

* Started adding logic for mono type challenge runs to not break the game if the user tries to start a run with an invalid party

* Updated the text to say the party is invalid

* Updated logic to make invalid pokemon greyed out when no valid pokemon are in your party

* Added comments on some code

* Updated locales to include the key for trying to start with invalid parties during a challenge

* Fixed some code from a bad merge where a challenge related param that was previously a number now needed to be a boolean and wasn't

* Removed comment as per review
2024-07-22 23:32:49 +01:00
Frederico Santos e2829f5225 fix: Update removeCookie function to use Max-Age=-1 instead of Expires header
The removeCookie function was updated to use the Max-Age=-1 attribute instead of setting the Expires header to a past date. This change ensures that the cookie is immediately expired when removed, preventing any potential login loops. Additionally, a legacy cookie without a domain was added to handle older cookies. This commit resolves the unnecessary cookie setting in the removeCookie function.
2024-07-22 22:41:51 +01:00
Frederico Santos b42fa558f8 fix: Remove unnecessary cookie setting in removeCookie function 2024-07-22 22:32:25 +01:00
Madmadness65 04819b88d6 Fix some broken images in item atlas & achievement
Fixed the broken sprites in the item atlas, and fixed the Baton Pass achievement to use the Baton item now (it was broken by the Leek being renamed). Also resized the Baton item image to 32*32, like all the other items.
2024-07-22 14:10:48 -05:00
Madmadness65 aba7132308 Re-add changes accidentally deleted by #2617 2024-07-22 13:55:03 -05:00
Mumble 3d2c2a14cc
[Visual] Achievement icons (#2617)
* Text Changes to MonoGen Challenges

* Item Texture Files

* MonoGen Ribbons added

* Resolving merge conflict

* Updated texture files? I think

* Changed image names and added new localizations for  syntax

* Removed unused ribbons

* [Feature] replace bug-report template with form (#2772)

* replace bug-report template with form

* update bug_report.yml

* add palceholders for data & session file

* Update item atlas

* Update item atlas again

This time, after merging main into the PR.

* [Sprite] Show Partner Eevee variants (#3097)

* [Sprite] Show Partner Eevee variants

Taken from non-partner Eevee

* [Sprite] Show Partner Eevee variants

Taken from non-partner Eevee

* [Sprite] Show Partner Eevee variants

* Merged with beta's new items

* Fixed typedoc issues

* Removing localizations

* Text Changes to MonoGen Challenges

* Item Texture Files

* MonoGen Ribbons added

* Resolving merge conflict

* Updated texture files? I think

* Changed image names and added new localizations for  syntax

* Removed unused ribbons

* Update item atlas

* [Feature] replace bug-report template with form (#2772)

* replace bug-report template with form

* update bug_report.yml

* add palceholders for data & session file

* Update item atlas again

This time, after merging main into the PR.

* Merged with beta's new items

* Fixed typedoc issues

* Removing localizations

* Allow Necrozma forms to play their special music (#3054)

* Allow Necrozma forms to play their special music (#3054)

* MonoGen Ribbons added

* Text Changes to MonoGen Challenges

* Item Texture Files

* MonoGen Ribbons added

* Updated texture files? I think

* Changed image names and added new localizations for  syntax

* Fixed typedoc issues

* Revert "Text Changes to MonoGen Challenges"

This reverts commit 3bf79acc6a.

* Text Changes to MonoGen Challenges

* Item Texture Files

* MonoGen Ribbons added

* Resolving merge conflict

* Updated texture files? I think

* Changed image names and added new localizations for  syntax

* Removed unused ribbons

* Update item atlas

* [Feature] replace bug-report template with form (#2772)

* replace bug-report template with form

* update bug_report.yml

* add palceholders for data & session file

* Update item atlas again

This time, after merging main into the PR.

* Merged with beta's new items

* Fixed typedoc issues

* Removing localizations

* Text Changes to MonoGen Challenges

* Item Texture Files

* MonoGen Ribbons added

* Resolving merge conflict

* Updated texture files? I think

* Changed image names and added new localizations for  syntax

* Removed unused ribbons

* Update item atlas

* Update item atlas again

This time, after merging main into the PR.

* Merged with beta's new items

* Fixed typedoc issues

* Removing localizations

* MonoGen Ribbons added

* Text Changes to MonoGen Challenges

* Item Texture Files

* MonoGen Ribbons added

* Updated texture files? I think

* Changed image names and added new localizations for  syntax

* Fixed typedoc issues

* Revert "Text Changes to MonoGen Challenges"

This reverts commit 3bf79acc6a.

* Please fix this.

* Revert "[Feature] replace bug-report template with form (#2772)"

This reverts commit aa69b10777.

---------

Co-authored-by: Frutescens <info@laptop>
Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>
Co-authored-by: Madmadness65 <blaze.the.fireman@gmail.com>
Co-authored-by: chaosgrimmon <31082757+chaosgrimmon@users.noreply.github.com>
Co-authored-by: Madmadness65 <59298170+Madmadness65@users.noreply.github.com>
2024-07-22 14:17:51 -04:00
Daniel Gaston 5006d0401e
[Bug] Sheer Force/Serene Grace Flyout Bugfix (#2496)
* Disable Show Ability for Serene Grace and Sheer Force when opponent calculates targetBenefitScore

* Add comment and definition to argument
2024-07-22 13:48:42 -04:00
DustinLin ccb38ca12b
[BUG] fixing multi-hit and move messages on faint (#2981)
* fixing order of messages, scences, to render messages before fainting

* updated fix for effectiveness text rendering order for multi hit moves

* fixing messages not appearing for multi-hit moves on faint

* updated multi-hit condition)

* fixing PR conflicts

* adding comments and FaintPhase setPhaseQueueSplice bug, fixing overrides merge conflict

* writing better comments

* removing space diff in overrides

* adding fainting check for self damage moves

* emergency fixing broken last commit

* additional comments for multi-hit problem

* updating comments, jsdoc style

* fixing linter, destiny bond errors

* splitting up varaible comments to be in JSDoc format

* fixing tests and merge mistakes

* adding rendering of multihit moves that only hit once

* fixing comment formatting_tabs and spaces

---------

Co-authored-by: Benjamin Odom <bennybroseph@gmail.com>
2024-07-22 13:44:29 -04:00
Madmadness65 d0cbe19bd8
Allow Necrozma forms to play their special music (#3054) 2024-07-22 12:35:11 -05:00
chaosgrimmon de0aacfcc7
[Sprite] Show Partner Eevee variants (#3097)
* [Sprite] Show Partner Eevee variants

Taken from non-partner Eevee

* [Sprite] Show Partner Eevee variants

Taken from non-partner Eevee

* [Sprite] Show Partner Eevee variants
2024-07-22 13:12:15 -04:00
sirzento 01de9b9b58
[Feature] Added pokemon nicknames/renaming (#2570)
* Added basic temp renaming

* Made nickname persistant after reloading

* Localization and cancel button

* Fixed instant rename on active pokemon

* Small bugfix to prevent console errors

* Changed logic to use the new nickname field. Replaced most .name with getNameToRender() for display.

* Changed evolution message. Removed log messagesc

* Added localization keys for other languages

* Removed empty lines

* French translation

Co-authored-by: Lugiad' <adrien.grivel@hotmail.fr>

* Chinese translation

Co-authored-by: Yonmaru40 <47717431+40chyan@users.noreply.github.com>

* Portuguese (Brazil) translation

Co-authored-by: José Ricardo Fleury Oliveira <josefleury@discente.ufg.br>

* Korean translation

Co-authored-by: Enoch <enoch.jwsong@gmail.com>

* Update menu.ts

* Update menu.ts [Localization(it)]

* Changed most .getNameToRender() instance to getPokemonNameWithAffix()

* Changed wild encounter messages back to just use the name without affix.

* Added localization for the party ui rename selection

* Escaping nickname characters to support all characters

* Better Error handling

* Update src/field/pokemon.ts

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

---------

Co-authored-by: Lugiad' <adrien.grivel@hotmail.fr>
Co-authored-by: Yonmaru40 <47717431+40chyan@users.noreply.github.com>
Co-authored-by: José Ricardo Fleury Oliveira <josefleury@discente.ufg.br>
Co-authored-by: Enoch <enoch.jwsong@gmail.com>
Co-authored-by: Niccolò <123510358+NicusPulcis@users.noreply.github.com>
Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>
2024-07-22 12:46:52 -04:00
schmidtc1 fc722bea7f
[Bug] Enemies can properly use stuff cheeks (#3090) 2024-07-22 12:01:59 -04:00
gjeodnd12165 21940e6426
[Bug] fix not changing moveset after add to starter #1932 (#2396) 2024-07-22 11:25:55 -04:00
NightKev b6266c6da1
[Move] Finish implementation of Glaive Rush (#2720)
* Finish implementation of Glaive Rush

* Fix test RNG

* Add code/test for Multi-Lens interaction

* Fix off-by-one error in test caused by rounding issues

* Update for code changes

* Fix BattlerTag name
2024-07-22 11:16:59 -04:00
AJ Fontaine 10413722c6
[Sprite] Fix a number of sprite issues including the Zubat line, Goldeen, Golett, Dudunsparce, H-Sneasel, Garchomp, Sylveon, Marshadow (#3069)
* Batfix, Goldeen, Chomp, Golett, genies

* Fix Dudunsparce using Reborn shiny backsprite for whatever reason

* Fix female Hisuian Sneasel missing variants

* Marshadow epic front and Zenith, Sylveon back

* Fix Zubat line back sprite inconsistencies

* Fix Noivern shiny back
2024-07-22 11:16:23 -04:00
Adrian T. f298ec3111
[Enhancement] Decouple move accuracy and accuracy multiplier calculation from phases.ts (#2899)
* refactor accuracy calc

* update doc

* move accuracy multiplier calculation outside phases

* update wonder skin unit test

* rename method

* add docs

* add unit tests

* address feedback

* rename method

* fix imports

* improve tests

* add test for ohko move accuracy
2024-07-22 11:14:42 -04:00
AJ Fontaine 4ad53024b4
Add remaining relearn moves (#2894) 2024-07-22 11:14:15 -04:00
schmidtc1 21f5595e06
[Bug] Fixes Encore bug with multi-target moves missing (#3060)
* Pushes move history even when multi target move misses

* Move pushMoveHistory out of Move Pending condition
2024-07-22 10:59:04 -04:00
NightKev ecbf7570b3
Make EXP boosting items stack additively and not multiplicatively (#3094)
Fixes #2040
2024-07-22 10:47:56 -04:00
NightKev cc6b424813
Prevent RNG from breaking the Quick Draw tests (#3096) 2024-07-22 10:32:31 -04:00
NightKev 50cf1c07a2
Fix broken `multi_target` tests and remove RNG-based failures (#3095) 2024-07-22 10:30:56 -04:00
서명인 (Myungin, SEO) cda74481de
[Localization] Add minor Korean translations to ability-trigger file (trace) (#3093)
* modify trace trigger description (refered from official translation)

modify trace trigger description (refered from official translation)

* modify trace trigger description (refered from official translation)

modify trace trigger description (refered from official translation)
2024-07-22 01:33:04 -04:00
Frederico Santos 5abf9ec190 feat: Delete duplicate cookies with the same name in getCookie function 2024-07-21 16:30:53 +01:00
Frederico Santos cf950313fc feat: Improve cookie handling in getCookie function 2024-07-21 16:08:51 +01:00
Frederico Santos 93bcf8ade9 fix: Remove unnecessary cookie setting in LoginPhase and MenuUiHandler 2024-07-21 15:55:42 +01:00
Frederico Santos 4c655691e5 feat: Add prompt=none to Discord OAuth authorization URL 2024-07-21 15:47:35 +01:00
Frederico Santos 22cd54c4f0 fix: update SameSite attribute in setCookie function to Strict 2024-07-21 15:25:38 +01:00
Frederico Santos 8d1a0660cb fix: update SameSite attribute in setCookie function to None 2024-07-21 14:48:42 +01:00
Amani H. a2edc214f0
[Refactor/Test] Update Dynamax Cannon Unit Tests (#3074)
* [Refactor/Test] Update Dynamax Cannon Unit Tests

* Adjust Test Names
2024-07-19 22:32:47 -04:00
AJ Fontaine 94b032ab1c
[Balance] Add 12 new TMs and remove 3 (#2733)
* Added Counter TM

* Counter, Aqua Tail, Gastro Acid, Pluck, Secret Power, Aurora Veil, Incinerate

* Placed TMs in proper order, added to pool

* Add Secret Power to the pool

* Add TM for Synthesis

* Covet, Heal Bell, PUPunch, Recycle, Volt Tackle, Worry Seed

* Remove species specific TMs

* Remove Secret Power TM until implementation
2024-07-20 02:16:19 +01:00
Dakurei be1f938d2c
[Music/BGM] New music added for the "Sea" biome, composed by Andr06 (#3063)
* Replacement of the BGM in the sea biome (by Andr06)

* Modification of BGM credits in README.md

* Replacement of the BGM name by the title chosen by its composer in all languages

* Update BGM loop point for biome 'SEA'
2024-07-19 00:51:10 -04:00
chaosgrimmon 6735dd7241
[Sprite] Mega Mewtwo sprite fixes (#3065)
* [Sprite] Add static epic Mega Mewtwo Y

Colours taken from exp, as consistent/exp rare backs share palettes.

* [Sprite] Fix transparent pixels on Mega Mewtwo X

* [Sprite] Fix transparent pixels on Mega Mewtwo X

* [Sprite] Add static epic Mega Mewtwo Y

Now exists, and is a paletteswap
2024-07-19 00:50:42 -04:00
chaosgrimmon 36cf0eacd0
[Sprite] Remove extra Oinkologne sprites (#3067)
* Delete public/images/pokemon/female/916.png

* Delete public/images/pokemon/exp/female/916.json

* Delete public/images/pokemon/exp/female/916.png

* Delete public/images/pokemon/female/916.json
2024-07-19 00:50:25 -04:00
DustinLin 37526c8356
[BUG] Uturn faint switch bug fix (#2980)
* reordering adding switch phases for u-turn

* reverting some temp changes

* generalizing function

* adding PR suggestions

* nit indenting
2024-07-19 00:03:57 +01:00
송영진 eb4604db26
[Bug] implemented multi target damage penalty (#2329)
* fix: damage multiplier by  the number of targets

* fix: used actual number value rather than the number holder

* test: added unit test for counting targets

* multi-target: fixed names of the unit tests.

* test: simple-test changes

* test: changed multi-target test code

* test: testing damage decreasement

* test: multi-target test fix

* resolved conflicts in test

---------

Co-authored-by: Tempoanon <163687446+Tempo-anon@users.noreply.github.com>
2024-07-18 16:49:00 -04:00
Dakurei 719764e2a4
[Music/BGM] New music added for the "Slum" biome, composed by Andr06 (#3000)
* Replacement of the BGM in the slum biome (by Andr06)

* Modification of BGM credits in README.md

* Replacement of the BGM name by the title chosen by its composer in all languages

* Update BGM loop point for biome 'SLUM'
2024-07-18 16:41:13 -04:00
Amani H. 99f4a9dd25
[Item] Add Scope Lens and Leek (#2666)
* [Item] Add Scope Lens and Leek

* Add Entry to pt_BR

* Localize for pt_BR

Co-authored-by: José Ricardo Fleury Oliveira <josefleury@discente.ufg.br>

* Fix & Clean Unit Tests

---------

Co-authored-by: José Ricardo Fleury Oliveira <josefleury@discente.ufg.br>
2024-07-18 10:20:55 -04:00
flx-sta dd693ae2d3
stop loading pride-update banner (#3057) 2024-07-17 19:20:59 -05:00
Dakurei 27b03aface
[Music/BGM] Fix bgm file & loop for battle_rival (#3053) 2024-07-17 16:32:38 -04:00