pokerogue/src/enums/challenges.ts

9 lines
158 B
TypeScript
Raw Normal View History

Add Challenges (#1459) * Initial challenge framework * Add type localisation * Change how challenges are tracked Also fixes the difficulty total text * MVP Renames challenge types, temporarily hides difficulty, and implements challenge saving. * Attempt to fix one legal pokemon in a double battle * Make monotype ignore type changing effects * Make isOfType correctly detect normal types * Try to fix double battles again * Make challenge function more like classic * Add helper function for fainted or not allowed * Add framework for fresh start challenge and improve comments * Try to fix evolution issues * Make form changing items only usable from rewards screen * Update localisation * Additional localisation change * Add achievements for completing challenges * Fix initialisation bug with challenge achievements * Add support for gamemode specific fixed battles Also make monogen challenges face the e4 of their generation * Add better support for mobile in challenges * Localise illegal evolution/form change message * Update achievement names * Make alternate forms count for monogen * Update monotype achievement icons * Add more comments * Improve comments * Fix mid battle form changes * Reorder mode list * Remove currently unused localisation entry * Add type overrides for monotype challenges Meloetta always counts for psychic and castform always counts for normal * Change how form changes are handled Now attempts a switch at the start of each turn instead of immediately * Add start button to challenge select screen * Make starter select back out to challenge screen if using challenges * Fix daily runs * Update tests to new game mode logic
2024-06-08 06:07:23 +01:00
export enum Challenges {
SINGLE_GENERATION,
SINGLE_TYPE,
LOWER_MAX_STARTER_COST,
LOWER_STARTER_POINTS,
[Challenge] Inverse battle challenge (#3525) * add inverse battle challenge. refactoring type.ts for inverse battle challenge * update type integer -> number * add inverse battle condition to thunder wave, conversion 2. * add inverse_battle test code, add checking gameMode in runToSummon not to overwrite gameMode to CLASSIC always * update startBattle with isClassicMode default = true * add inverse achievement * fix achv validation condition * remove unnecessary new line * update defaultWidth 160 -> 200 * update locales * fix korean translation * fix korean translation2 * Update src/locales/de/achv.ts Co-authored-by: Jannik Tappert <38758606+CodeTappert@users.noreply.github.com> * Update src/locales/de/challenges.ts Co-authored-by: Jannik Tappert <38758606+CodeTappert@users.noreply.github.com> * Update src/locales/de/challenges.ts Co-authored-by: Jannik Tappert <38758606+CodeTappert@users.noreply.github.com> * resize challenge description 96 -> 84 * update challenge select UI size. * revert font size to 84. update de translation * Update src/locales/fr/challenges.ts Co-authored-by: Lugiad' <adrien.grivel@hotmail.fr> * Update src/locales/fr/achv.ts Co-authored-by: Lugiad' <adrien.grivel@hotmail.fr> * Update src/locales/es/challenges.ts Co-authored-by: Asdar <asdargmng@gmail.com> * Update src/locales/fr/challenges.ts Co-authored-by: Lugiad' <adrien.grivel@hotmail.fr> * Update src/locales/fr/achv.ts Co-authored-by: Lugiad' <adrien.grivel@hotmail.fr> * Update src/locales/es/achv.ts Co-authored-by: Asdar <asdargmng@gmail.com> * Update src/locales/fr/achv.ts Co-authored-by: Lugiad' <adrien.grivel@hotmail.fr> * shrink de font size on achivement * set middle align to achv title * Update src/locales/zh_CN/achv.ts Co-authored-by: mercurius-00 <80205689+mercurius-00@users.noreply.github.com> * Update src/locales/zh_TW/achv.ts Co-authored-by: mercurius-00 <80205689+mercurius-00@users.noreply.github.com> * Update src/locales/zh_CN/challenges.ts Co-authored-by: mercurius-00 <80205689+mercurius-00@users.noreply.github.com> * Update src/locales/zh_TW/challenges.ts Co-authored-by: mercurius-00 <80205689+mercurius-00@users.noreply.github.com> * fix zh_TW ahiv.ts * fix import code on inverse battle test for updated phase * Update src/data/type.ts Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> * update requested changes * Update src/locales/pt_BR/achv.ts Co-authored-by: José Ricardo Fleury Oliveira <josefleury@discente.ufg.br> * Update src/locales/pt_BR/achv.ts Co-authored-by: José Ricardo Fleury Oliveira <josefleury@discente.ufg.br> * Update src/locales/pt_BR/challenges.ts Co-authored-by: José Ricardo Fleury Oliveira <josefleury@discente.ufg.br> * [draft] update inverse battle apply function * change the way how to use applyChallenge for inverse type * resolve confilct * fix test codes * remove unnecessary multiplier variable and break codes * update getTypeDamageMultiplier argument type from `number` to `Type` * Fix inverse types tests (#1) * Fix Inverse Battle tests * Add timeout parameter to tests * update requested changes * update requested changes * update requested changes2 * update comments * Update src/test/utils/helpers/challengeModeHelper.ts Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> * Update src/test/utils/helpers/challengeModeHelper.ts Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> * fix mis pasted code * revert loadChallenge code for FreshStartChallenge * code refactoring * restore challenge.json lost translations * revert UI changes * revert unreverted newlines * Run History inclusion * requested changes from torranx * update WaterSuperEffectTypeMultiplierAttr for inverse battle matchup. * fix test code. adding flying press test code * update requested change from xavion3 * updated requested change from xavion 2 * update requested changes from xavion 3 * remove exception code which is not valid * attach partial mark to Freeze dry. requested by xavion * add missing game over phase code when we delete old phases.ts * fix test codes * merge conflict * fix achv condition * updated achv block condition. we don't want to change desc now * resolve conflict * Eternatus Moveset Tinkering * Cleaning it up --------- Co-authored-by: Jannik Tappert <38758606+CodeTappert@users.noreply.github.com> Co-authored-by: Lugiad' <adrien.grivel@hotmail.fr> Co-authored-by: Asdar <asdargmng@gmail.com> Co-authored-by: mercurius-00 <80205689+mercurius-00@users.noreply.github.com> Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com> Co-authored-by: José Ricardo Fleury Oliveira <josefleury@discente.ufg.br> Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com> Co-authored-by: frutescens <info@laptop>
2024-08-29 19:59:33 +01:00
FRESH_START,
INVERSE_BATTLE,
Add Challenges (#1459) * Initial challenge framework * Add type localisation * Change how challenges are tracked Also fixes the difficulty total text * MVP Renames challenge types, temporarily hides difficulty, and implements challenge saving. * Attempt to fix one legal pokemon in a double battle * Make monotype ignore type changing effects * Make isOfType correctly detect normal types * Try to fix double battles again * Make challenge function more like classic * Add helper function for fainted or not allowed * Add framework for fresh start challenge and improve comments * Try to fix evolution issues * Make form changing items only usable from rewards screen * Update localisation * Additional localisation change * Add achievements for completing challenges * Fix initialisation bug with challenge achievements * Add support for gamemode specific fixed battles Also make monogen challenges face the e4 of their generation * Add better support for mobile in challenges * Localise illegal evolution/form change message * Update achievement names * Make alternate forms count for monogen * Update monotype achievement icons * Add more comments * Improve comments * Fix mid battle form changes * Reorder mode list * Remove currently unused localisation entry * Add type overrides for monotype challenges Meloetta always counts for psychic and castform always counts for normal * Change how form changes are handled Now attempts a switch at the start of each turn instead of immediately * Add start button to challenge select screen * Make starter select back out to challenge screen if using challenges * Fix daily runs * Update tests to new game mode logic
2024-06-08 06:07:23 +01:00
}