Port the remaining battle items, the stats screen and hBattleTurn at the menu

- Run every non-ball item effect usable in battle from the ROM's
  ItemEffects: Full Restore, revives, bitter medicine, Bitter Berry, Ethers
  and Elixers, X items, X Accuracy, Guard Spec, Dire Hit and Poké Doll.
- Read happiness changes from HappinessChanges, including the larger
  level-up gain where a Pokémon was caught.
- Model hBattleTurn at the battle menu, including the trainer AI's writes,
  and drop the status-heal refusal.
- Port the stats screen for battles and Bill's PC.
- Compare the send-out and withdraw texts, RestoreHealth, RestorePP,
  ChangeHappiness and CalcPlayerStats with the original routines.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Sébastien QUEROLandClaude Opus 5.5 committed 2026-09-30 11:24:55 +02:00
1 parent cfd083c16d
commit b13e09ec20
22 files changed
+1547 -171

No files matched your search

+14
View File
@@ -241,6 +241,20 @@ export const C = {
ITEMMENU_PARTY: 5,
PARTYMENUTEXT_HEAL_HP: 0xf5,
PARTYMENUTEXT_HEAL_CONFUSION: 0xf9,
PARTYMENUTEXT_REVIVE: 0xf7,
HAPPINESS_GAINLEVEL: 0x01,
HAPPINESS_USEDXITEM: 0x03,
HAPPINESS_FAINTED: 0x06,
HAPPINESS_BEATENBYSTRONGFOE: 0x08,
HAPPINESS_BITTERPOWDER: 0x0f,
HAPPINESS_ENERGYROOT: 0x10,
HAPPINESS_REVIVALHERB: 0x11,
HAPPINESS_GAINLEVELATHOME: 0x13,
REVIVE: 0x27,
ELIXER: 0x41,
MAX_ELIXER: 0x15,
MAX_ETHER: 0x40,
MYSTERYBERRY: 0x96,
EGG: 0xfd,
WILD_BATTLE: 1,
TRAINER_BATTLE: 2,