Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.1.0 - The Halloween Update #4730

Merged
merged 169 commits into from
Oct 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
169 commits
Select commit Hold shift + click to select a range
000b8d9
Update .env.beta
patapancakes Sep 28, 2024
3976d11
Synchronize Beta with main hotfix #5
Tempo-anon Sep 29, 2024
b43620b
[Refactor] Optimize trick room ordering code (#4468)
KimJeongSun Sep 30, 2024
4160aef
[Feature] Show app version on title screen (#4344)
fransdhinta Sep 30, 2024
2488bf8
[Localization] [JA] Fixing typos in ability-trigger.json
Chapybara-jp Sep 30, 2024
fd67096
[P3 Bug][UI] Fix egg summary not displaying 1st mon properly (#4507)
MokaStitcher Sep 30, 2024
d060012
[P2] Fix Zippy Zap being boosted by Sheer Force (#4469)
innerthunder Sep 30, 2024
bcec819
[Move] Fully Implement Syrup Bomb (#4441)
frutescens Sep 30, 2024
6d89ad9
[P2] Fix duplicate mon ID / RNG not properly resetting after game ove…
MokaStitcher Sep 30, 2024
7339fac
[Ability] Remove (P) from Super Luck (#4498)
innerthunder Sep 30, 2024
82111bc
[Enhancement] Gen 7+ grunts can now be in double battles (#4489)
Madmadness65 Sep 30, 2024
d620b5c
[Refactor] Move base shiny/HA chance to constants outside functions (…
Fontbane Sep 30, 2024
4c327e9
[Ability] Refactor Gulp Missile and make it trigger when Cramorant fa…
torranx Sep 30, 2024
d99dbf4
[P2] Fix for Pokemon Forms have Access to Other Forms' TM Movepools (…
PrabbyDD Sep 30, 2024
79e1721
Bump rollup from 4.18.1 to 4.22.4 (#4439)
dependabot[bot] Sep 30, 2024
d8ee8ad
Bump vite from 5.3.5 to 5.4.8 (#4413)
dependabot[bot] Sep 30, 2024
1bae87f
[Move] Fully Implement Plasma Fists (#4446)
innerthunder Sep 30, 2024
3d34608
Add scoring for the Glaive Rush `BattlerTag`s (#4514)
DayKev Sep 30, 2024
7d2df53
Add `waveTurnCount` to `PokemonBattleData` (#4168)
DayKev Sep 30, 2024
bab5b31
[Localization] Expert Breeder ME - Egg bug in locales (#4524)
Adri1 Sep 30, 2024
814acee
[Localization] Zh-cn fix 9-30 (#4517)
40chyan Sep 30, 2024
d660c21
[Localization] Update pt_BR translations for menu, party, and setting…
josericardo-fo Sep 30, 2024
de9fdc5
[Balance] Increase Minimum BST Filter for Elite 4 / Champion Teams (#…
Blitz425 Sep 30, 2024
5a20416
[Refactor] Remove redundant session data function in game-over-phase …
DayKev Sep 30, 2024
e9ee2c1
[Refactor] Remove unused parameters in move flag functions (#4516)
DayKev Sep 30, 2024
8a8adad
[Refactor] Clean up some `TODO`s from the `strict-null` refactor (#4267)
DayKev Sep 30, 2024
145b80f
[P2] Fix Substitute blocking field effects (#4504)
innerthunder Sep 30, 2024
45f6b23
[P2] Chilly Reception's Snow is called during Enemy AI Move Selection…
DustinLin Oct 1, 2024
9538686
[Qol][Refactor] i18n lazy-loading (#4327)
flx-sta Oct 1, 2024
5e151f5
[Refactor] External locales (#4529)
f-fsantos Oct 1, 2024
c46507d
[Update] Update subproject commit reference in locales
f-fsantos Oct 2, 2024
a6bcd6e
[Refactor] Remove obsolete comments in egg gacha and starter select U…
DayKev Oct 2, 2024
7473c31
[P2] Fix Tera Shell to apply to all hits of multi-strike moves (#4541)
innerthunder Oct 2, 2024
8a2900a
[Refactor] Move some relevant files, tables etc to new balance folder…
Fontbane Oct 2, 2024
ea261a0
[Refactor] Cleanup test boilerplate script (#4547)
torranx Oct 2, 2024
f634b7c
[Misc] Disable some leftover debug code (#4546)
DayKev Oct 2, 2024
831efeb
[P2] Make weather damage round down for consistency (#4559)
MokaStitcher Oct 3, 2024
5f70059
[QOL] Have Friendship Value be shown in summary (#4490)
CodeTappert Oct 3, 2024
8fc0d9a
[P2] Fix Toxic to bypass semi-invulnerability when used by a Poison-t…
Lneacx Oct 3, 2024
ea9e0c7
[Move] Implement Scale Shot (#4551)
Fontbane Oct 3, 2024
54efd44
[Refactor] Modifiers type inference v2 (#4294)
flx-sta Oct 3, 2024
c58b5e9
[P2] Fixes party status cure moves only curing the player's pokemon, …
schmidtc1 Oct 3, 2024
76e25a6
[Move] Update Tera Starstorm (still Partial), Readd Partial tag to Te…
torranx Oct 3, 2024
46c8415
[Beta P1] Fix rare candy crashing (#4561)
flx-sta Oct 3, 2024
af51c1f
[Move] Unique message for heal block, taunt, torment, and imprison (#…
frutescens Oct 3, 2024
9c56c15
[P3] Fix persisting sleep animation when sprite is already loaded (#4…
acelynnzhang Oct 3, 2024
74ea358
[Beta] Fix hit check so Poison-types do not brick semi-invuln. (#4567)
Lneacx Oct 4, 2024
644c078
add new lint rules....again
torranx Oct 4, 2024
db1e50d
add lint rules (#3769)
DayKev Oct 4, 2024
38c682c
[QoL] Add fusion options to overrides (#4298)
EmberCM Oct 4, 2024
a5db2e1
[Misc] Update readme to include relevant links (#4573)
torranx Oct 4, 2024
2bc5f50
[Test] Fix some test flakiness involving `doKillOpponents()` (#4571)
PigeonBar Oct 4, 2024
22442d3
[Refactor] Refactor move phase and add documentation (#3974)
DayKev Oct 4, 2024
2c97b2b
[Sprite] Fix variant Farigiraf icon names (#4572)
chaosgrimmon Oct 4, 2024
75bd730
[Balance] Fix TM compatibility on forms, Tera Blast on Indigo Disk mo…
Fontbane Oct 4, 2024
0bd4d6c
[Move] Fully Implement the Pledge Moves (#4511)
innerthunder Oct 4, 2024
2753728
[Move] Implement Electrify (#4569)
innerthunder Oct 4, 2024
d362456
[P2] Diamond Storm should only trigger once when hitting multiple pok…
DayKev Oct 4, 2024
1947472
[P3] Fix start button cursor not being cleared properly in starter se…
MokaStitcher Oct 4, 2024
c99df97
[Move] Implement Ion Deluge (#4579)
innerthunder Oct 4, 2024
f562a76
Make repeat abilities not stack (#4588)
Xavion3 Oct 5, 2024
42b75e8
[Qol] Make i18n money formatter controlled by translators (#4550)
flx-sta Oct 5, 2024
e8f40c1
[Test] Update `create-test` script for linting changes (#4587)
DayKev Oct 5, 2024
f629a3e
[P2] Stop G-Max Pokemon from evolving (#4581)
innerthunder Oct 5, 2024
c2c41d9
Update subproject commit reference for locales
f-fsantos Oct 6, 2024
f9691b8
Change deploy script to specify "main" instead of `default_branch` (#…
DayKev Oct 6, 2024
a7157bb
fix shop option cursor indexing (#4601)
ben-lear Oct 6, 2024
1226ab3
[Sprite] Compress Bronzor animation (#4593)
chaosgrimmon Oct 6, 2024
c01fff4
[Beta P1] Fix regression in Metal Burst caused by #3974 (#4589)
DayKev Oct 6, 2024
a259ccf
[Beta][Test] Fix Scale Shot flaky test (#4564)
Fontbane Oct 7, 2024
f5fa478
[P1] Fix crash when starting a challenge run after revisiting challen…
acelynnzhang Oct 7, 2024
a1ca7e6
[Move] Triple Arrows effect chance for stat change is now 50% (#4543)
DayKev Oct 8, 2024
9bb6398
[Sprite] Fix stray pixels in Kirlia's animation (#4612)
chaosgrimmon Oct 8, 2024
6e10f66
[P2] Fix damage achievements not awarding (#4613)
MokaStitcher Oct 8, 2024
0ede7b0
[P3][UI] Fix egg gacha overlay not getting cleared properly (#4600)
MokaStitcher Oct 8, 2024
57a9678
[Offline P1] Fix wrong local save being deleted when creating a new r…
MokaStitcher Oct 8, 2024
39cebb7
[Bug] i18n messages files fix (#4611)
flx-sta Oct 8, 2024
d8c914c
[Beta P3] Fix i18n namespaces map for `mysteryEncounterMessages` from…
flx-sta Oct 8, 2024
deb2035
[Beta][P2] Fix Grip Claw (#4614)
MokaStitcher Oct 9, 2024
d2c579c
[P2] Prevent generating Pokemon with duplicate IDs in daily runs (#4623)
MokaStitcher Oct 9, 2024
ffe941d
[Feature][UI] Save Preview (#4410)
frutescens Oct 9, 2024
f180b60
[Qol] Load i18n en locales during tests (#4553)
flx-sta Oct 9, 2024
ca3cc3c
[P1 Bug] Fix infinite recursion from abilities disabled by Sheer Forc…
PigeonBar Oct 10, 2024
52257de
[P3] Fix enemy used PP flyout, fixes #4622 (#4629)
DayKev Oct 10, 2024
e9906ea
[P2] Obstruct/Kings Shield/etc no longer reduce stats through Clear B…
frutescens Oct 10, 2024
51894d4
[P2] Pollen Puff ally behavior fixed (#4615)
frutescens Oct 10, 2024
64147e4
[P2] Fix Battle Bond continuing to affect Water Shuriken after Grenin…
PigeonBar Oct 10, 2024
a778537
[P2] Sketch Failure Bug involving multiple Sketch-s in a moveset (#4618)
frutescens Oct 10, 2024
ba7e261
[Bug] Fix substitute interactions with `PostDefendAbAttr`s (#4570)
DayKev Oct 10, 2024
0996789
[Refactor] Improve typing in `phaseInterceptor.ts` (#4560)
torranx Oct 10, 2024
6ad5ba9
[Enhancement] Refactor Starter Species to use separate EggTier map (#…
ben-lear Oct 10, 2024
5d0b361
[P2] Syrup Bomb effect is removed when user leaves the field (#4606)
DayKev Oct 10, 2024
3f63c14
[P3] Fix "Stat Won't Go Any Lower/Higher" Not Appearing (#4635)
xsn34kzx Oct 10, 2024
407cd65
[Misc] Enemy item override will now apply to all enemies (#4620)
DayKev Oct 11, 2024
80a784a
[P3 Beta][UI] Fix loading behavior introduced with save preview (#4633)
MokaStitcher Oct 11, 2024
4f45633
[UI] Remove score display in voucher menu (#4616)
MokaStitcher Oct 11, 2024
70b9a43
[P2] Fix first-turn status damage and arena hazards (#3528)
ElizaAlex Oct 11, 2024
89d7e7e
[P3][UI] Fix tooltip bugs in Starter Select screen (#4641)
MokaStitcher Oct 11, 2024
f0cc1fc
[Sprite] Hisui Goodra, Sliggoo, Shiftry (#4642)
Oct 11, 2024
7645d50
[P3] Fix "falsex" type hint for Sheer Cold against ice types (#4638)
innerthunder Oct 11, 2024
cfb92b4
[Move] Telekinesis + [Bug] Ingrain (#4506)
frutescens Oct 11, 2024
b7eb95b
[Test] Fix several flaky tests (#4639)
PigeonBar Oct 12, 2024
2ac688d
[Misc] More complete phase logging (#4651)
PigeonBar Oct 12, 2024
ebb7612
[Bug] Stat Stages are now changed individually instead of all at once…
PrabbyDD Oct 12, 2024
caf29e2
[Documentation] Document all (P) moves (#4650)
Tempo-anon Oct 13, 2024
8e7aea0
Fixed Charizard and Kingler BST, fixed ability indexing for gmax form…
damocleas Oct 13, 2024
391f38c
[Documentation] Document all (P) abilities (#4649)
Tempo-anon Oct 13, 2024
470f9e4
[P3] Fix Substitute visual error on wave transition (#4648)
innerthunder Oct 13, 2024
8a355d5
[Bug] Move Restriction Battler Tag bugs (#4536)
frutescens Oct 13, 2024
e340abe
[P1 Bug] Fix softlock when a phazing attack activates a reviver seed …
PigeonBar Oct 14, 2024
8981f0e
Trainer party de-duplication checks static pokemon too (#4585)
frutescens Oct 14, 2024
676322e
[QOL] Add input delay for skipping egg summary (#4644)
MokaStitcher Oct 14, 2024
e7a4d40
[Move] Implement Power Trick (#2658)
ysh4296 Oct 14, 2024
e962ac1
[Beta Bug] Prevent duplicate move failure message (#4662)
DayKev Oct 14, 2024
bb98bc2
[Balance] Evil Team Update / Penny Adjustments (#4577)
Blitz425 Oct 15, 2024
d5f87bb
[P3][Beta] Fix missing move text when a move fails (#4664)
innerthunder Oct 15, 2024
21b7159
[P2] Attacks that miss against pokemon in semi invul state that have …
PrabbyDD Oct 15, 2024
d01d856
[Refactor] Default case to display challenge name (#4656)
frutescens Oct 15, 2024
1966335
[Refactor] Add type inference and support for simulated calls to `Are…
innerthunder Oct 15, 2024
c04d81b
[Ability] Allow Power Construct to transform 10% PC Zygardes (#4626)
Madmadness65 Oct 15, 2024
093f3d9
[Balance] Add Memory Mushroom to Shop (#4555)
innerthunder Oct 16, 2024
50ff6e7
[P1 Bug] Fix several Destiny Bond crashes (#4665)
PigeonBar Oct 16, 2024
c6ec019
[Bug] Fix for Expert Breeder's Pokemon being invisible and IV scanner…
PigeonBar Oct 16, 2024
2caa09f
[Move] Fully Implement Secret Power (#4647)
frutescens Oct 16, 2024
72c08e5
[Refactor] Clean up commented safari zone code from #4661 (#4671)
PigeonBar Oct 16, 2024
1907824
[P1] Fix party UI crash from unsanitized `lastCursor` pointing to emp…
PigeonBar Oct 16, 2024
3ea4597
[Localization] [UI/UX] Italian Type and Status icons (#4673)
Adri1 Oct 16, 2024
d5fee37
[Refactor] Add friendship related constants (#4657)
Fontbane Oct 16, 2024
d92d63e
[Misc] Restore info comment that was accidentally removed (#4674)
DayKev Oct 16, 2024
afebecd
[P2 Bug] Fix pool entry for Jynx not using baby species (#4675)
Madmadness65 Oct 16, 2024
85b8ca6
[Dev] Bump Game Version, Overhaul Version Migration (#4388)
xsn34kzx Oct 16, 2024
2f212f5
fixed effectChanceOVerrride location + removed ability tags (#4677)
frutescens Oct 17, 2024
c5b3220
[Beta P3][UI] Fix item/cursor placement in reward screen (#4678)
MokaStitcher Oct 17, 2024
de64fd7
[Misc] [Beta] Fix crash when loading save preview with Mystery Encoun…
PigeonBar Oct 18, 2024
5c70ab2
Merge pull request #4684 from pagefaultgames/main
f-fsantos Oct 18, 2024
39abac6
Add eslint rule to enforce indenting of `case` statements (#4692)
DayKev Oct 20, 2024
e6c06d5
[P All][Bug] Various ME bugfixes (copy) (#4695)
MokaStitcher Oct 20, 2024
75a114a
[Localization][UI/UX] emerald-pro font update (#4697)
Adri1 Oct 21, 2024
b76e54f
Replace duplicate code with `getDoubleBattleChance()` (#4690)
DayKev Oct 21, 2024
f518144
[P3] Fix mistimed sound effect in `LearnMovePhase` (#4698)
innerthunder Oct 21, 2024
966b07f
[Misc] Shiny overrides can now force Pokemon to not be shiny (#4699)
DayKev Oct 21, 2024
f779760
[P2] Fix oversight where hazards cannnot affect Pokemon that set it (…
DayKev Oct 21, 2024
467841d
[P2] Nightmare triggers at turn end instead of after move (#4702)
PrabbyDD Oct 22, 2024
c2eb9de
[Ability] Partially Implement Infiltrator (does not work with mist) (…
innerthunder Oct 22, 2024
7066a15
[Refactor] Added `BattlerTagLapseType.AFTER_HIT` (#3655)
ElizaAlex Oct 22, 2024
181f598
[P2] Fix Early Bird (#4632)
DayKev Oct 22, 2024
5e7f204
[UI][QoL] Cursor defaults to Fight at the start of each new wave (#4666)
frutescens Oct 22, 2024
96e5f2d
Starmobile Stat Adjustments (#4704)
damocleas Oct 23, 2024
0fe57b4
[Balance] Add Exclusive Moves from Prior Evolutions via Memory Mushro…
Blitz425 Oct 23, 2024
1ad4f3b
[Test] Add `STATUS_ACTIVATION_OVERRIDE` to `overrides.ts` (#4689)
DayKev Oct 23, 2024
a0baf89
[P2] Fix dark deal reducing transformed Pokemon's held item stack to …
bjparker1226 Oct 23, 2024
16b7194
[P3] Fix Egg Summary not showing new abilities in blue (#4712)
MokaStitcher Oct 23, 2024
03025b2
[P2] Fix various charge move bugs (#4595)
innerthunder Oct 23, 2024
fd38ab4
[P2] Missing Minior form (violet) now spawns in the wild (#4711)
DayKev Oct 23, 2024
958d791
[P2] Fixes Transform/Imposter not updating type/battle stat changes i…
schmidtc1 Oct 23, 2024
c7e9eaf
[P2] Fix binding, etc. not being removed when switching with Baton Pa…
innerthunder Oct 23, 2024
a13550e
[Balance][ME] Various ME Balance changes (#4700)
MokaStitcher Oct 23, 2024
a2419c4
[Misc] Add admin for (un)linking 3rd party accounts (#4198)
Opaque02 Oct 23, 2024
414e0a5
[Balance] Change Tyrogue to move-based evolutions (#4694)
innerthunder Oct 24, 2024
a50763c
updating locales
f-fsantos Oct 25, 2024
6418f46
[Sprite] Fix transparency of pixels on Fletchinder (#4720)
chaosgrimmon Oct 25, 2024
f87ac11
[Beta] Stop Transform giving copied moves negative fractional `ppUp` …
PigeonBar Oct 25, 2024
61cf937
[Balance] Ferroseed HA
Smewkie Oct 25, 2024
51b2a4d
Something (#4728)
f-fsantos Oct 26, 2024
3936238
[Sprite] October Variant Update (#4608)
Oct 26, 2024
4be0214
[fix] added missing rare icons for spinarak, ariados. added to icon s…
Oct 26, 2024
6119356
Updated date
f-fsantos Oct 26, 2024
4fb1f37
[Sprite] Fix Berry Juice item sprite
Madmadness65 Oct 26, 2024
22865c0
fix oversight with save migration (#4731)
MokaStitcher Oct 26, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 2 additions & 2 deletions .env.beta
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
VITE_BYPASS_LOGIN=0
VITE_BYPASS_TUTORIAL=0
VITE_SERVER_URL=https://api.beta.pokerogue.net
VITE_SERVER_URL=https://apibeta.pokerogue.net
VITE_DISCORD_CLIENT_ID=1248062921129459756
VITE_GOOGLE_CLIENT_ID=955345393540-2k6lfftf0fdnb0krqmpthjnqavfvvf73.apps.googleusercontent.com
VITE_I18N_DEBUG=1
VITE_I18N_DEBUG=0
2 changes: 1 addition & 1 deletion .env.development
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ VITE_BYPASS_TUTORIAL=0
VITE_SERVER_URL=http://localhost:8001
VITE_DISCORD_CLIENT_ID=1234567890
VITE_GOOGLE_CLIENT_ID=1234567890
VITE_I18N_DEBUG=1
VITE_I18N_DEBUG=0
VITE_PORT=8000
38 changes: 0 additions & 38 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -5,41 +5,3 @@

# github actions/templates etc. - Dev Leads
/.github @pagefaultgames/dev-leads

# --- Translations ---

# all translations - Translation Leads
/src/locales @pagefaultgames/translation-leads

# Catalan (Spain/Spanish)
/src/locales/ca_ES @pagefaultgames/catalan-translation-team

# German
/src/locales/de @pagefaultgames/german-translation-team

# English
/src/locales/en @pagefaultgames/english-translation-team

# Spanish
/src/locales/es @pagefaultgames/spanish-translation-team

# French
/src/locales/fr @pagefaultgames/french-translation-team

# Italian
/src/locales/it @pagefaultgames/italian-translation-team

# Japenese
/src/locales/ja @pagefaultgames/japanese-translation-team

# Korean
/src/locales/ko @pagefaultgames/korean-translation-team

# Brasilian (Brasil/Portuguese)
/src/locales/pt_BR @pagefaultgames/portuguese_br-translation-team

# Chinese (simplified)
/src/locales/zh_CN @pagefaultgames/chinese_simplified-translation-team

# Chinese (traditional)
/src/locales/zh_TW @pagefaultgames/chinese_traditional-translation-team
2 changes: 2 additions & 0 deletions .github/workflows/deploy-beta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- uses: actions/setup-node@v4
with:
node-version: "20"
Expand Down
18 changes: 12 additions & 6 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
name: Deploy
name: Deploy Main

on:
push: {}
pull_request: {}
push:
branches:
- main
pull_request:
branches:
- main

jobs:
deploy:
if: github.repository == 'pagefaultgames/pokerogue'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- uses: actions/setup-node@v4
with:
node-version: "20"
Expand All @@ -20,20 +26,20 @@ jobs:
env:
NODE_ENV: production
- name: Set up SSH
if: github.event_name == 'push' && github.ref_name == github.event.repository.default_branch
if: github.event_name == 'push' && github.ref_name == 'main'
run: |
mkdir ~/.ssh
echo "${{ secrets.SSH_PUBLIC_KEY }}" > ~/.ssh/id_ed25519.pub
echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_ed25519
chmod 600 ~/.ssh/*
ssh-keyscan -H ${{ secrets.SSH_HOST }} >> ~/.ssh/known_hosts
- name: Deploy build on server
if: github.event_name == 'push' && github.ref_name == github.event.repository.default_branch
if: github.event_name == 'push' && github.ref_name == 'main'
run: |
rsync --del --no-times --checksum -vrm dist/* ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }}:${{ secrets.DESTINATION_DIR }}
ssh -t ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} "~/prmanifest --inpath ${{ secrets.DESTINATION_DIR }} --outpath ${{ secrets.DESTINATION_DIR }}/manifest.json"
- name: Purge Cloudflare Cache
if: github.event_name == 'push' && github.ref_name == github.event.repository.default_branch
if: github.event_name == 'push' && github.ref_name == 'main'
id: purge-cache
uses: NathanVaughn/[email protected]
with:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/eslint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ jobs:
steps:
- name: Check out Git repository # Step to check out the repository
uses: actions/checkout@v4 # Use the checkout action version 4
with:
submodules: 'recursive'

- name: Set up Node.js # Step to set up Node.js environment
uses: actions/setup-node@v4 # Use the setup-node action version 4
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/github-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
- name: Checkout repository for Typedoc
uses: actions/checkout@v3
with:
submodules: 'recursive'
path: pokerogue_docs

- name: Install OS package
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/test-shard-template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ jobs:
steps:
- name: Check out Git repository
uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Set up Node.js
uses: actions/setup-node@v4
with:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
- name: Check out Git repository
uses: actions/checkout@v4
with:
submodules: 'recursive'
path: tests-action
- name: Set up Node.js
uses: actions/setup-node@v4
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "public/locales"]
path = public/locales
url = https://github.com/pagefaultgames/pokerogue-locales
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,21 @@ If you have the motivation and experience with Typescript/Javascript (or are wil
2. Run `npm run start:dev` to locally run the project in `localhost:8000`

#### Linting
We're using ESLint as our common linter and formatter. It will run automatically during the pre-commit hook but if you would like to manually run it, use the `npm run eslint` script.
We're using ESLint as our common linter and formatter. It will run automatically during the pre-commit hook but if you would like to manually run it, use the `npm run eslint` script. To view the complete rules, check out the [eslint.config.js](./eslint.config.js) file.

### 📚 Documentation
You can find the auto-generated documentation [here](https://pagefaultgames.github.io/pokerogue/main/index.html).
For information on enemy AI, check out the [enemy-ai.md](./docs/enemy-ai.md) file.
For detailed guidelines on documenting your code, refer to the [comments.md](./docs/comments.md) file.

### ❔ FAQ

**How do I test a new _______?**
- In the `src/overrides.ts` file there are overrides for most values you'll need to change for testing

**How do I retrieve the translations?**
- The translations were moved to the [dedicated translation repository](https://github.com/pagefaultgames/pokerogue-locales) and are now applied as a submodule in this project.
- The command to retrieve the translations is `git submodule update --init --recursive`. If you still struggle to get it working, please reach out to #dev-corner channel in Discord.

## 🪧 To Do
Check out [Github Issues](https://github.com/pagefaultgames/pokerogue/issues) to see how can you help us!
Expand Down
31 changes: 18 additions & 13 deletions create-test-boilerplate.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
/**
* This script creates a test boilerplate file for a move or ability.
* @param {string} type - The type of test to create. Either "move", "ability",
* or "item".
* @param {string} fileName - The name of the file to create.
* @example npm run create-test move tackle
* This script creates a test boilerplate file in the appropriate
* directory based on the type selected.
* @example npm run create-test
*/

import fs from "fs";
Expand Down Expand Up @@ -34,7 +32,7 @@ async function promptTestType() {
console.log("Exiting...");
return process.exit();
} else if (!typeChoices.includes(typeAnswer.selectedOption)) {
console.error('Please provide a valid type ("move", "ability", or "item")!');
console.error(`Please provide a valid type (${typeChoices.join(", ")})!`);
return await promptTestType();
}

Expand All @@ -51,7 +49,7 @@ async function promptFileName(selectedType) {
{
type: "input",
name: "userInput",
message: `Please provide a file name for the ${selectedType} test:`,
message: `Please provide the name of the ${selectedType}:`,
},
]);

Expand Down Expand Up @@ -102,7 +100,7 @@ async function runInteractive() {
description = `Mystery Encounter - ${formattedName}`;
break;
default:
console.error('Invalid type. Please use "move", "ability", or "item".');
console.error(`Invalid type. Please use one of the following: ${typeChoices.join(", ")}.`);
process.exit(1);
}

Expand All @@ -112,7 +110,7 @@ import { Moves } from "#enums/moves";
import { Species } from "#enums/species";
import GameManager from "#test/utils/gameManager";
import Phaser from "phaser";
import { afterEach, beforeAll, beforeEach, describe, it, expect } from "vitest";
import { afterEach, beforeAll, beforeEach, describe, expect, it } from "vitest";

describe("${description}", () => {
let phaserGame: Phaser.Game;
Expand All @@ -131,15 +129,22 @@ describe("${description}", () => {
beforeEach(() => {
game = new GameManager(phaserGame);
game.override
.moveset([Moves.SPLASH])
.moveset([ Moves.SPLASH ])
.ability(Abilities.BALL_FETCH)
.battleType("single")
.disableCrits()
.enemySpecies(Species.MAGIKARP)
.enemyAbility(Abilities.BALL_FETCH)
.enemyMoveset(Moves.SPLASH);
});

it("test case", async () => {
// await game.classicMode.startBattle([Species.MAGIKARP]);
// game.move.select(Moves.SPLASH);
it("should do X", async () => {
await game.classicMode.startBattle([ Species.FEEBAS ]);

game.move.select(Moves.SPLASH);
await game.phaseInterceptor.to("BerryPhase");

expect(true).toBe(true);
});
});
`;
Expand Down
21 changes: 13 additions & 8 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import tseslint from '@typescript-eslint/eslint-plugin';
import stylisticTs from '@stylistic/eslint-plugin-ts'
import stylisticTs from '@stylistic/eslint-plugin-ts';
import parser from '@typescript-eslint/parser';
import importX from 'eslint-plugin-import-x';

Expand All @@ -16,31 +16,36 @@ export default [
'@typescript-eslint': tseslint
},
rules: {
"eqeqeq": ["error", "always"], // Enforces the use of === and !== instead of == and !=
"indent": ["error", 2], // Enforces a 2-space indentation
"eqeqeq": ["error", "always"], // Enforces the use of `===` and `!==` instead of `==` and `!=`
"indent": ["error", 2, { "SwitchCase": 1 }], // Enforces a 2-space indentation, enforces indentation of `case ...:` statements
"quotes": ["error", "double"], // Enforces the use of double quotes for strings
"no-var": "error", // Disallows the use of var, enforcing let or const instead
"prefer-const": "error", // Prefers the use of const for variables that are never reassigned
"no-var": "error", // Disallows the use of `var`, enforcing `let` or `const` instead
"prefer-const": "error", // Enforces the use of `const` for variables that are never reassigned
"no-undef": "off", // Disables the rule that disallows the use of undeclared variables (TypeScript handles this)
"@typescript-eslint/no-unused-vars": [ "error", {
"args": "none", // Allows unused function parameters. Useful for functions with specific signatures where not all parameters are always used.
"ignoreRestSiblings": true // Allows unused variables that are part of a rest property in object destructuring. Useful for excluding certain properties from an object while using the rest.
"ignoreRestSiblings": true // Allows unused variables that are part of a rest property in object destructuring. Useful for excluding certain properties from an object while using the others.
}],
"eol-last": ["error", "always"], // Enforces at least one newline at the end of files
"@stylistic/ts/semi": ["error", "always"], // Requires semicolons for TypeScript-specific syntax
"semi": "off", // Disables the general semi rule for TypeScript files
"no-extra-semi": ["error"], // Disallows unnecessary semicolons for TypeScript-specific syntax
"brace-style": "off", // Note: you must disable the base rule as it can report incorrect errors
"curly": ["error", "all"], // Enforces the use of curly braces for all control statements
"@stylistic/ts/brace-style": ["error", "1tbs"],
"@stylistic/ts/brace-style": ["error", "1tbs"], // Enforces the following brace style: https://eslint.style/rules/js/brace-style#_1tbs
"no-trailing-spaces": ["error", { // Disallows trailing whitespace at the end of lines
"skipBlankLines": false, // Enforces the rule even on blank lines
"ignoreComments": false // Enforces the rule on lines containing comments
}],
"space-before-blocks": ["error", "always"], // Enforces a space before blocks
"keyword-spacing": ["error", { "before": true, "after": true }], // Enforces spacing before and after keywords
"comma-spacing": ["error", { "before": false, "after": true }], // Enforces spacing after comma
"comma-spacing": ["error", { "before": false, "after": true }], // Enforces spacing after commas
"import-x/extensions": ["error", "never", { "json": "always" }], // Enforces no extension for imports unless json
"array-bracket-spacing": ["error", "always", { "objectsInArrays": false, "arraysInArrays": false }], // Enforces consistent spacing inside array brackets
"object-curly-spacing": ["error", "always", { "arraysInObjects": false, "objectsInObjects": false }], // Enforces consistent spacing inside braces of object literals, destructuring assignments, and import/export specifiers
"computed-property-spacing": ["error", "never" ], // Enforces consistent spacing inside computed property brackets
"space-infix-ops": ["error", { "int32Hint": false }], // Enforces spacing around infix operators
"no-multiple-empty-lines": ["error", { "max": 2, "maxEOF": 1, "maxBOF": 0 }], // Disallows multiple empty lines
}
}
]
14 changes: 14 additions & 0 deletions global.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import type { SetupServerApi } from "msw/node";

export {};

declare global {
/**
* Only used in testing.
* Can technically be undefined/null but for ease of use we are going to assume it is always defined.
* Used to load i18n files exclusively.
*
* To set up your own server in a test see `game_data.test.ts`
*/
var i18nServer: SetupServerApi;
}
7 changes: 6 additions & 1 deletion lefthook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,9 @@ pre-push:
commands:
eslint:
glob: "*.{js,ts,jsx,tsx}"
run: npx eslint --fix {push_files}
run: npx eslint --fix {push_files}

post-merge:
commands:
update-submodules:
run: git submodule update --init --recursive
Loading
Loading