Commit Graph

9546 Commits

Author SHA1 Message Date
kittenchilly
c8aac3407e Merge branch 'upcoming' into overworldsnow 2023-08-29 21:02:33 -05:00
kittenchilly
c427d96f3f Better Ultra Burst animation 2023-08-29 19:13:21 -05:00
kittenchilly
028536e2d3 Spaces 2023-08-29 17:12:09 -05:00
kittenchilly
d540eccbb1 Merge branch 'upcoming' into ultraburst 2023-08-29 16:17:35 -05:00
Eduardo Quezada
be152fbee8 Merge branch 'RHH/master' into RHH/pr/master/opponentName 2023-08-29 13:11:32 -04:00
DizzyEggg
0381ccdf32 remove more of gActiveBattler 2023-08-29 16:20:16 +02:00
DizzyEggg
156aa59f18 start removing gActiveBattler in controller emitters 2023-08-29 15:21:31 +02:00
DizzyEggg
00e1542cb8 Merge branch 'ai_switch_mon_fix' of https://github.com/DizzyEggg/pokeemerald into ai_switch_mon_fix 2023-08-29 10:42:07 +02:00
DizzyEggg
44acd287f1 solve conflicts 2023-08-29 10:41:05 +02:00
ghoulslash
326fb2605a
Some gActiveBattler Fixes (#3259)
* some gActiveBattler related fixes

* fix IsBattleSEPlaying gActiveBattler->battlerId

---------

Co-authored-by: ghoulslash <pokevoyager0@gmail.com>
2023-08-29 09:31:11 +02:00
ghoulslash
4490e9879a
Prevent certain status moves when item is known + Fake Out changes (#3219) 2023-08-28 17:12:29 -04:00
DizzyEggg
6ae1ba10da fix conflicts 2023-08-28 13:55:45 +02:00
Pawkkie
906ea4a5b0
Add missing absorbing abilities to FindMonThatAbsorbsOpponentsMove (#3218)
* Add missing absorbing abilities to FindMonThatAbsorbsOpponentsMove

* Use array to match ability to absorbing type

Previous implementation involving piggybacking on a conditional in a bit of a messy fashion to check for each ability type, this should be more readable and more easily modified by a novice. This is almost exactly BuffelSaft's inclement emerald implementation.

* Minor syntax fixes
2023-08-28 13:39:27 +02:00
GriffinR
d67914e114
Merge pull request #1912 from GriffinRichards/moves-mask
Handful of fixes related to MAX_MON_MOVES
2023-08-27 19:40:59 -04:00
kittenchilly
37f6685949 Merge branch 'upcoming' into overworldsnow 2023-08-27 14:51:57 -05:00
kittenchilly
48d6fe2e64 Merge branch 'upcoming' into ultraburst 2023-08-26 14:43:31 -05:00
voloved
2784f701d8
Poké Ball shortcut tweaks (#3254) 2023-08-26 12:58:51 -04:00
voloved
2a2cd77cf4
Allow Cycling Through Balls in the Last Ball Used Menu (#3039) 2023-08-24 19:23:26 -04:00
Eduardo Quezada D'Ottone
9c937a945c
Pokemon sprite review pt.1 (#3235) 2023-08-23 22:43:42 -04:00
Philipp AUER
905fc6fd4d
Fixed Metronome Item damage multiplier (#3246)
Co-authored-by: sbird <sbird@no.tld>
2023-08-23 19:23:00 -04:00
CyanSMP64
fd37946c1d resize golduck 2023-08-22 20:31:13 +12:00
LOuroboros
9d6953cc63
Removed the sTMHMMoves array and made TMs/HMs read moves from their secondaryId item field (#3243)
* Deleted sTMHMMoves array, TMs/HMs read moves from their secondaryId item field now
The unused "registrability" variable has been removed in order to preserve the size of the gItems array after turning the secondaryId variable into a u16.
* Made ItemIdToBattleMoveId return ITEM_NONE if an item that is not a TM/HM is passed through it
* Renamed IsMoveHm to IsMoveHM
2023-08-21 12:49:17 +01:00
DizzyEggg
9cf5376c96 use GetBattlerParty in LoadMonSprite 2023-08-21 09:43:01 +02:00
GriffinR
e70577d59b Add missing sizeof in trainer_see 2023-08-20 17:22:29 -04:00
kittenchilly
a79898f1b1 Make fog cause misty terrain 2023-08-20 13:51:48 -05:00
GriffinR
4941e2602a
Merge pull request #1909 from GriffinRichards/stat-anim
Document stat change animation
2023-08-20 14:29:11 -04:00
kittenchilly
5e98891577 Snow doesn't cause shade anymore 2023-08-20 13:24:20 -05:00
CyanSMP64
4e5809a0d0 tweak graveler, pikachu 2023-08-20 22:08:54 +12:00
kittenchilly
0ad3919f22 Fix overworld snow weather 2023-08-19 01:40:31 -05:00
CyanSMP64
ec24754489 fix arcanine, change bg colour of green pokemon 2023-08-18 17:24:30 +12:00
Eduardo Quezada
d3333812dd Merge branch 'RHH/upcoming' into RHH/pr/upcoming/cleanup/customTrainer 2023-08-17 17:52:28 -04:00
kittenchilly
4ca4b2dd76 Update battle_interface.c 2023-08-17 13:29:27 -05:00
kittenchilly
4e0e70ae81 Fix memory corruption when handling the ultra burst trigger sprite 2023-08-17 13:29:04 -05:00
kittenchilly
f95b4fdb4c Merge branch 'upcoming' into ultraburst 2023-08-17 13:25:00 -05:00
Eduardo Quezada
a6dbb68bac Merge branch 'RHH/master' into RHH/upcoming
# Conflicts:
#	data/battle_scripts_1.s
#	src/battle_util.c
#	src/battle_z_move.c
2023-08-17 13:42:09 -04:00
Philipp AUER
cd90fdec5d
[Critical] fix memory corruption when handling trigger sprites (#3238)
Co-authored-by: sbird <sbird@no.tld>
2023-08-16 20:21:16 -04:00
GriffinR
bdc0ea1037 Add MOD to match mod with powers of 2 2023-08-16 16:44:45 -04:00
GriffinR
057928438a Document ChooseMoveAndTargetInBattlePalace 2023-08-16 16:41:29 -04:00
GriffinR
aca7998b93 Add missing use of ALL_MOVES_MASK 2023-08-16 14:33:15 -04:00
CyanSMP64
74de0ef3ca set background colour 2023-08-16 13:58:31 +12:00
GriffinR
10a10e914b
Merge pull request #1910 from GriffinRichards/misc-constants
Use miscellaneous missing constants
2023-08-15 17:53:41 -04:00
CyanSMP64
0c27db10d6 Review mon sprites 0001-0080 2023-08-15 20:24:07 +12:00
kittenchilly
dba28cf93f
Allow Z-Moves to be selected after Mega Evolution (#3233)
* Allow Z-Moves to be selected after Mega Evolution

* You cannot do Wish Mega Evolution at all if you hold a z crystal

* Rebase to master
2023-08-14 19:10:15 -04:00
LOuroboros
2d45b9b8fe
Corrected conditionals used for B_SPEED_BUFFING_RAPID_SPIN and I_GEM_BOOST_POWER (#3232) 2023-08-14 16:14:12 -04:00
LOuroboros
c414a0103c
Made Cmd_jumpifnopursuitswitchdmg and Cmd_pursuitdoubles use Pursuit's effect ID instead of its move ID (#3231)
* Made jumpifnopursuitswitchdmg use Pursuit's effect ID instead of its move ID

* Made Cmd_pursuitdoubles use Pursuit's effect ID too, even though it's unused
2023-08-14 08:45:37 -04:00
PCG
b8a22eb119
Remove soundMove from Steam Eruption and replace it with sheerForceBoost (#3229)
Co-authored-by: PCG06 <prajithgomes06@gmail.com>
2023-08-13 00:53:22 -04:00
GriffinR
4c2b12541b
Merge pull request #1908 from GriffinRichards/name-buffer
Automatically update nickname buffer sizes
2023-08-12 23:36:19 -04:00
GriffinR
344fe4dd65 Stop double-counting EOS in assert 2023-08-12 23:13:11 -04:00
kittenchilly
5e8caa8d45 Merge branch 'upcoming' into ultraburst 2023-08-12 12:36:11 -05:00
kittenchilly
2b27b0bf00 Constants 2023-08-12 12:30:36 -05:00
Eduardo Quezada
952bacd858 Merge branch 'RHH/master' into RHH/upcoming
# Conflicts:
#	.github/ISSUE_TEMPLATE/01_battle_engine_bugs.yaml
#	.github/ISSUE_TEMPLATE/02_battle_ai_issues.yaml
#	.github/ISSUE_TEMPLATE/04_other_errors.yaml
2023-08-11 17:50:28 -04:00
Eduardo Quezada D'Ottone
ada29313de
Fix for wild double battles with an in-game partner (#3210)
Co-authored-by: DizzyEggg <jajkodizzy@wp.pl>
2023-08-11 17:29:10 -04:00
Philipp AUER
59da940283
Refactor damage formula to match Gen5+ (#3196)
* [battle, damage] refactor damage formula to match gen5+

* [test] use exact values for dry skin, swarm tests

* fixup: assume stats for dry-skin, swarm tests

---------

Co-authored-by: sbird <sbird@no.tld>
2023-08-11 16:28:38 -04:00
GriffinR
b248791f47
Merge pull request #1904 from GriffinRichards/temp-alias
Add temp flag and var aliases
2023-08-11 15:45:00 -04:00
kittenchilly
c3a8edae32 Sprites and fixes 2023-08-11 13:36:01 -05:00
Eduardo Quezada
f026b51b48 Merge branch 'RHH/upcoming' into RHH/pr/upcoming/cleanup/customTrainer
# Conflicts:
#	src/battle_main.c
#	src/battle_tower.c
#	src/match_call.c
2023-08-11 11:41:44 -04:00
GriffinR
60a6c9d160
Merge pull request #1903 from GriffinRichards/frontier-gfx
Fix some frontier gfx, adjacent cleanup
2023-08-10 14:49:44 -04:00
Alex
bcb6f723d9 Use AI_DATA->holdEffects instead AI_GetHoldEffect 2023-08-10 16:24:29 +02:00
Alex
275e5ef5e6 Make more use of AI_GetHoldEffect + Fake Out changes
fix ShouldTryToFlinch

fix some mess up

fix of fix of mess up
2023-08-10 15:33:12 +02:00
GriffinR
d5d46bb438 More DISPLAY_WIDTH/HEIGHT constant usage 2023-08-10 01:42:38 -04:00
GriffinR
18319e8da3 Misc missing constant use 2023-08-10 01:42:18 -04:00
GriffinR
079f2da0f6 Fix some missing constant use in Apprentice 2023-08-10 00:38:23 -04:00
kittenchilly
c3e31af5f3 Ultra burst trigger 2023-08-09 22:12:26 -05:00
GriffinR
d1c2a30149
Merge pull request #1907 from GriffinRichards/fix-tv
Fix Bravo Trainer Tower member names
2023-08-09 15:25:45 -04:00
GriffinR
6eaaa50ad5
Correct berry fix graphics colors, more PLTT constant use (#1892) 2023-08-09 12:49:21 -04:00
Martin Griffin
912a80e27a
Reference TMs and HMs by move instead of number (#1732) 2023-08-09 10:51:01 -04:00
DizzyEggg
5f7819f697 no exp for ai mons 2023-08-09 16:03:02 +02:00
DizzyEggg
fec8f14fff IsAiAiBattle function 2023-08-09 15:57:22 +02:00
DizzyEggg
d0fe75b06a fixes 2023-08-09 09:57:42 +02:00
DizzyEggg
a0c34813f1 small fixes 2023-08-09 09:34:41 +02:00
DizzyEggg
8d5ba6c6d1 allow ai vs ai battles 2023-08-09 09:15:42 +02:00
GriffinR
6598cb30bc Document stat change animation 2023-08-08 23:56:16 -04:00
GriffinR
65fee186f8 Automatically update nickname buffer sizes 2023-08-08 16:28:09 -04:00
GriffinR
087a2cecef Fix Bravo Trainer Tower member names 2023-08-08 14:38:00 -04:00
DizzyEggg
be0861b746
Update src/battle_ai_main.c
Co-authored-by: LOuroboros <lunosouroboros@gmail.com>
2023-08-08 20:03:19 +02:00
DizzyEggg
f72ec368fc improve switching with ai bad moves 2023-08-08 12:55:47 +02:00
Alex
42992ca5ce
Fix Teleport ending trainer battles (#3166) 2023-08-07 11:23:12 -04:00
DizzyEggg
1fb42e4497
Sticky web / Court Change / Mirror Armor tests + small fixes (#3160)
Co-authored-by: Eduardo Quezada D'Ottone <eduardo602002@gmail.com>
Co-authored-by: Martin Griffin <martin.griffin@algosport.co.uk>
2023-08-07 10:27:57 -04:00
Alex
8ee3a3c5bb solve conflics 2023-08-07 14:25:30 +02:00
DizzyEggg
ce18df46e6 replace global usage of gActiveBattler in controller files 2023-08-07 12:51:58 +02:00
DizzyEggg
b8ba6139cb health bar update 2023-08-07 10:29:02 +02:00
DizzyEggg
546b0c7e97 handle move anim 2023-08-07 09:26:03 +02:00
Eduardo Quezada
34d38bdbae Merge branch 'RHH/master' into RHH/upcoming 2023-08-06 20:31:45 -04:00
DizzyEggg
e8d6c99e6d more controllers work 2023-08-07 01:05:09 +02:00
DizzyEggg
ef8024d8c5 draw trainer pic 2023-08-06 21:50:59 +02:00
Eduardo Quezada
d9a17467cf Kept previous check while using gTestRunnerEnabled 2023-08-06 14:28:02 -04:00
DizzyEggg
a9483c361b trainer intro ball throw 2023-08-06 12:41:36 +02:00
DizzyEggg
af899c9679 stuff 2023-08-06 00:44:22 +02:00
DizzyEggg
ffb0e20049 hide show party status summary 2023-08-05 23:27:56 +02:00
DizzyEggg
18db0cb3b7 controller string 2023-08-05 22:41:13 +02:00
DizzyEggg
f9e131b6ac fix recorded, exp update the same for player partner 2023-08-05 21:34:17 +02:00
DizzyEggg
0b4c1aa275 more work on controllers 2023-08-05 20:42:19 +02:00
DizzyEggg
1793b9e1da more controller functions 2023-08-05 14:11:25 +02:00
DizzyEggg
a505cd7fb9 simplify the get mon set mon data functions more 2023-08-05 12:53:14 +02:00
DizzyEggg
cbebdf044a handle se, bgm and fainting cry 2023-08-05 12:13:50 +02:00
DizzyEggg
c4bfe40da6 remove empty controller functions 2023-08-05 11:39:42 +02:00
DizzyEggg
5a8b6c18ef ball throw and start removing empty controller functions 2023-08-05 11:05:37 +02:00
Eclipse
5226935857
Fixed Trainer class ball not assigned to second Pokémon (#3203) 2023-08-04 22:56:05 -04:00
GriffinR
41847cd5aa STAT_ANIM constant usage 2023-08-04 16:27:45 -04:00
DizzyEggg
c72bb27325 faint animation 2023-08-04 22:15:39 +02:00
GriffinR
866c32a735 Add temp var aliases 2023-08-04 14:17:28 -04:00
DizzyEggg
7360a4a18a up to return mon to ball 2023-08-04 17:29:29 +02:00
DizzyEggg
7ba8a0216f more work on controllers 2023-08-04 13:42:40 +02:00
ghoulslash
a0dd77dd41
Improve AI switching, so it doesn't get killed on switch-in (#3146) 2023-08-04 07:34:58 -04:00
DizzyEggg
cc30d2fb53 start removing duplicate controller functions 2023-08-04 12:10:38 +02:00
ghoulslash
4ae6ae4de3
Reset all battler IDs at battle start (#3111)
* reset battler IDs before BattleScript_OverworldTerrain and BattleScript_OverworldWeatherStarts to prevent playanimation from executing on invalid battler ids

* replace BS_SCRIPTING with BS_BATTLER_0 in BattleScript_OverworldTerrain and BattleScript_OverworldWeatherStarts

---------

Co-authored-by: ghoulslash <pokevoyager0@gmail.com>
2023-08-04 08:57:06 +02:00
GriffinR
6d4dadd7b5 Add temp flag aliases 2023-08-03 15:55:06 -04:00
DizzyEggg
e7bc42fcaf use IsValidForBattle 2023-08-03 21:17:39 +02:00
LOuroboros
0bace94dc7
Updated Cmd_jumpifsideaffecting 2023-08-03 14:46:45 -03:00
GriffinR
16c0be7ed2 Fix some frontier gfx, adjacent cleanup 2023-08-03 11:15:15 -04:00
Martin Griffin
cd51471c96
Revamped GetTotalAccuracy (#3182) 2023-08-02 12:19:36 +01:00
sbird
1d8ad1b756 [battle, movesets] revert bulbasaur's level up change 2023-08-02 09:51:45 +02:00
Eduardo Quezada
f94efa94e1 Merge branch 'RHH/master' into RHH/upcoming 2023-08-02 01:18:07 -04:00
ghoulslash
7a814999e5 MOVE_CORROSIVE_GAS Effect (#3152)
# Conflicts:
#	data/battle_anim_scripts.s
#	data/battle_scripts_1.s
#	include/constants/battle_move_effects.h
2023-08-02 01:05:54 -04:00
Eduardo Quezada
87050d8c08 Fix Stamina/Wind Power/Electromorphosis/Rattled issues with targets (#3143) 2023-08-01 23:54:04 -04:00
Philipp AUER
44eb6260cc
[battle, anim] woodhammer animation overhaul (#3192)
* [battle, anim] woodhammer animation overhaul

* squashme: timings

---------

Co-authored-by: sbird <sbird@no.tld>
2023-08-01 19:10:18 -04:00
Eduardo Quezada
f8c0f91c66 Using RGB color constants where appropiate 2023-07-31 15:33:14 -04:00
Eduardo Quezada D'Ottone
54816816a0
Fixed null dereferencing errors with -fanalyzer on modern (#3165) 2023-07-31 14:49:08 -04:00
DizzyEggg
5eec3b2fc3
fix various issues with primal weather blocking water/fire type moves (#3138)
* fix various issues with primal weather blocking water/fire type moves

* forgot to change return to effect=1

* fix bugs
2023-07-30 10:50:51 -04:00
Eduardo Quezada D'Ottone
8196bea2d7
Pret merge 23-07-25 (#3176) 2023-07-30 10:46:23 -04:00
Alex
5167b01b14 var for ability + hold effect, loaded dice comparison
fix for small bug introduced in the latest commit
2023-07-29 23:36:01 +02:00
LOuroboros
4a657c7eaf Revamped GetTotalAccuracy 2023-07-29 17:22:10 -03:00
Alex
5fa7a6d4c6 Skill Link Tests, Loaded Dice stuff 2023-07-28 13:20:06 +02:00
DizzyEggg
1baa57418e
Fixed copyright screen not showing up on certain emulators (#2664)
* Fix old intro not showing up on VBA

* Update intro.c

* Update intro.c

* Update intro.c
2023-07-26 21:33:01 -04:00
Eduardo Quezada
8dafc5e208 Fixed B_ATK_TRAINER_NAME not working properly in tests 2023-07-26 17:36:37 -04:00
Alex
bca29d8586 Adds Mortal Spin and Population Bomb 2023-07-26 17:37:56 +02:00
DizzyEggg
a3d6e31227 Merge branch 'rattled' into stamina_fix 2023-07-26 09:36:46 +02:00
DizzyEggg
c11839c648 Use isValidForBattle 2023-07-26 09:34:23 +02:00
DizzyEggg
7b7cbf506d Merge branch 'upcoming' into ai_switching 2023-07-26 09:23:53 +02:00
Martin Griffin
0e5c78aeb6 Merge remote-tracking branch 'pret/master' into 'rhh/master' 2023-07-25 19:49:18 +01:00
Eduardo Quezada
ad78dfcf68 Merge branch 'RHH/master' into RHH/upcoming
# Conflicts:
#	src/battle_script_commands.c
#	src/battle_util.c
2023-07-25 14:38:53 -04:00
Alex
da9b421ae1
Fix Ruin ability calcs (#3171) 2023-07-25 09:59:26 +02:00
Martin Griffin
31a3ada7de Detect potential misalignment in modern 2023-07-24 19:42:56 +01:00
Martin Griffin
b53cca1a06
Declarations for 2- and 3-argument GetMonData (#1756)
* Type-safe GetMonData/GetBoxMonData

* Comments
2023-07-24 09:57:37 -04:00
ghoulslash
b5431898c2
RNG for Metronome, multi-hit moves, and Loaded Dice (#3159) 2023-07-23 08:15:14 -04:00
Martin Griffin
fc321965a9 RNG_HITS and RNG_LOADED_DICE 2023-07-23 10:24:58 +01:00
ghoulslash
f5d5e544d1
Fix trainer slide messages appearing for frontier trainers (#3162) 2023-07-23 04:37:36 -04:00
gruxor
5a6532ddfb Merge branch 'upcoming-fixes' of https://github.com/gruxor/pokeemerald-expansion into upcoming-fixes 2023-07-22 14:50:12 -04:00
gruxor
3d25dadcd0 Fixed whitespace indent on switches 2023-07-22 14:49:37 -04:00
gruxor
215d57e871
Update src/fieldmap.c
Co-authored-by: LOuroboros <lunosouroboros@gmail.com>
2023-07-22 14:47:07 -04:00
gruxor
4e75f6d454 Minor fix to null check 2023-07-21 16:22:43 -04:00
gruxor
fc8ee625b6 Fixed outstanding UB with -fanalyzer on modern 2023-07-21 15:51:03 -04:00
Alex
ad25dfe1e9
Set otGender + Moves in FillPartnerParty (#3163) 2023-07-21 14:43:39 -04:00
LOuroboros
cd5f997ee3
Added a debug feature to hatch eggs (#3155) 2023-07-21 12:06:05 +02:00
DizzyEggg
e0271a92e9 Fix trainer messages appearing for frontier trainers 2023-07-21 11:40:15 +02:00
Martin Griffin
b406a9c1bd RandomUniformExcept and RNG_METRONOME 2023-07-20 10:25:03 +01:00
Eduardo Quezada
47cea526ec Merge branch 'RHH/master' into RHH/upcoming
# Conflicts:
#	src/battle_util.c
2023-07-19 23:22:07 -04:00
Bassoonian
6d7d7f109e
Fix debug menu memory overflow (#3154) 2023-07-19 17:38:09 -04:00
Bassoonian
7fa6ed8b05 Fix priortiy typos 2023-07-19 17:33:28 +02:00
Alex
6b5d1e7577
Adds some gen9 moves (#3147)
* Adds some gen9 moves

* Fix Test + Tabs

* Collision Course boost changed to 1.3333
2023-07-19 13:25:20 +02:00
Eduardo Quezada D'Ottone
cf29c9eb69
Fixed enemy parties not reverting to their original form post-battle (#3150) 2023-07-19 08:46:57 +02:00
Eclipse
ca792d43cc
Gender differences sprites, final part (#3122)
* The last survivors

* Tweaked Numel, Milotic and Relicanth
Updated their sprites according to their current depictions.

---------

Co-authored-by: Eduardo Quezada D'Ottone <eduardo602002@gmail.com>
2023-07-18 21:31:22 -04:00
DizzyEggg
f4dc5e931f some more stuff 2023-07-18 12:01:25 +02:00
DizzyEggg
1bd4f9c7a8 rework incoming surviability 2023-07-18 11:36:09 +02:00
Eduardo Quezada D'Ottone
b08c8f85fc
Fixed Utility Umbrella damage calculations (#2835)
* Fixed Utility Umbrella holders not receiving regular damage when being hurt by what would've been weakened rain/sun attacks

* Fixed reading move incorrectly

* Tests: Sun, Rain, Utility Umbrella and Hydro Steam

* [STASH] Skeli changes, needs to remake tests

* Fixed tests

* Removed redundant tests

* Removed unused variable

* Removed Primal Todo tests
2023-07-18 09:22:05 +02:00
Eduardo Quezada D'Ottone
6fec0e4dd1
Ported TheXaman's latest changes to the Debug Menu (#2815)
* Added option for generating incrementing pokemon in pc boxes

# Conflicts:
#	src/debug.c

* added submenu arrows, increased menu high to full screen

# Conflicts:
#	src/debug.c

* combined flags and vars into one submenu

# Conflicts:
#	src/debug.c

* added new window to flags/vars showing the current state and added submenu indicator

# Conflicts:
#	src/debug.c

* added alligned arrows for debug submenus

# Conflicts:
#	src/debug.c

* used {CLEAR_TO X} instead of manual spaces

# Conflicts:
#	src/debug.c

* renamed gDebugText to proper sDebugText

# Conflicts:
#	src/debug.c

* added Fill submenu, added fill function for PC items and all bag pockets  @LOuroboros

# Conflicts:
#	src/debug.c

* put cheat start into utility

# Conflicts:
#	src/debug.c

* put fill submenu into main menu

# Conflicts:
#	src/debug.c

* tiny fix

* renaming and reordering

# Conflicts:
#	src/debug.c

* Added reset pokedex flags for @AsparagusEduardo

* made flag toggle list dynamic

# Conflicts:
#	src/debug.c

* initial battle debug menu WIP

# Conflicts:
#	src/debug.c
#	src/wild_encounter.c

* fix visual bug

* added battle start

# Conflicts:
#	include/debug.h
#	src/battle_ai_script_commands.c

* Added faster way to add initial movesets to mon

* Added waiting music for the slow box filling

* Simplified the call to scripts

* Simplified debug scripts

* Disabled Battle Test for now

* Fixed personality on fast PC fill being always 0

* Removed BATTLE_ENGINE instances + added AI_FLAG_COUNT

* Added missing return TRUE

* Sets nickname

* Changed how GetSpeciesName to how it's used upstream

---------

Co-authored-by: TheXaman <48356183+TheXaman@users.noreply.github.com>
2023-07-18 09:17:03 +02:00
Eduardo Quezada D'Ottone
43ad1a4d3b
Unified multi-strike move flags (#3126)
* Unified twoStrikes and threeStrikes flags into strikeCount

* Decreased strikeCount max from 255 to 15.
2023-07-18 09:07:14 +02:00
Alex
38655b9d1f
Fix gem boost on multi hit moves and config for gem param (#3144) 2023-07-18 06:11:54 +01:00
DizzyEggg
04feba8314 test for electromorphosis, small fix for wind power 2023-07-17 16:30:59 +02:00
DizzyEggg
c0f10623d6 Merge branch 'be/staminafix' of https://github.com/ghoulslash/pokeemerald into stamina_fix 2023-07-17 15:35:40 +02:00
Alex
330e20b9e9
Fix Protosynthesis and Quark Drive boosts (#3139)
* Fix Protosynthesis and Quark Drive boosts

* Added Tests + fix newly introduced bug in the PR

Add unintentionally deletet break

new line
2023-07-17 11:10:13 +02:00
DizzyEggg
1f1d24b3e4
Fix Primal Reversion not activating when switching in after fainting (#3141)
* Fixed Primal Reversion not activating when switching in after a fainting
* add tests for primal reversion

Co-authored-by: Eduardo Quezada <eduardo602002@gmail.com>
2023-07-16 12:26:54 +01:00
Martin Griffin
17f8f50a59 Merge remote-tracking branch 'rhh/master' into upcoming 2023-07-16 07:46:34 +01:00
Eclipse
fb8989414f
Fixed Mega Venasaur icon (#3137) 2023-07-16 02:40:21 -04:00
DizzyEggg
3c5c68ac58
Fix how AI categorizes Weak moves and give priority to always hits moves when needed (#3109)
* ai weak move fix and always hits move prioritarizing
2023-07-16 07:24:59 +01:00
Martin Griffin
58ede15263
Fix Roullout Fury Cutter AI power calc (#3110) 2023-07-16 06:45:35 +01:00
Martin Griffin
c4057cb0e0
Fix Metronome's/Mirror Move's called move to take powder moves / multi hit moves into account (#3135) 2023-07-16 06:41:18 +01:00
DizzyEggg
2a249654e7 fix mirror move/metronome powder/multi hit moves & tests 2023-07-15 14:00:55 +02:00
Martin Griffin
e9bd8979b0 More efficient Random calls in Shuffle 2023-07-14 18:57:19 +02:00
Eduardo Quezada
168b005406 Merge branch 'RHH/master' into RHH/upcoming 2023-07-14 12:40:01 -04:00
SonikkuA-DatH
6382640f8a
Castform, Cherrim Sun, Spinda, and Spheal Graphical Tweaks (#3127)
* Casrform graphics. Palette changes, edited backs, and 2 Frame anims

* Castform Graphics

* Cherrim graphics, and Castform redefinitions

* Spheal and Spinda Graphic edits. Spheal mouth adjustment, Spinda 2 frame and palette

* Revised Spinda Spot drawing function, removed tabs

* Animations for Castform forms, Spinda, Cherrim Sun, and Spheal set

* Spacing

* Forgot shiny pal. Fixed

* Delete .vs directory

* remove vs ref
2023-07-14 11:45:40 -04:00
Martin Griffin
96159d189f
Clear fixedPopup when gTestRunnerHeadless (#3133)
Previously fixedPopup = FALSE was unconditional, but it was erroneously
changed in f1b9872bf0.
2023-07-14 11:26:19 -04:00
DizzyEggg
0c0b841a80
Remove debug item effect override (#3106) 2023-07-13 18:47:01 -04:00
Eduardo Quezada D'Ottone
0efc9a29ad
Disabled species now default their graphics to SPECIES_NONE (#3116) 2023-07-12 20:11:07 -04:00
Eduardo Quezada
3aaa89ce71 Changed all instances of gSpeciesNames so that it uses GetSpeciesName 2023-07-07 14:37:51 -04:00
Eduardo Quezada
adfc0af372 Mon graphics are now loaded depending on their availability
- If it has a female sprite/palette, it's loaded.
- If it the species is enabled and it has a sprite/palette, it's loaded.
- Otherwise, load the SPECIES_NONE graphics.
2023-07-07 14:36:30 -04:00
sbird
6482279fa3 [battle, math] refactor damage calculation to use proper fp type and inlined multiplication 2023-07-07 18:51:23 +02:00
Eduardo Quezada
404b18564f Merge branch 'RHH/master' into RHH/upcoming 2023-07-06 15:28:41 -04:00
DizzyEggg
98ae1beaec
Fix ability pop-up properly updating text (#3107) 2023-07-06 15:10:28 -04:00
DizzyEggg
cf9b933a5f
Fix Z-Moves softlocking when the z move effect was not used (#3108) 2023-07-06 15:08:28 -04:00
Eduardo Quezada
4405f79d24 Merge branch 'RHH/master' into RHH/upcoming 2023-07-06 13:15:06 -04:00
Eduardo Quezada
f21953f254 Merge remote-tracking branch 'pret/master' into RHH/master 2023-07-06 13:06:31 -04:00
DizzyEggg
9a09f1e3b9 Fix Roullout Fury Cutter AI power calc 2023-07-06 13:41:16 +02:00
Eduardo Quezada
4bbb3a1e51 Merge branch 'RHH/master' into RHH/upcoming 2023-07-05 19:28:37 -04:00
Eduardo Quezada
b10b5fd9c3 EVERYTHING_CUSTOMIZED -> TRAINER_PARTY 2023-07-05 18:31:08 -04:00
Eduardo Quezada
e8487961c7 TrainerMonCustomized -> TrainerMon 2023-07-05 18:29:28 -04:00
Eduardo Quezada
b86184a4f6 Removed TrainerMonPtr 2023-07-05 18:23:18 -04:00
Eduardo Quezada
2f9e0ecd9f Removed uses of F_TRAINER_PARTY_EVERYTHING_CUSTOMIZED 2023-07-05 18:22:48 -04:00
ghoulslash
1a53154324
Beat Up AI Damage Calc (#3104)
* add specific AI dmg calc for new beat up

* beat up ai calc optimizations

---------

Co-authored-by: ghoulslash <pokevoyager0@gmail.com>
2023-07-05 20:59:42 +02:00
DizzyEggg
34aff01d3a
Fix graphical/exp bugs with 2 vs 1 trainer battles (#3105) 2023-07-05 14:52:24 -04:00
Martin Griffin
eab4e32e2a
Shuffle implementation (#3097) 2023-07-05 19:46:40 +02:00
Eduardo Quezada
0b3c7b7d3b Converted IV fields to the current system 2023-07-04 21:49:06 -04:00
Eduardo Quezada
3dd7a2c09e Removed TrainerMonNoItemDefaultMoves 2023-07-04 21:29:58 -04:00
Eduardo Quezada
9c961b4fd5 Removed TrainerMonNoItemCustomMoves 2023-07-04 21:22:27 -04:00
Eduardo Quezada
1ef56f6ae1 Removed TrainerMonItemDefaultMoves 2023-07-04 21:16:47 -04:00
Eduardo Quezada
c201cae2ee Removed TrainerMonItemCustomMoves 2023-07-04 21:06:55 -04:00
Eduardo Quezada D'Ottone
862602233d
Gender differences sprites, part 3 (#3095) 2023-07-04 11:36:24 -04:00
ghoulslash
cc3a6d4d94
make special case ABILITYEFFECT_xx ids their own caseId switch cases to fix potential overlap with ability IDs 0xFF etc (#3083)
Co-authored-by: ghoulslash <pokevoyager0@gmail.com>
2023-07-03 10:03:50 +02:00
Eduardo Quezada D'Ottone
1fa9a05470
Convert move flags and bans into GCC bitfields (#2952)
* Slicing moves to new bitfield

* Wind moves to new bitfield

* Two-strike moves to new bitfield

* Forgot to add flagTwoStrikes to battle_moves.h

* Removed "flag" from field names

* FLAG_HIT_IN_SUBSTITUTE and FLAG_THAW_USER

* Airborne moves

* FLAG_POWDER, FLAG_TARGET_ABILITY_IGNORED and FLAG_DANCE

* FLAG_BALLISTIC and FLAG_PROTECTION_MOVE

* Fixed missing uses of MOVE_UNAVAILABLE in battle_ai_util.c

* FLAG_SOUND

* FLAG_DMG_UNDERGROUND and FLAG_DMG_UNDERWATER

* FLAG_DMG_MINIMIZE

* Cleanup

* FLAG_STAT_STAGES_IGNORED

* Updated Pollen Puff's ballistic flag

* FLAG_STRONG_JAW_BOOST and FLAG_MEGA_LAUNCHER_BOOST

* thaw

* FLAG_THREE_STRIKES

* FLAG_IRON_FIST_BOOST

* FLAG_RECKLESS_BOOST

* FLAG_HIGH_CRIT

* Removed empty flags

* Moves that fail when called by Me First + added missing Shell Trap

* Moves that fail when Gravity is active

* Better names for banned fields

* Moves that fail when called by Instruct

* Cleanup

* Contact Moves + Fixed Wandering Spirit skipping contact checks

* Inverted FLAG_PROTECT_AFFECTED so that there's a flag for moves that SKIP protect.

* Simplified B_MOVE_FLAGS configs

* FORBIDDEN_METRONOME

* Renamed hitsPastSubstitute to ignoresSubstitute

* FORBIDDEN_PARENTAL_BOND

* Struggle uncallable by Metronome

* FORBIDDEN_MIMIC

* FLAG_KINGS_ROCK_AFFECTED

* Made a single config for move flags

* Macro for checking move flags

* FLAG_MAGIC_COAT_AFFECTED

* Fixed HasMagicCoatAffectedMove

* FLAG_SNATCH_AFFECTED

* Removed unused EFFECT_FLINCH_MINIMIZE_HIT

* Fixed Stench/King's Rock interaction

* Removed sMovesNotAffectedByStench in favor of checking move effects

* Removed EFFECT_TWISTER, which was a repeat of EFFECT_FLINCH_HIT

* Changed Gen2 configs to less than Gen 3

* FORBIDDEN_SLEEP_TALK

* Cleanup

* Inverted FLAG_MIRROR_MOVE_AFFECTED

* FLAG_SHEER_FORCE_BOOST

* Ordered

* FORBIDDEN_ASSIST and FORBIDDEN_COPYCAT

* Removed TestMoveFlags and TestMoveFlagsInMoveset + flags field

* Fixed Triple Arrows test
2023-07-03 10:01:59 +02:00
gruxor
68ce97cd90
Fixed shadows in viewer (#3094)
* Fixed shadows in viewer + minor arg signature fix

* Unfixed castform functions, upcoming removal
2023-07-02 19:41:47 -04:00