Commit graph

13997 commits

Author SHA1 Message Date
Eduardo Quezada
d076193b9f Merge branch 'RHH/master' into RHH/upcoming
# Conflicts:
#	asm/macros/battle_script.inc
#	include/constants/battle.h
#	include/constants/battle_script_commands.h
#	src/battle_script_commands.c
#	src/data/battle_moves.h
2023-12-03 16:39:32 -03:00
LOuroboros
6b1ea33be8
Fixed Trace (#3623)
* Applied Alex's fix for ABILITYEFFECT_TRACE

* Added Trace tests written by Alex/Rainonline

* Updated Trace's target-choosing capabilities and added a double battle test for it
Credits to Alex/Rainonline.

* Removed 2 of the 3 'Trace on opponent's switch-in' tests

* Added another Trace test
2023-12-02 23:09:09 +01:00
Eduardo Quezada D'Ottone
ff0351ca70
Ask users for credits in README.md (#3619)
* Ask users for credits in README.md

* Consistently refer to the repo as pokeemerald-expansion

---------

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-12-01 16:41:33 +01:00
Alex
d1a69d7e04
fix new line (#3621) 2023-11-30 20:01:21 -03:00
Pawkkie
131bb94d73
Extend AI_FLAG_SMART_SWITCHING for Encore / hazards / lowered attacking stats (#3557)
* Consider Encore / lowered stats / hazards

* Fix poorly thought out Return FALSE

* Incorporate Egg's feedback

* Tests for hazards and stats, and some fixes

---------

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-30 12:37:19 +01:00
psf
2b1d36db46
Fix issue where Sky Battles cause upcoming not to compile when debug menu is turned off (#3617)
* Moved Sky Battle error message outside of debug.inc
https://github.com/rh-hideout/pokeemerald-expansion/issues/3615\#issue-2015546179

* Update data/scripts/debug.inc

Made changes from Jasper's review

625f007741

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>

---------

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-29 23:08:36 +01:00
Alex
4bde378c0d
Fixes Floral Healing + Tests (#3604) 2023-11-29 13:57:29 +01:00
Alex
913bc6c9d0
Adds White Herb tests (#3611) 2023-11-29 11:05:06 +01:00
ghoulslash
8c4058c7a8
add HITMARKER_DISABLE_ANIMATION for bug bite consumeberry (#3607)
Co-authored-by: ghoulslash <pokevoyager0@gmail.com>
Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-28 18:57:11 +01:00
Bassoonian
b72581985c
Add bad poison downgrade config (#3605)
Co-authored-by: Alex <93446519+AlexOn1ine@users.noreply.github.com>
2023-11-27 12:42:53 +01:00
psf
fe16a2cdee
Port pokefirered's Vs. Seeker to pokeemerald (#3256)
* First version of Vs. Seeker

* Update movement.inc

98f7e9978d (r1306721924)

* Update field_effect_scripts.s

https://github.com/rh-hideout/pokeemerald-expansion/pull/3256/files#r1306722004

* Update field_effect_scripts.s

https://github.com/rh-hideout/pokeemerald-expansion/pull/3256/files#r1306722024

* Update item_use.h

https://github.com/rh-hideout/pokeemerald-expansion/pull/3256/files#r1306722401

* Update movement_action_func_tables.h

https://github.com/rh-hideout/pokeemerald-expansion/pull/3256/files#r1306722828

* Update event_object_movement.c

https://github.com/rh-hideout/pokeemerald-expansion/pull/3256/files#r1306722887

* Update overworld.c

https://github.com/rh-hideout/pokeemerald-expansion/pull/3256/files#r1306723396

* Update vs_seeker.h

https://github.com/rh-hideout/pokeemerald-expansion/pull/3256/files#r1306724158

* Update vs_seeker.c

Addressed some cleanup comments from SBird

* Update UpdateRandomTrainerRematches
Fixed typo in ClearAllTrainerRematchStates
Fixed types in GetRematchableTrainerLocalId

* Updated UseVsSeekerEffect_2

* Updated UseVsSeekerEffect_3

* Updated UseVsSeekerEffect_4

* Fixed bug that allowed Vs Seeker to be used indoors in correct places
Moved VsSeeker function declarations into header

* Refactored FieldUseFunc_VsSeeker

* Added curly braces to else case in FieldUseFunc_VsSeeker

* renamed data[x] in Task_ResetObjectsRematchWantedState

* Refactored Task_ResetObjectsRematchWantedState

* Refactored VsSeekerResetObjectMovementAfterChargeComplete

* Refactored ResetMovementOfRematchableTrainers

* Refactored GatherNearbyTrainerInfo

* Refactored Task_VsSeeker_3

* CanUseVsSeeker

* Refactored GetVsSeekerResponseInArea

* GetCurVsSeekerResponse refactored

* Cleaned up GetTrainerFlagFromScript

* Gave sensible names to Task_VsSeeker

* Fixed two bugs where player would not have the right gfx state after using VsSeeker on a Bike or Underwater

* Renamed UseVsSeeker Functions

* Added I_VS_SEEKER_CHARGING to make Vs. Seeker broken until flag is assigned
Removed extra VsSeeker animation code

* Addressed PR feedback

* Fixed issue with building non-modern

* Refactored GetRunningBehaviorFromGraphicsId and renamed to GetResponseMovementTypeFromTrainerGraphicsId

* Addresses Lunos's PR feedback: https://github.com/rh-hideout/pokeemerald-expansion/pull/3256\#pullrequestreview-1623547850
Removed the check to see if a map was not indoors to improve readability
Made IsValidLocationForVsSeeker into a static function

* Added changes in response to Jasper's feedback
https://github.com/rh-hideout/pokeemerald-expansion/pull/3256\#pullrequestreview-1725276522

* Updated with Edu's discord feedback https://discord.com/channels/419213663107416084/1135040810082123907/1176872015085453392

* Removed ifdef tags around the repo unless needed
b5dc744ced
2023-11-26 18:58:43 +01:00
psf
493478e94b
Added support for XY's Sky Battles (#2950)
* Original implementation from Phlayne

* Moved Sky Battle Flag / Var into a config

* Optimized existing code and fixed existing bugs

Added error message for when sky battle var and flag are not set
Merged CanDoSkyBattle and PrepareSkyBattle into one special

* Added compatibility for Gen7+

* Commented out Volt Crash from banned moves

* Cleaned up debug scripts from testing

* Fixed bug where player did not white out even if they had no healthy Pokémon and only an egg
Zeroed out both Sky Battle configs

* Removed extra include from src/field_specials.c
Removed extra line break in src/battle_script_commands.c

* Added FLAG_DISABLED_IN_SKY_BATTLE
Added FLAG_DISABLED_IN_SKY_BATTLE to appropriate moves

* Changed DoesSkyBattleCancelCurrentMove to look at move flags

* Fixed alignment and spacing in battle_moves.h

* Added FLAG_DISABLED_IN_SKY_BATTLE to Sticky Web

* Added FLAG_DISABLED_IN_SKY_BATTLE to Steel Roller

* Disabled the ability to change Battle Terrain when Sky Battle is happening
Stopped Ceaseless Edge from spawning Spikes when Sky Battle is happening
Added B_SKY_BATTLE_STRICT_MECHANICS config

* Fixed bug with SKY_BATTLE_STRICT_MECHANICS where conditions were not consistently being applied

* Add rulesVariants to the BattleStruct
Added skyBattle check in AllocateBattleResources

* Replaced B_FLAG_SKY_BATTLE checks with rulesVariants.skyBattle checks

* Fixed debug script

* Reverted include/config/battle.h

* Fixed spacing and placement of functions

* Fixed debug script omission
Fixed bug where Spikes did not set from Ceaseless Edge and Stone Axe

* Added FLAG_DISABLED_IN_SKY_BATTLE to Psychic Terrain

* Addressed DizzyEgg PR feedback

* Forgot a file in last commit

* Addressed feedback from DizzyEggg

* Address Lunos' PR feedback

* Update specials.inc

Added an empty line at the end of data/specials.inc

* Fixed spacing

* Apply suggestions from code review

Co-authored-by: Eduardo Quezada D'Ottone <eduardo602002@gmail.com>

* Updated skyBattleBanned and HandleBattleVariantEndParty to use correct names

* Removed STRICT_MOVES and STRICT_MECHANICS

* Fixed minor spacing issues with merge

* Merged in upcoming

* Implemented feedback from Jasper
5da6117d1b

---------

Co-authored-by: Eduardo Quezada D'Ottone <eduardo602002@gmail.com>
2023-11-26 16:59:44 +01:00
Bassoonian
0fe203c7f5
Fix fusions (#3602) 2023-11-25 09:56:41 -03:00
Eduardo Quezada
c8b0545d20 Merge branch 'RHH/master' into RHH/upcoming
# Conflicts:
#	include/battle.h
2023-11-25 00:51:33 -03:00
Bassoonian
74bb0f05f5
Battle Dome Automation (#3596)
* MOVE_POINTS_STRONG

* MOVE_POINTS_POWERFUL

* MOVE_POINTS_LOW_PP

* MOVE_POINTS_STAT_RAISE

* Removed duplicate function

* MOVE_POINTS_STAT_LOWER

* MOVE_POINTS_DMG

* MOVE_POINTS_ACCURATE

* MOVE_POINTS_HEAL

* MOVE_POINTS_DEF

* MOVE_POINTS_RISKY

* MOVE_POINTS_EFFECT

* MOVE_POINTS_LUCK

* MOVE_POINTS_POPULAR

* MOVE_POINTS_STATUS

* MOVE_POINTS_RARE

* MOVE_POINTS_COMBO

* Apply review suggestions

* More implemented review suggestions

---------

Co-authored-by: Eduardo Quezada <eduardo602002@gmail.com>
2023-11-24 16:19:32 +01:00
Frank DeBlasio
b7cd6502d4
Add config for times of day (#3579)
* Added initial config for times of day

* Changed TIME_DUSK/DUSK_EVO to EVENING

* Added morning and evening to Gens 3/4

* Renamed *_EVO_HOUR_BEGIN/END to just *_HOUR_BEGIN/END

* Incorporated comments
2023-11-24 15:57:08 +01:00
kittenchilly
b6ff973f38
Add support for legendary fusion (#3274)
* Legendary Mon Fusion Evolution Compatibility Added

Kyurem, Calyrex, and Necrozma Fusions have been implemented, however, the animation for the the process is incomplete, the party menu screen needs to be updated while the screen is whited out and it has proved beyond me right now. Smh

* Added Fusion Move Prompts

Handles cases for learning the fusion moves from the other fused mon and deleting the move when you unfuse (plus learning confusion (well a set choice in the data struct) if there are no moves left after deleting one)

* Fix Bug With Fusion Mon Move Learning

If the main fusion came after the fused mon in the party order it would try to teach the move to the next member in the party

* Apply suggestions from code review

Co-authored-by: LOuroboros <lunosouroboros@gmail.com>

* Fix build

* Fix fusion items being used up

* Fixed animations

* RefreshPartyMenu

* Apply suggestions from code review

Co-authored-by: Eduardo Quezada D'Ottone <eduardo602002@gmail.com>

* Apply suggestions

* Update form_change_tables.h

* Fix animation and simplify fusion tables

* Fix party full message

* Remove trailing whitespaces

* Update party_menu.c

* Update party_menu.c

* Make IsFusionMon better

* Apply suggestions from code review

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>

---------

Co-authored-by: TeamAquasHideout <jonathonheddings@gmail.com>
Co-authored-by: Eduardo Quezada D'Ottone <eduardo602002@gmail.com>
Co-authored-by: LOuroboros <lunosouroboros@gmail.com>
Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-23 22:59:51 +01:00
psf
8d6cb9692a
Improved Repel / Lure Menu (#3594)
* First draft of repel lure

* Updated all lure and repel scripts

* Optimized inc file

* Updated y coord

* optimized sprays.c

* Removed spray.inc

* Updated cosnt use

* Removed dead repel and lure code

* Updated debug for testing

* testing new inc file

* turn on debug and options

* playground generated inc file without ifs

* pory generated inc with ifdef complete

* Updated spray.c with new inc

* reverted item config

* Reverted event scripts

* Reverted event scripts

* Revert config

* Added testing scripts for debug

* Added back specials

* reverted debug scripts

* Updated use of constants

* Addressed tabs > spaces feedback
https://github.com/rh-hideout/pokeemerald-expansion/pull/3594\#discussion_r1402917676

* Updated constant names to avoid confusion
Made inc file changes
https://github.com/rh-hideout/pokeemerald-expansion/pull/3594\#pullrequestreview-1746418044

* Updated constant name of NUM_SPRAY_TYPES to NUM_SPRAY_STRENGTH to be more accurate
2023-11-23 21:31:33 +01:00
Alex
71fd95e6d4
Fixes Protosynthesis and Quark Drive ability pop up (#3595) 2023-11-23 19:49:21 +01:00
Bassoonian
d6ded280a3
Reflect Ivy Cudgel type in interfaces (#3590)
* Reflect Ivy Cudgel type in interfaces

* Use GetSideParty
2023-11-23 19:23:10 +01:00
ghoulslash
c0bc6979c7
Fixes Howl activating if partner has Soundproof (#3593) 2023-11-22 17:42:36 -05:00
Alex
ca39889587 Fixes Howl 2023-11-22 21:55:08 +01:00
Bassoonian
a7beed5b25
Dynamax messages (#3581)
* Dynamax messages

* Convert various to callnative

* Remove battler argument from callnatives

* Rename i variable

* Fix missing else
2023-11-21 19:18:18 +01:00
Alex
b9edbb429b
Adds combined pledge move effects (#3336)
* Adds combined pledge move effects

* added pledge status and various other fixes

* leftover

* fix triple arrow test tag

* pledge moves can not be redirected by absorbing abilities

* more pledge changes

* remove duplicate test

* Stab boost, Rainbow anim and new SeaOfFire anim

* leftover

---------

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-21 16:23:22 +01:00
Alex
be42d4eafb
Increase score of secondary effects only at 100% chance (#3583)
Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-21 11:30:20 +01:00
ghoulslash
4c783e2ae1
Indexes for Type Effectiveness table (#3374) 2023-11-20 22:02:22 -05:00
ghoulslash
5be62225ec
Merge branch 'upcoming' into RHH/pr/upcoming/typeEffectiveness 2023-11-20 21:45:37 -05:00
ghoulslash
34c608724d
Clean up time of day code (#3585) 2023-11-20 14:39:50 -05:00
Alex
428a23d313
Merge branch 'upcoming' into timefunctionfixes 2023-11-20 20:20:04 +01:00
Frank DeBlasio
f356bb1cee
Added B_UPDATED_MOVE_DATA checks against Acid/Crunch's descriptions (#3586)
Co-authored-by: Alex <93446519+AlexOn1ine@users.noreply.github.com>
2023-11-20 20:07:34 +01:00
ghoulslash
41e65357b8
Merge branch 'upcoming' into timefunctionfixes 2023-11-20 14:04:19 -05:00
Bassoonian
c9c0827ba2
Fix 3568 (#3569) 2023-11-20 19:33:06 +01:00
Bassoonian
cb245a00c6
Includes older item and move names as variants (#3580)
* Item name variants

* Updated move names

---------

Co-authored-by: Alex <93446519+AlexOn1ine@users.noreply.github.com>
2023-11-20 18:35:00 +01:00
Bassoonian
f6f305ef1d Clean up time of day code 2023-11-20 11:06:20 +01:00
Eduardo Quezada
13a65a21ad Adds configable nature colors (#3582)
* Colored stats depending on nature

* Fix bug

* Update colors and add config

---------

Co-authored-by: DizzyEggg <jajkodizzy@wp.pl>
2023-11-19 21:11:38 -03:00
Eduardo Quezada
341bbb30ef Revert "Adds configable nature colors (#3582)"
This reverts commit 9311911413.
2023-11-19 21:10:21 -03:00
Bassoonian
9311911413
Adds configable nature colors (#3582)
* Colored stats depending on nature

* Fix bug

* Update colors and add config

---------

Co-authored-by: DizzyEggg <jajkodizzy@wp.pl>
2023-11-19 23:18:47 +01:00
Bassoonian
59a7d2cb92 Update colors and add config 2023-11-19 18:30:18 +01:00
Bassoonian
8a772b729a Merge branch 'nature_color' of https://github.com/DizzyEggg/pokeemerald into naturecolors 2023-11-19 18:23:47 +01:00
Alex
4cb03d4add
Adds Raging Bull and various fixes (#3552)
* Adds Raging Bull and various fixes

* fix compiling on abgcc

* syrup bomb anim fix

* sticky syrup anim in link battles

* fix sticky syrup in link battles

* fix battler index

---------

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-19 17:45:58 +01:00
Katy
b5cb92f0e2
Gen 6 Sprites/Animations For Species (#3543)
* Bunnelby Spritework

+ New pal + new animation

* Fletchling Spritework

New front sprite, animation and palettes

* Fletchinder + Talonflame Changes

New animation for Fletchinder
Spritework + animations for Talonflame

* Flabebe, Floette + Florges Changes

+ Touched up Flabebe
+ Fixed Floettes normal forms sprite
+ Added second frame to Eternal form for Floette
+ Animations changed

* Amaura Spritework

New second frame + animation (frame-by-frame)

* Chespin Spritework

Touched up chespins sprites + changed the animation.

---------

Co-authored-by: Alex <93446519+AlexOn1ine@users.noreply.github.com>
2023-11-18 23:48:02 +01:00
Frank DeBlasio
42076897d3
Made function for time-based evolutions (#3369)
* Made function for time-based evolutions

* Incorporated Edu's comments and time variables

* Moved time of day begin/end variables to rtc.h

* Fixed if/else statement to pass building with modern

* Added morning

* Added ability to check if end time > beginning time

* Updated times to match SwSh

---------

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-18 16:53:56 +01:00
Alex
5fa1bffa8d
Adds Glaive Rush, fixes for Plasma Fists and Relic Song (#3476)
* Adds Glaive Rush

* Fixes: Glaive Rush status is removed until users next turn

* Glaive Rush no affect

* simplify glaive rush script

* simlify script further

* leftover

* Fix Plasma Fists and Relic Song + tests

* Callnative for Plasma Fists

* Use Status Field Ion Deludge for Plasma Fists

* add assumes for flinch_status

---------

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-18 15:19:38 +01:00
Frank DeBlasio
efe4929ce2
Added Japan-only Walda PC icons (#3550)
* Added Japan-only Walda PC icons

* Added a config for the Japanese icons

* Update overworld.h with suggestions

---------

Co-authored-by: Eduardo Quezada D'Ottone <eduardo602002@gmail.com>
2023-11-18 00:54:13 +01:00
ghoulslash
bf8c9609ae
add battle pyramid wild reqs (#2581)
* add battle pyramid wild reqs

* fix comment

* fix ice type round to match vanilla. move config to overworld

* some fixes

* BATTLE_PYRAMID_RANDOM_ENCOUNTERS define to FALSE defualt

* fix GetSpeciesName

* fix GetTotalBaseStat define, gEvolutionTable targetSpecies call

* fix wildMons call

* fix call to CheckBattlePyramidEvoRequirement

* fix arg 2 in CheckBattlePyramidEvoRequirement

* free->Free and fix evoItems ptr

* move sBurningMoves

* fix comment

fix ice type round to match vanilla. move config to overworld

some fixes

BATTLE_PYRAMID_RANDOM_ENCOUNTERS define to FALSE defualt

fix GetSpeciesName

fix GetTotalBaseStat define, gEvolutionTable targetSpecies call

fix wildMons call

fix call to CheckBattlePyramidEvoRequirement

fix arg 2 in CheckBattlePyramidEvoRequirement

free->Free and fix evoItems ptr

move sBurningMoves

BATTLE_PYRAMID_RANDOM_ENCOUNTERS defaults to false

* fix errors

* initial movesCount, abilitiesCount

---------

Co-authored-by: ghoulslash <pokevoyager0@gmail.com>
Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-17 16:04:41 +01:00
Eduardo Quezada
508332a93f Reverted PR template tests 2023-11-17 11:59:34 -03:00
Eduardo Quezada
8f3eb1c9a5 PR template test 2 2023-11-17 11:53:25 -03:00
Eduardo Quezada
5f24bf6e77 PR template test 2023-11-17 11:49:01 -03:00
LOuroboros
efe9f6d8ab
Added battle tests for Embargo (#3555)
* Added Embargo battle tests

* Expanded Embargo doesn't prevent Primal Reversion to avoid CI failure

* Applied corrections to some of the Embargo tests
2023-11-17 13:14:37 +01:00
Eduardo Quezada D'Ottone
c46f9ec6a5
Form changing method for Shaymin Sky into Land at night (#1690)
* Form changing method for Shaymin Sky into Land at night

* Ordered form change tables

* Refactored form change type to support both night and day

* Removed added space

---------

Co-authored-by: Bassoonian <iasperbassoonian@gmail.com>
2023-11-17 00:09:43 +01:00