Implement native opening scenes, battle foundation and overworld movement
Checks / web (push) Canceled after 0s
Checks / web (push) Canceled after 0s
This commit is contained in:
1 parent
8b80d05ca2
commit
c08d250cf6
39 files changed
+10727
-1524
No files matched your search
+205
-1
@@ -16,9 +16,213 @@ export const SYMBOLS = {
|
||||
sprites: 0x14736,
|
||||
facings: 0x4049,
|
||||
standardScripts: 0xbc000,
|
||||
mapScenes: 0x4d01e,
|
||||
specials: 0xc029,
|
||||
emotes: 0x1444d,
|
||||
landmarks: 0x1ca8c3,
|
||||
weekdayNames: 0x909f2,
|
||||
whatDayText: 0x90a3f,
|
||||
isItDayText: 0x90a4f,
|
||||
dstConfirmText: 0x90a83,
|
||||
timeConfirmText: 0x90ab7,
|
||||
baseData: 0x51424,
|
||||
pokemonNames: 0x53384,
|
||||
pokemonPics: 0x120000,
|
||||
picsBanks: 0x511d4,
|
||||
pokemonPalettes: 0xa8ce,
|
||||
growthRates: 0x50efa,
|
||||
evosAttacks: 0x425b1,
|
||||
moves: 0x41afb,
|
||||
moveNames: 0x1c9f29,
|
||||
itemNames: 0x1c8000,
|
||||
itemAttributes: 0x67c1,
|
||||
itemPocketNames: 0x9701c,
|
||||
giveItemScript: 0x96f77,
|
||||
putItemInPocketText: 0x9705b,
|
||||
pocketIsFullText: 0x97060,
|
||||
caughtAskNicknameText: 0x4db44,
|
||||
nicknameStrings: 0x11780,
|
||||
wildBattleScript: 0x97cf9,
|
||||
battleWhiteoutScript: 0x124c1,
|
||||
spawnPoints: 0x152ab,
|
||||
johtoGrassWildMons: 0x2a5e9,
|
||||
grassMonProbTable: 0x2a1cb,
|
||||
grassCollisions: 0x149ea,
|
||||
} as const;
|
||||
|
||||
/** The currently ported area. Story callbacks are not executed yet. */
|
||||
/** Assembly routines that scripts `callasm` but that do nothing. */
|
||||
export const EMPTY_ROUTINES = {
|
||||
giveItemDummy: 0x96f76,
|
||||
battleBGMap: 0x1250a,
|
||||
} as const;
|
||||
|
||||
/** Assembly routines that scripts `callasm`, translated natively. */
|
||||
export const NATIVE_ROUTINES = {
|
||||
halveMoney: 0x12513,
|
||||
getWhiteoutSpawn: 0x12527,
|
||||
} as const;
|
||||
|
||||
/** Native handlers are selected by the routine a special index points to,
|
||||
* so the ROM's own special table remains the source of truth. */
|
||||
export const SPECIAL_ROUTINES = {
|
||||
restartMapMusic: 0x3d47,
|
||||
setDayOfWeek: 0x90913,
|
||||
initialSetDst: 0x90a54,
|
||||
initialClearDst: 0x90a88,
|
||||
toggleDecorationsVisibility: 0x27043,
|
||||
toggleMaptileDecorations: 0x26feb,
|
||||
fadeOutToWhite: 0x8c084,
|
||||
healParty: 0xc658,
|
||||
warpToSpawnPoint: 0x97c28,
|
||||
} as const;
|
||||
|
||||
/** Work RAM addresses that the event and text formats name as operands. */
|
||||
export const RAM = {
|
||||
stringBuffer1: 0xd073,
|
||||
stringBuffer2: 0xd086,
|
||||
stringBuffer3: 0xd099,
|
||||
stringBuffer4: 0xd0ac,
|
||||
stringBuffer5: 0xd0bf,
|
||||
playerName: 0xd47d,
|
||||
momsName: 0xd488,
|
||||
rivalName: 0xd493,
|
||||
battleMonNickname: 0xc621,
|
||||
enemyMonNickname: 0xc616,
|
||||
curPartyLevel: 0xd143,
|
||||
monOrItemNameBuffer: 0xd050,
|
||||
} as const;
|
||||
|
||||
/** Event constants named directly by translated special routines. */
|
||||
export const EVENTS = {
|
||||
playersRoomPoster: 716,
|
||||
playersHouseConsole: 1857,
|
||||
playersHouseDoll1: 1858,
|
||||
playersHouseDoll2: 1859,
|
||||
playersHouseBigDoll: 1860,
|
||||
} as const;
|
||||
|
||||
/** Battle engine tables and texts, keyed by their PRET labels so that
|
||||
* \`npm run check:reference\` can verify each address by name. */
|
||||
export const BATTLE = {
|
||||
AccuracyLevelMultipliers: 0x34eb2,
|
||||
AlreadyAsleepText: 0x811c1,
|
||||
AlreadyConfusedText: 0x80dcc,
|
||||
AlreadyParalyzedText: 0x81592,
|
||||
AlreadyPoisonedText: 0x811fa,
|
||||
AlwaysFleeMons: 0x3c5b1,
|
||||
AskForgetMoveText: 0x667f,
|
||||
AttackMissed2Text: 0x81033,
|
||||
AttackMissedText: 0x81020,
|
||||
"BattleCommand_StatDownMessage.BattleStatFellText": 0x36415,
|
||||
"BattleCommand_StatDownMessage.BattleStatSharplyFellText": 0x36410,
|
||||
"BattleCommand_StatDownMessage.stat": 0x363fe,
|
||||
"BattleCommand_StatUpMessage.BattleStatWentUpText": 0x363e4,
|
||||
"BattleCommand_StatUpMessage.BattleStatWentWayUpText": 0x363df,
|
||||
"BattleCommand_StatUpMessage.stat": 0x363cd,
|
||||
BattleMonNicknameText: 0x3f2ef,
|
||||
BattleText_CantEscape: 0x80ba0,
|
||||
BattleText_CantEscape2: 0x80b3b,
|
||||
BattleText_EnemyMonFainted: 0x809a8,
|
||||
BattleText_GotAwaySafely: 0x80b77,
|
||||
BattleText_ItemHealedConfusion: 0x80dab,
|
||||
BattleText_MonFainted: 0x80a75,
|
||||
BattleText_MonHasNoMovesLeft: 0x80c72,
|
||||
BattleText_StringBuffer1GrewToLevel: 0x80c9c,
|
||||
BattleText_TargetRecoveredWithItem: 0x80880,
|
||||
BattleText_TheMoveIsDisabled: 0x80c5b,
|
||||
BattleText_TheresNoPPLeftForThisMove: 0x80c39,
|
||||
BattleText_WildFled: 0x807bd,
|
||||
BecameConfusedText: 0x80d97,
|
||||
BoostedExpPointsText: 0x3f12c,
|
||||
ButItFailedText: 0x814f0,
|
||||
ConfusedNoMoreText: 0x80d81,
|
||||
ConsumableEffects: 0x271de,
|
||||
CriticalHitChances: 0x346ab,
|
||||
CriticalHitMoves: 0x346a3,
|
||||
CriticalHitText: 0x81086,
|
||||
DefrostedOpponentText: 0x8124b,
|
||||
DidNotLearnMoveText: 0x667a,
|
||||
DidntAffect1Text: 0x8150c,
|
||||
DidntAffect2Text: 0x81520,
|
||||
DisabledMoveText: 0x80f02,
|
||||
DisabledNoMoreText: 0x80d39,
|
||||
DoesntAffectText: 0x81071,
|
||||
EnemyText: 0x1295,
|
||||
ExpPointsText: 0x3f131,
|
||||
FastAsleepText: 0x80ce7,
|
||||
FellAsleepText: 0x811b1,
|
||||
FlinchedText: 0x80d1a,
|
||||
FrozenSolidText: 0x80d06,
|
||||
FullyParalyzedText: 0x8157d,
|
||||
GoMonText: 0x3f2d1,
|
||||
HasNoPPLeftText: 0x80fba,
|
||||
HeldStatusHealingEffects: 0x3de44,
|
||||
HPIsFullText: 0x81534,
|
||||
HungOnText: 0x80e99,
|
||||
HurtByBurnText: 0x807f8,
|
||||
HurtByPoisonText: 0x807e2,
|
||||
HurtItselfText: 0x80d5f,
|
||||
IdentifiedText: 0x816b1,
|
||||
IsConfusedText: 0x80d4f,
|
||||
"IsHMMove.HMMoves": 0x34f0,
|
||||
ItemAttributes: 0x67c1,
|
||||
ItFailedText: 0x81500,
|
||||
LearnedMoveText: 0x666b,
|
||||
MoveAskForgetText: 0x6670,
|
||||
MoveCantForgetHMText: 0x669a,
|
||||
MoveEffectPriorities: 0x3c5df,
|
||||
MoveEffectsPointers: 0x271f4,
|
||||
MoveGrammar: 0x105e7a,
|
||||
MoveNameText: 0x105e23,
|
||||
"MoveNameText.endusedmovetexts": 0x105e39,
|
||||
MustRechargeText: 0x80d27,
|
||||
NoPPLeftText: 0x80f99,
|
||||
NothingHappenedText: 0x814d9,
|
||||
NotVeryEffectiveText: 0x810c1,
|
||||
OftenFleeMons: 0x3c5a8,
|
||||
OneHitKOText: 0x81097,
|
||||
ParalyzedText: 0x81558,
|
||||
"PrintTempMonStats.StatNames": 0x50bb5,
|
||||
ProtectedByMistText: 0x81321,
|
||||
ProtectedByText: 0x815a9,
|
||||
ProtectingItselfText: 0x8167a,
|
||||
RageBuildingText: 0x810f3,
|
||||
RecoveredUsingText: 0x80bc2,
|
||||
RegainedHealthText: 0x8100c,
|
||||
SafeguardProtectText: 0x81733,
|
||||
SometimesFleeMons: 0x3c59a,
|
||||
StatLevelMultipliers: 0x364e6,
|
||||
StatNames: 0x364a6,
|
||||
StopLearningMoveText: 0x6675,
|
||||
SuckedHealthText: 0x81210,
|
||||
SuperEffectiveText: 0x810aa,
|
||||
Text_1_2_and_Poof: 0x6684,
|
||||
"Text_1_2_and_Poof.MoveForgotText": 0x6695,
|
||||
Text_MonGainedExpPoint: 0x3f11b,
|
||||
TypeBoostItems: 0x35703,
|
||||
TypeMatchups: 0x34bb1,
|
||||
UnaffectedText: 0x81061,
|
||||
UsedMove1Text: 0x105e04,
|
||||
UsedMove2Text: 0x105e0b,
|
||||
UsedMoveText: 0x105db9,
|
||||
"UsedMoveText_CheckObedience.UsedInsteadText": 0x105e1a,
|
||||
WasBurnedText: 0x8123c,
|
||||
WasPoisonedText: 0x811d5,
|
||||
WildPokemonAppearedText: 0x80746,
|
||||
WokeUpText: 0x80cfa,
|
||||
WontDropAnymoreText: 0x8128f,
|
||||
WontRiseAnymoreText: 0x81272,
|
||||
} as const;
|
||||
|
||||
export const MAP_GROUP_COUNT = 26;
|
||||
export const NUM_POKEMON = 251;
|
||||
export const NUM_ITEMS = 190;
|
||||
/** The last group has no following pointer to bound it. */
|
||||
export const LAST_MAP_GROUP_SIZE = 11;
|
||||
|
||||
/** Areas whose rules, scripts and presentation are ported. Other decoded
|
||||
* maps remain unavailable; the label only distinguishes interiors that share
|
||||
* a ROM landmark name. */
|
||||
export const NATIVE_MAPS: Record<string, string> = {
|
||||
"24:4": "New Bark Town",
|
||||
"24:5": "Elm’s lab",
|
||||
|
||||
Reference in new issue
Block a user