25 Commits

Author SHA1 Message Date
Alex
c80a41b730
Suppress trainerproc compile warning for unused func (#7592) 2025-08-21 17:31:59 +02:00
grintoul
916f083852
Added trainerBackPic to Trainer struct to de-couple trainer pic and trainer back pic defines (#7425) 2025-08-13 11:02:41 +02:00
hedara90
469a0b476a
Update trainer.h usage warning (#7439)
Co-authored-by: Hedara <hedara90@gmail.com>
2025-08-02 11:54:39 +01:00
hedara90
05b1db8cc6
trainerproc copy other trainer party (#7251) 2025-07-18 15:57:57 +01:00
Hedara
84972342d6 Add 'Macro' key to trainerproc 2025-06-18 21:51:46 +02:00
Hedara
90aed43c27 Merge branch 'master' into master-upcoming
Conflicts:
	.github/ISSUE_TEMPLATE/01_battle_engine_bugs.yaml
	.github/ISSUE_TEMPLATE/02_battle_ai_issues.yaml
	.github/ISSUE_TEMPLATE/03_feature_requests.yaml
	.github/ISSUE_TEMPLATE/04_other_errors.yaml
	.github/pull_request_template.md
	src/battle_controller_player.c
	src/battle_main.c
	src/battle_script_commands.c
	src/battle_util.c
	src/data/graphics/pokemon.h
	src/data/pokemon/species_info/gen_9_families.h
	test/battle/ability/flower_veil.c
	test/battle/ability/sweet_veil.c
	test/battle/ability/synchronize.c
	test/battle/ability/water_bubble.c
	test/battle/move_effect/fell_stinger.c
	test/battle/move_effect/level_damage.c
	test/battle/move_effect/magic_room.c
	test/battle/move_effect/me_first.c
	test/battle/move_effect/sky_drop.c
	test/battle/move_effect/smack_down.c
	test/battle/move_effect/wish.c
	test/battle/move_flags/ignore_type_if_flying_and_ungrounded.c
2025-05-22 15:41:08 +02:00
jfb1337
ce9bbcc3b7
Fix trainers.party parser failing on apostrophes (#6938) 2025-05-21 10:41:18 +02:00
Eduardo Quezada
406fd7ce81
Expand trainerproc to support additional battle types (#6770)
Co-authored-by: Alex <93446519+AlexOn1ine@users.noreply.github.com>
2025-05-17 15:08:44 +02:00
Pawkkie
3f5335c4ba
Refactor AI flags to u64 (#6753)
Co-authored-by: DizzyEggg
2025-05-04 17:16:34 +02:00
hedara90
88986baf5f
Trainer Party Pools (#5731)
Co-authored-by: Hedara <hedara90@gmail.com>
2025-01-25 13:28:46 +01:00
Eduardo Quezada
f6a86a65ef Merge branch '_RHH/master' into _RHH/upcoming 2025-01-19 10:32:57 -03:00
Eduardo Quezada
17e224343f
Fixed whitespace issue with trainerproc (#6042) 2025-01-17 22:04:16 +01:00
psf
a7f77ed08d
Adds B_VAR_DIFFICULTY and related functions READ DESC (#5337)
Co-authored-by: sbird <sbird@no.tld>
Co-authored-by: Philipp AUER <SBird1337@users.noreply.github.com>
Co-authored-by: Martin Griffin <martinrgriffin@gmail.com>
Co-authored-by: hedara90 <90hedara@gmail.com>
2025-01-04 14:25:03 +01:00
Alex
3db351359a
Clean up redundancy for mugshots (#5906) 2024-12-30 18:32:21 +01:00
Martin Griffin
c714caa27a
trainerproc: Fix showing incorrect error context (#5769) 2024-12-04 19:22:35 +01:00
cawtds
632ef149e0
Handle showdowns apostrophe the same way as ASCII apostrophe (#5712) 2024-11-24 20:42:14 +01:00
Martin Griffin
a5e0738484
trainerproc: Parse line markers (#5122) 2024-08-08 20:12:18 +02:00
Martin Griffin
5b251b614c trainerproc: Support Ogerpon 2024-07-25 14:50:32 +01:00
hedara90
3f4b4adae5
Updated reference to config location to new location (#5026)
Co-authored-by: Hedara <hedara90@gmail.com>
2024-07-23 14:09:32 -04:00
Alex
5e2e2e9fce
Minor shouldUseGimmick refactor (#4962) 2024-07-13 20:56:18 +02:00
AgustinGDLV
9797640dff
Gimmick Refactor (#4449)
* consolidated gimmick checks, triggers, communication, and activation; updated test runner

* fixed improper use of .usableGimmick

* cleaning up battle_dynamax.c, changing function args to u32s

* fixed '#ifdef TESTING' causing errors

* updated z-moves to use gimmick interface, pared down redundancies; no AI/tests

* added support for z-moves in tests, consolidated gimmick fields

* removed ShouldUseMaxMove and .usingMaxMove

* renamed TryChangeZIndicator, updated z move display

* added several z-move tests and fixed various z-move interactions; fixed z-move category calc

* fixed useless battler arg in GetTypeBasedZMove

* added basic test check for bad Z-Move or Mega usage

* reworked test runner gimmick functionality; added support for Ultra Burst + Z-Move to test Light That Burns the Sky

* fixed gimmick test logic; fixed damage category override

* fixed mega rayquaza test fail

* consolidated gimmick indicator logic; added graphics to gGimmicksInfo

* removed TeraData struct

* reimplemented AI logic for Z-Moves; no changes

* updated Z-Move and Ultra Burst trigger gfx

* added testrunner check for multiple gimmick use

* fixed duplicate z-move call in test

* reorganized data/graphics/gimmicks.h

* added signature Z-Move ability tests; implemented Guardian of Alola

* fixed bad test update

* fixed Thousand Arrows not affecting Tera Flying; clean-up

* fixed -ate tests

* fixed tera tests

* fixed tera tests really

* fixed last batch of tests

* fixed -ate mega test again

* code review

* code review pt.2

* tweaked CanTera again

* dynamax flag only required for player
2024-06-22 22:25:40 +02:00
Alex
aaaccbfe6c
Adds support for shouldDynamax and shouldTerastal in trainer parties (#4431) 2024-04-23 17:54:46 +01:00
Bassoonian
308475a163
Make trainerproc compatible with partners (#4421)
* Prepare stuff for MGriffin to fix

* Remove doubleBattle from migration script

* Support PARTNER_NONE in trainerproc

* Let script apply to battle_partners.h file

* TRAINER_BACK_PIC

* Let script fix issues

---------

Co-authored-by: Martin Griffin <martinrgriffin@gmail.com>
2024-04-22 17:03:36 +02:00
Eduardo Quezada
d8072795db
Fixed trainerproc skipping numbers when writing species IDs (#4366)
Credit for MGriffin for the fix
2024-04-07 15:10:29 +01:00
Martin Griffin
8bd5ac2e7a
Competitive-formatted parties (#3545)
$ python3 migration_scripts/convert_parties.py src/data/trainers.h src/data/trainer_parties.h src/data/npc_trainers.party
Is available to convert Trainer Control-formatted trainers/parties into
Competitive-formatted ones.

Multiple '#include's can be placed in the trainer section of src/data.c
to support spreading the trainers across multiple .party files.

trainerproc does not interpret the values, leaving that job to the C
compiler, so we use '#line' to associate those errors with the lines in
the .party file(s). Because the columns don't make sense we use
-fno-show-column and -fno-diagostics-show-caret. We might want to move
gTrainers into its own file so that the rest of src/data.c isn't
affected by those flags.

Extensions (misfeatures, imo):
- .party files are passed through cpp, so '#define's are supported, and so
  are '// ...' and '/* ... */' comments.
- .party files also support writing, e.g. 'SPECIES_PIKACHU' instead of
  'Pikachu'. This allows people to write constants explicitly if they
  like.

Pragmas:
- '#pragma trainerproc ivs explicit' requires an explicit 'IVs:' line
  rather than defaulting to 31s.
- '#pragma trainerproc ivs <IVs>' changes the default IVs.
- '#pragma trainerproc level explicit' requires an explicit 'Level:'
  line rather than defaulting to 100.
- '#pragma trainerproc level <level>' changes the default level.

Co-authored-by: Eduardo Quezada <eduardo602002@gmail.com>
Co-authored-by: Alex <93446519+AlexOn1ine@users.noreply.github.com>
2024-04-06 15:05:15 -03:00