From 15cc2d2b9a3cf548d79ef29903ff89d5b76da258 Mon Sep 17 00:00:00 2001 From: AnonymousRandomPerson Date: Thu, 5 Dec 2024 01:52:27 -0500 Subject: [PATCH] Synced from pmdsky-debug --- asm/include/main_02008240.inc | 1 + asm/include/main_0200ED1C.inc | 14 +- asm/include/main_02054C24.inc | 2 +- asm/include/main_0207BC3C.inc | 2 +- asm/include/main_0207F894.inc | 38 +-- asm/include/main_02089694.inc | 1 + asm/include/main_020897DC.inc | 248 +++++++++--------- asm/include/overlay_00.inc | 2 +- asm/include/overlay_29_022DC314.inc | 6 +- asm/include/overlay_29_022EF7C4.inc | 2 +- asm/include/overlay_29_022EFA6C.inc | 2 +- asm/include/overlay_29_022F7388.inc | 38 +-- asm/include/overlay_29_022F9744.inc | 44 ++-- asm/include/overlay_29_022FBB1C.inc | 10 +- asm/include/overlay_29_022FC9C0.inc | 2 +- asm/include/overlay_29_02300108.inc | 2 +- asm/include/overlay_29_023008DC.inc | 2 +- asm/include/overlay_29_023016A8.inc | 4 +- asm/include/overlay_29_02301A84.inc | 2 +- asm/include/overlay_29_02301D78.inc | 2 +- asm/include/overlay_29_02301F50.inc | 12 +- asm/include/overlay_29_02308FE0.inc | 50 ++-- asm/include/overlay_29_0230A9B8.inc | 108 ++++---- asm/include/overlay_29_0230F02C.inc | 12 +- asm/include/overlay_29_0230F9A4.inc | 34 +-- asm/include/overlay_29_0231513C.inc | 28 +- asm/include/overlay_29_02317844.inc | 22 +- asm/include/overlay_29_02318AD4.inc | 4 +- asm/include/overlay_29_02319FB0.inc | 12 +- asm/include/overlay_29_0231A9F8.inc | 12 +- asm/include/overlay_29_0231B1B8.inc | 2 +- asm/include/overlay_29_0231B33C.inc | 74 +++--- asm/include/overlay_29_02320788.inc | 2 +- asm/include/overlay_29_0232145C.inc | 46 ++-- asm/include/overlay_29_02322DDC.inc | 24 +- asm/include/overlay_29_023498A0.inc | 38 +-- asm/include/overlay_29_0234D484.inc | 10 +- asm/itcm.s | 170 ++++++------ asm/main_0200ED1C.s | 24 +- asm/main_0202598C.s | 10 +- asm/main_02054C24.s | 2 +- asm/main_0207BC3C.s | 18 +- asm/main_0207F894.s | 4 +- asm/overlay_00.s | 10 +- asm/overlay_29_022DC314.s | 6 +- asm/overlay_29_022E9618.s | 6 +- asm/overlay_29_022FC9C0.s | 2 +- asm/overlay_29_0230A9B8.s | 2 +- asm/overlay_29_02320788.s | 4 +- lib/asm/crt0.s | 4 +- lib/asm/include/crt0.inc | 2 +- .../sync_pmdsky_debug/pmdsky_debug_reader.py | 1 + tools/sync_pmdsky_debug/symbol_details.py | 6 + .../sync_pmdsky_debug/sync_to_pmdsky_debug.py | 13 +- tools/sync_pmdsky_debug/xmap_reader.py | 4 +- 55 files changed, 608 insertions(+), 594 deletions(-) diff --git a/asm/include/main_02008240.inc b/asm/include/main_02008240.inc index 6f70f09b..3f59c932 100644 --- a/asm/include/main_02008240.inc +++ b/asm/include/main_02008240.inc @@ -1 +1,2 @@ #pragma once + diff --git a/asm/include/main_0200ED1C.inc b/asm/include/main_0200ED1C.inc index 4bb3f064..88c6a553 100644 --- a/asm/include/main_0200ED1C.inc +++ b/asm/include/main_0200ED1C.inc @@ -300,6 +300,7 @@ .public BAG_ITEMS_PTR_MIRROR .public BulkItemToItem .public CALCIUM_STAT_BOOST +.public CopyAndInterleave .public CopyBitsFrom .public CopyBitsTo .public CopyStringFromId @@ -335,6 +336,7 @@ .public DUNGEON_MOVE_TABLES .public DungeonGoesUp .public DungeonSwapIdxToId +.public EnqueueRender3dTexture .public ENTITIES .public EXCLUSIVE_ITEM_ATTACK_BOOSTS .public EXCLUSIVE_ITEM_DEFENSE_BOOSTS @@ -437,6 +439,10 @@ .public MOVE_ACCURACY_STARS_TABLE .public MOVE_POWER_STARS_TABLE .public MultiplyByFixedPoint +.public NewRender3dQuadrilateral +.public NewRender3dRectangle +.public NewRender3dTexture +.public NewRender3dTiling .public ov10_022BDADC .public ov10_022C2528 .public PointsToZero @@ -449,7 +455,7 @@ .public RECOIL_MOVE_LIST .public RECYCLE_SHOP_ITEM_LIST .public RemoveEmptyItems -.public Render3dStack +.public Render3dProcessQueue .public RENDER_3D .public RENDER_3D_FUNCTIONS_64 .public ResumeBgm @@ -467,13 +473,7 @@ .public strlen .public strncmp .public strstr -.public sub_01FF8000 .public sub_01FF80B0 -.public sub_01FF8CAC -.public sub_01FF8D0C -.public sub_01FF8D3C -.public sub_01FF8D6C -.public sub_01FF8D9C .public sub_01FF8F04 .public sub_02002778 .public sub_020027E8 diff --git a/asm/include/main_02054C24.inc b/asm/include/main_02054C24.inc index e274c289..19f609b3 100644 --- a/asm/include/main_02054C24.inc +++ b/asm/include/main_02054C24.inc @@ -220,6 +220,7 @@ .public DRIVER_WORK .public DUNGEON_SWAP_ID_TABLE .public DungeonGoesUp +.public EnqueueRender3dTiling .public ENTITIES .public EVENTS .public ExplorersOfSkyMain @@ -428,7 +429,6 @@ .public StrncpyName .public StrncpySimple .public StrncpySimpleNoPadSafe -.public sub_01FF8CDC .public sub_020018D0 .public sub_02001980 .public sub_02001AB0 diff --git a/asm/include/main_0207BC3C.inc b/asm/include/main_0207BC3C.inc index 740fe070..4346ae86 100644 --- a/asm/include/main_0207BC3C.inc +++ b/asm/include/main_0207BC3C.inc @@ -18,8 +18,8 @@ .public ARM9_UNKNOWN_TABLE__NA_20AE924 .public EnableIrqFlag .public FileInit +.public InitDmaTransfer_Standard .public SetIrqFlag -.public sub_01FF9A68 .public sub_01FF9AA8 .public sub_01FF9B18 .public sub_01FF9B3C diff --git a/asm/include/main_0207F894.inc b/asm/include/main_0207F894.inc index b76e7a8f..59e63eae 100644 --- a/asm/include/main_0207F894.inc +++ b/asm/include/main_0207F894.inc @@ -1,22 +1,4 @@ #pragma once -.public ArrayCopy32 -.public ArrayFill32 -.public ArrayFill32Fast -.public EnableIrqFlag -.public FileInit -.public GetIrqFlag -.public MIi_UncompressBackward -.public MemcpyFast -.public MemsetFast -.public OS_GetLockID -.public OSi_ReferSymbol -.public SVC_CpuSet -.public SVC_WaitByLoop -.public SetIrqFlag -.public StartThread -.public ThreadExit -.public WaitForInterrupt -.public WaitForever2 .public _02000BC4 .public _020AEC5C .public _020AECB0 @@ -89,10 +71,23 @@ .public _ll_udiv .public _u32_div_f .public _ull_mod +.public ArrayCopy32 +.public ArrayFill32 +.public ArrayFill32Fast +.public CopyAndInterleave +.public EnableIrqFlag +.public FileInit +.public GetIrqFlag +.public MemcpyFast +.public MemsetFast +.public MIi_UncompressBackward +.public OS_GetLockID +.public OSi_ReferSymbol +.public SetIrqFlag +.public StartThread .public strchr .public strlen .public strncpy -.public sub_01FF8000 .public sub_02078A98 .public sub_02078C3C .public sub_02078C68 @@ -143,3 +138,8 @@ .public sub_0208B374 .public sub_0208C5B4 .public sub_0208D638 +.public SVC_CpuSet +.public SVC_WaitByLoop +.public ThreadExit +.public WaitForever2 +.public WaitForInterrupt diff --git a/asm/include/main_02089694.inc b/asm/include/main_02089694.inc index 6f70f09b..3f59c932 100644 --- a/asm/include/main_02089694.inc +++ b/asm/include/main_02089694.inc @@ -1 +1,2 @@ #pragma once + diff --git a/asm/include/main_020897DC.inc b/asm/include/main_020897DC.inc index 7b057a57..01a04a95 100644 --- a/asm/include/main_020897DC.inc +++ b/asm/include/main_020897DC.inc @@ -1,128 +1,4 @@ #pragma once -.public ACTOR_LIST -.public ARM9_UNKNOWN_DATA__NA_209EAAC -.public BaseFormsEqual -.public DseTrackEvent_Dummy1Byte -.public DseTrackEvent_Dummy2Bytes -.public DseTrackEvent_Dummy2Bytes2 -.public DseTrackEvent_EndTrack -.public DseTrackEvent_ForceLfoEnvelopeLevel -.public DseTrackEvent_Invalid -.public DseTrackEvent_MainLoopBegin -.public DseTrackEvent_OctaveDelta -.public DseTrackEvent_PanDelta -.public DseTrackEvent_PanFade -.public DseTrackEvent_RestoreEnvelopeDefaults -.public DseTrackEvent_SetBank -.public DseTrackEvent_SetBankLsb -.public DseTrackEvent_SetBankMsb -.public DseTrackEvent_SetBpm -.public DseTrackEvent_SetBpm2 -.public DseTrackEvent_SetEnvelopeAttackBegin -.public DseTrackEvent_SetEnvelopeAttackTime -.public DseTrackEvent_SetEnvelopeDecayTimeAndSustainLevel -.public DseTrackEvent_SetEnvelopeHoldTime -.public DseTrackEvent_SetEnvelopeReleaseTime -.public DseTrackEvent_SetEnvelopeSustainTime -.public DseTrackEvent_SetExpression -.public DseTrackEvent_SetFlagBit1Unknown -.public DseTrackEvent_SetHoldNotes -.public DseTrackEvent_SetInstrument -.public DseTrackEvent_SetKeyBend -.public DseTrackEvent_SetKeyBendRange -.public DseTrackEvent_SetLfoParameter -.public DseTrackEvent_SetNoteDurationMultiplier -.public DseTrackEvent_SetNoteRandomRegion -.public DseTrackEvent_SetOctave -.public DseTrackEvent_SetOptionalVolume -.public DseTrackEvent_SetPan -.public DseTrackEvent_SetTuning -.public DseTrackEvent_SetTuningJitterAmplitude -.public DseTrackEvent_SetUnknown2 -.public DseTrackEvent_SetVolume -.public DseTrackEvent_SetupKeyBendLfo -.public DseTrackEvent_SetupKeyBendLfoEnvelope -.public DseTrackEvent_SetupLfo -.public DseTrackEvent_SetupLfoEnvelope -.public DseTrackEvent_SetupPanLfo -.public DseTrackEvent_SetupPanLfoEnvelope -.public DseTrackEvent_SetupVolumeLfo -.public DseTrackEvent_SetupVolumeLfoEnvelope -.public DseTrackEvent_Signal -.public DseTrackEvent_SongVolumeFade -.public DseTrackEvent_SubLoopBegin -.public DseTrackEvent_SubLoopBreakOnLastIteration -.public DseTrackEvent_SubLoopEnd -.public DseTrackEvent_TuningDeltaCoarse -.public DseTrackEvent_TuningDeltaFine -.public DseTrackEvent_TuningDeltaFull -.public DseTrackEvent_TuningFade -.public DseTrackEvent_UseKeyBendLfo -.public DseTrackEvent_UseLfo -.public DseTrackEvent_UsePanLfo -.public DseTrackEvent_UseVolumeLfo -.public DseTrackEvent_VolumeDelta -.public DseTrackEvent_VolumeFade -.public DseTrackEvent_Wait16 -.public DseTrackEvent_Wait24 -.public DseTrackEvent_Wait8 -.public DseTrackEvent_WaitDelta -.public DseTrackEvent_WaitSame -.public DseTrackEvent_WaitUntilFadeout -.public GetKeyM2N -.public GetKeyM2NBaseForm -.public GetKeyN2M -.public GetKeyN2MBaseForm -.public IsAOrBPressed -.public LEVEL_LIST -.public MISSION_FLOOR_RANKS_AND_ITEM_LISTS_1 -.public MISSION_FLOOR_RANKS_AND_ITEM_LISTS_2 -.public RANK_STRINGS_1 -.public RANK_STRINGS_2 -.public RANK_STRINGS_3 -.public REMOTE_STRINGS -.public Render3d64Nothing -.public Render3d64Quadrilateral -.public Render3d64Rectangle -.public Render3d64RectangleMulticolor -.public Render3d64Texture -.public Render3d64Texture0x7 -.public Render3d64Tiling -.public Render3d64WindowFrame -.public STRING_BALANCE_M_LEVEL_BIN -.public STRING_DUNGEON_DUNGEON_BIN -.public STRING_EFFECT_EFFECT_BIN -.public STRING_MONSTER_MONSTER_BIN -.public STRING_MONSTER_M_ATTACK_BIN -.public STRING_MONSTER_M_GROUND_BIN -.public SoundLfoWave_FullNoiseFunc -.public SoundLfoWave_FullSquareFunc -.public SoundLfoWave_FullTriangleFunc -.public SoundLfoWave_HalfNoiseFunc -.public SoundLfoWave_HalfSquareFunc -.public SoundLfoWave_HalfTriangleFunc -.public SoundLfoWave_InvalidFunc -.public SoundLfoWave_ReverseSawFunc -.public SoundLfoWave_SawFunc -.public TryAppendToSlice -.public TryAssignByte -.public TryAssignByteWrapper -.public UNOWN_SPECIES_ADDITIONAL_CHARS -.public UpdateAdvancedMenu -.public UpdateAdvancedTextBox -.public UpdateAlertBox -.public UpdateAreaNameBox -.public UpdateCollectionMenu -.public UpdateControlsChart -.public UpdateDebugMenu -.public UpdateDialogueBox -.public UpdateOptionsMenu -.public UpdateParentMenu -.public UpdatePortraitBox -.public UpdateScrollBox -.public UpdateSimpleMenu -.public UpdateTeamSelectionMenu -.public UpdateTextBox .public _020908D4 .public _020908DC .public _020908E4 @@ -2006,10 +1882,115 @@ .public _022BCA70 .public __vsprintf_internal .public __vsprintf_internal_slice +.public ACTOR_LIST +.public ARM9_UNKNOWN_DATA__NA_209EAAC +.public BaseFormsEqual +.public DseTrackEvent_Dummy1Byte +.public DseTrackEvent_Dummy2Bytes +.public DseTrackEvent_Dummy2Bytes2 +.public DseTrackEvent_EndTrack +.public DseTrackEvent_ForceLfoEnvelopeLevel +.public DseTrackEvent_Invalid +.public DseTrackEvent_MainLoopBegin +.public DseTrackEvent_OctaveDelta +.public DseTrackEvent_PanDelta +.public DseTrackEvent_PanFade +.public DseTrackEvent_RestoreEnvelopeDefaults +.public DseTrackEvent_SetBank +.public DseTrackEvent_SetBankLsb +.public DseTrackEvent_SetBankMsb +.public DseTrackEvent_SetBpm +.public DseTrackEvent_SetBpm2 +.public DseTrackEvent_SetEnvelopeAttackBegin +.public DseTrackEvent_SetEnvelopeAttackTime +.public DseTrackEvent_SetEnvelopeDecayTimeAndSustainLevel +.public DseTrackEvent_SetEnvelopeHoldTime +.public DseTrackEvent_SetEnvelopeReleaseTime +.public DseTrackEvent_SetEnvelopeSustainTime +.public DseTrackEvent_SetExpression +.public DseTrackEvent_SetFlagBit1Unknown +.public DseTrackEvent_SetHoldNotes +.public DseTrackEvent_SetInstrument +.public DseTrackEvent_SetKeyBend +.public DseTrackEvent_SetKeyBendRange +.public DseTrackEvent_SetLfoParameter +.public DseTrackEvent_SetNoteDurationMultiplier +.public DseTrackEvent_SetNoteRandomRegion +.public DseTrackEvent_SetOctave +.public DseTrackEvent_SetOptionalVolume +.public DseTrackEvent_SetPan +.public DseTrackEvent_SetTuning +.public DseTrackEvent_SetTuningJitterAmplitude +.public DseTrackEvent_SetUnknown2 +.public DseTrackEvent_SetupKeyBendLfo +.public DseTrackEvent_SetupKeyBendLfoEnvelope +.public DseTrackEvent_SetupLfo +.public DseTrackEvent_SetupLfoEnvelope +.public DseTrackEvent_SetupPanLfo +.public DseTrackEvent_SetupPanLfoEnvelope +.public DseTrackEvent_SetupVolumeLfo +.public DseTrackEvent_SetupVolumeLfoEnvelope +.public DseTrackEvent_SetVolume +.public DseTrackEvent_Signal +.public DseTrackEvent_SongVolumeFade +.public DseTrackEvent_SubLoopBegin +.public DseTrackEvent_SubLoopBreakOnLastIteration +.public DseTrackEvent_SubLoopEnd +.public DseTrackEvent_TuningDeltaCoarse +.public DseTrackEvent_TuningDeltaFine +.public DseTrackEvent_TuningDeltaFull +.public DseTrackEvent_TuningFade +.public DseTrackEvent_UseKeyBendLfo +.public DseTrackEvent_UseLfo +.public DseTrackEvent_UsePanLfo +.public DseTrackEvent_UseVolumeLfo +.public DseTrackEvent_VolumeDelta +.public DseTrackEvent_VolumeFade +.public DseTrackEvent_Wait16 +.public DseTrackEvent_Wait24 +.public DseTrackEvent_Wait8 +.public DseTrackEvent_WaitDelta +.public DseTrackEvent_WaitSame +.public DseTrackEvent_WaitUntilFadeout +.public GetKeyM2N +.public GetKeyM2NBaseForm +.public GetKeyN2M +.public GetKeyN2MBaseForm +.public IsAOrBPressed +.public LEVEL_LIST .public mbtowc .public memset +.public MISSION_FLOOR_RANKS_AND_ITEM_LISTS_1 +.public MISSION_FLOOR_RANKS_AND_ITEM_LISTS_2 +.public RANK_STRINGS_1 +.public RANK_STRINGS_2 +.public RANK_STRINGS_3 +.public REMOTE_STRINGS +.public Render3d64Nothing +.public Render3d64Quadrilateral +.public Render3d64Rectangle +.public Render3d64RectangleMulticolor +.public Render3d64Texture +.public Render3d64Texture0x7 +.public Render3d64Tiling +.public Render3d64WindowFrame .public snprintf +.public SoundLfoWave_FullNoiseFunc +.public SoundLfoWave_FullSquareFunc +.public SoundLfoWave_FullTriangleFunc +.public SoundLfoWave_HalfNoiseFunc +.public SoundLfoWave_HalfSquareFunc +.public SoundLfoWave_HalfTriangleFunc +.public SoundLfoWave_InvalidFunc +.public SoundLfoWave_ReverseSawFunc +.public SoundLfoWave_SawFunc .public sprintf +.public STRING_BALANCE_M_LEVEL_BIN +.public STRING_DUNGEON_DUNGEON_BIN +.public STRING_EFFECT_EFFECT_BIN +.public STRING_MONSTER_M_ATTACK_BIN +.public STRING_MONSTER_M_GROUND_BIN +.public STRING_MONSTER_MONSTER_BIN .public sub_02003620 .public sub_02003780 .public sub_02005D14 @@ -2208,5 +2189,24 @@ .public sub_02087F10 .public sub_02088510 .public sub_020895F4 +.public TryAppendToSlice +.public TryAssignByte +.public TryAssignByteWrapper +.public UNOWN_SPECIES_ADDITIONAL_CHARS +.public UpdateAdvancedMenu +.public UpdateAdvancedTextBox +.public UpdateAlertBox +.public UpdateAreaNameBox +.public UpdateCollectionMenu +.public UpdateControlsChart +.public UpdateDebugMenu +.public UpdateDialogueBox +.public UpdateOptionsMenu +.public UpdateParentMenu +.public UpdatePortraitBox +.public UpdateScrollBox +.public UpdateSimpleMenu +.public UpdateTeamSelectionMenu +.public UpdateTextBox .public vsprintf .public wcstombs diff --git a/asm/include/overlay_00.inc b/asm/include/overlay_00.inc index c3669ef5..6cb99255 100644 --- a/asm/include/overlay_00.inc +++ b/asm/include/overlay_00.inc @@ -35,6 +35,7 @@ .public GetFadeStatus .public GetLanguage .public GetProcessorMode +.public HardwareInterrupt .public LoadOverlay .public MemAlloc .public memcmp @@ -87,7 +88,6 @@ .public strncmp .public strncpy .public strstr -.public sub_01FF95E8 .public sub_02002448 .public sub_020024B0 .public sub_020024C0 diff --git a/asm/include/overlay_29_022DC314.inc b/asm/include/overlay_29_022DC314.inc index 6383d051..5643d044 100644 --- a/asm/include/overlay_29_022DC314.inc +++ b/asm/include/overlay_29_022DC314.inc @@ -59,9 +59,9 @@ .public ov29_02373690 .public ov29_0237C6D4 .public ov29_0237C714 -.public sub_01FF8130 -.public sub_01FF81CC -.public sub_01FF8C60 +.public Render3dSetPaletteBase +.public Render3dSetTextureParams +.public Render3dTextureNoSetup .public sub_01FF9BA0 .public sub_01FF9E14 .public sub_01FF9F80 diff --git a/asm/include/overlay_29_022EF7C4.inc b/asm/include/overlay_29_022EF7C4.inc index 2f638360..25324e30 100644 --- a/asm/include/overlay_29_022EF7C4.inc +++ b/asm/include/overlay_29_022EF7C4.inc @@ -4,8 +4,8 @@ .public EntityIsValid__022EF7A0 .public IsFloorOver .public MoveMonsterToPos -.public UpdateEntityPixelPos .public ov29_022FA360 .public ov29_023444D4 .public ov29_02348F20 .public ov29_0234BA54 +.public UpdateEntityPixelPos diff --git a/asm/include/overlay_29_022EFA6C.inc b/asm/include/overlay_29_022EFA6C.inc index 6e7abb55..77b8c8ce 100644 --- a/asm/include/overlay_29_022EFA6C.inc +++ b/asm/include/overlay_29_022EFA6C.inc @@ -2,7 +2,6 @@ .public BoostIQ .public DUNGEON_PTR .public EntityIsValid__022F0590 -.public TeamMemberHasItemActive .public ov29_022DE5F0 .public ov29_022EA370 .public ov29_0234B1A4 @@ -12,3 +11,4 @@ .public ov29_023535A4 .public ov29_0237C9A0 .public sub_0201D198 +.public TeamMemberHasItemActive diff --git a/asm/include/overlay_29_022F7388.inc b/asm/include/overlay_29_022F7388.inc index 9a2fb7ce..cc24a2c4 100644 --- a/asm/include/overlay_29_022F7388.inc +++ b/asm/include/overlay_29_022F7388.inc @@ -1,18 +1,18 @@ #pragma once .public AbilityIsActiveVeneer -.public CASTFORM_WEATHER_ATTRIBUTE_TABLE .public CanAttackInDirection +.public CASTFORM_WEATHER_ATTRIBUTE_TABLE .public CeilFixedPoint .public CheckTeamMemberIdx -.public DIRECTIONS_XY -.public DUNGEON_PTR .public DeleteWanTableEntryVeneer .public DetermineMonsterShadow +.public DIRECTIONS_XY .public DirectoryFileMngr_GetDirectoryFileSize .public DiscoverMinimap .public DisplayMessage .public DisplayMessage2 .public DrawMinimapTile +.public DUNGEON_PTR .public DungeonRandInt .public EnableAllLearnableIqSkills .public EndFrozenClassStatus @@ -40,8 +40,8 @@ .public GetType .public IQ_SKILLS .public IsLevelResetDungeon -.public IsMonsterIdInNormalRange .public IsMonster__022F9720 +.public IsMonsterIdInNormalRange .public IsOutlawOrChallengeRequestFloor .public IsRecruitingAllowed .public IsSecretBazaarNpcBehavior @@ -60,21 +60,6 @@ .public MemFree .public MonsterIsType .public OpenMessageLog -.public PopulateActiveMonsterPtrs -.public RemoveHolderForItemInBag -.public ReplaceWanFromBinFile -.public SetForcedLossReason -.public SetMissionTargetEnemyDefeated -.public ShouldMonsterRunAway -.public StoryRestrictionsEnabled -.public SubstitutePlaceholderStringTags -.public TEAM_MEMBER_TABLE_PTR -.public TryEndStatusWithAbility -.public UpdateMapSurveyorFlag -.public UpdateMinimap -.public WAN_TABLE -.public WEATHER_BALL_TYPE_TABLE -.public YesNoMenu .public ov10_022C4C6E .public ov10_022C4C70 .public ov29_022DDB68 @@ -106,9 +91,24 @@ .public ov29_0234EF24 .public ov29_0235171E .public ov29_0237C9B0 +.public PopulateActiveMonsterPtrs +.public RemoveHolderForItemInBag +.public ReplaceWanFromBinFile +.public SetForcedLossReason +.public SetMissionTargetEnemyDefeated +.public ShouldMonsterRunAway +.public StoryRestrictionsEnabled .public sub_02053250 .public sub_0205349C .public sub_02056228 .public sub_020566C4 .public sub_020585B4 .public sub_02058674 +.public SubstitutePlaceholderStringTags +.public TEAM_MEMBER_TABLE_PTR +.public TryEndStatusWithAbility +.public UpdateMapSurveyorFlag +.public UpdateMinimap +.public WAN_TABLE +.public WEATHER_BALL_TYPE_TABLE +.public YesNoMenu diff --git a/asm/include/overlay_29_022F9744.inc b/asm/include/overlay_29_022F9744.inc index 1c07bb38..80ac4591 100644 --- a/asm/include/overlay_29_022F9744.inc +++ b/asm/include/overlay_29_022F9744.inc @@ -1,4 +1,5 @@ #pragma once +.public _020A1870 .public AbilityIsActiveVeneer .public AdvanceFrame .public AiMovement @@ -15,11 +16,11 @@ .public CheckVariousStatuses .public CheckVariousStatuses2 .public Conversion2IsActive -.public DIRECTIONS_XY -.public DUNGEON_PTR .public DefenderAbilityIsActive__022F96CC +.public DIRECTIONS_XY .public DiscoverMinimap .public DisplayAnimatedNumbers +.public DUNGEON_PTR .public DungeonRandInt .public EnableIqSkill .public EndBurnClassStatus @@ -61,34 +62,15 @@ .public IqSkillIsEnabled .public IsCurrentFixedRoomBossFight .public IsFullFloorFixedRoom +.public IsMonster__022F9720 .public IsMonsterIdInNormalRange .public IsMonsterSleeping -.public IsMonster__022F9720 .public IsOneHitKoMove .public IsSecretBazaarNpcBehavior .public ItemZInit .public LogMessageByIdWithPopup .public LogMessageByIdWithPopupCheckUser .public LogMessageByIdWithPopupCheckUserTarget -.public PointCameraToMonster -.public RandInt -.public RemoveEquivItem -.public RestoreAllMovePP -.public SECONDARY_TERRAIN_TYPES -.public SetActionPassTurnOrWalk -.public ShouldDisplayEntityWrapper -.public ShouldTryEatItem -.public ShowPpRestoreEffect -.public SubFixedPoint -.public SubstitutePlaceholderStringTags -.public TryIncreaseHp -.public TryInflictBurnStatus -.public TryInflictPausedStatus -.public UpdateCamera -.public UpdateMapSurveyorFlag -.public UpdateMinimap -.public UpdateStatusIconFlags -.public _020A1870 .public ov29_022E0A04 .public ov29_022E4160 .public ov29_022E576C @@ -113,9 +95,27 @@ .public ov29_0234B084 .public ov29_0234B09C .public ov29_0235171E +.public PointCameraToMonster +.public RandInt +.public RemoveEquivItem +.public RestoreAllMovePP +.public SECONDARY_TERRAIN_TYPES +.public SetActionPassTurnOrWalk +.public ShouldDisplayEntityWrapper +.public ShouldTryEatItem +.public ShowPpRestoreEffect .public sub_0201405C .public sub_02017C50 .public sub_0204AEF0 .public sub_02050FF8 .public sub_02052E2C .public sub_02056228 +.public SubFixedPoint +.public SubstitutePlaceholderStringTags +.public TryIncreaseHp +.public TryInflictBurnStatus +.public TryInflictPausedStatus +.public UpdateCamera +.public UpdateMapSurveyorFlag +.public UpdateMinimap +.public UpdateStatusIconFlags diff --git a/asm/include/overlay_29_022FBB1C.inc b/asm/include/overlay_29_022FBB1C.inc index ce4308e0..5c195559 100644 --- a/asm/include/overlay_29_022FBB1C.inc +++ b/asm/include/overlay_29_022FBB1C.inc @@ -1,4 +1,5 @@ #pragma once +.public _s32_div_f .public CopySpawnEntriesMaster .public DUNGEON_PTR .public DungeonRngSetPrimary @@ -23,10 +24,10 @@ .public GetTileSafe .public GetTurnLimit .public GroundToDungeonMoveset -.public IQ_SKILLS .public InitAnimationControlWithSet__0201C0CC .public InitMoveCheckId .public InitTeamMember +.public IQ_SKILLS .public IsCurrentMissionType .public IsDestinationFloorWithFixedRoom .public IsDestinationFloorWithMonster @@ -36,10 +37,6 @@ .public IsSecretBazaarNpcBehavior .public JoinedAtRangeCheck2Veneer .public LoadWazaP2 -.public SetMonsterLevelAndId -.public SetSpriteIdForAnimationControl -.public UnloadCurrentWazaP -.public _s32_div_f .public ov29_022DDA54 .public ov29_022EFAE8 .public ov29_022FB83C @@ -47,4 +44,7 @@ .public ov29_023021F0 .public ov29_02304830 .public ov29_02351E28 +.public SetMonsterLevelAndId +.public SetSpriteIdForAnimationControl .public sub_0200F9B4 +.public UnloadCurrentWazaP diff --git a/asm/include/overlay_29_022FC9C0.inc b/asm/include/overlay_29_022FC9C0.inc index f473b8c8..4218f434 100644 --- a/asm/include/overlay_29_022FC9C0.inc +++ b/asm/include/overlay_29_022FC9C0.inc @@ -34,6 +34,7 @@ .public GetMonsterApparentId .public GetMonsterIdToSpawn .public GetMonsterLevelToSpawn +.public GetRandomTile .public GetTile .public GetType .public InflictSleepStatusSingle @@ -73,7 +74,6 @@ .public ov29_022E2018 .public ov29_022E2DFC .public ov29_022E6644 -.public ov29_022E9628 .public ov29_022EFAE8 .public ov29_022F9EA0 .public ov29_022FA1D8 diff --git a/asm/include/overlay_29_02300108.inc b/asm/include/overlay_29_02300108.inc index 6fc9e04d..1d2069ab 100644 --- a/asm/include/overlay_29_02300108.inc +++ b/asm/include/overlay_29_02300108.inc @@ -7,11 +7,11 @@ .public GetNameRaw .public GetNameWithGender .public IsBlinded -.public StringFromId .public ov29_0234B0B4 .public ov29_023527C0 .public ov29_023527D0 .public strcpy +.public StringFromId .public sub_02024FB8 .public sub_02056084 .public sub_02058534 diff --git a/asm/include/overlay_29_023008DC.inc b/asm/include/overlay_29_023008DC.inc index 50098172..917c769c 100644 --- a/asm/include/overlay_29_023008DC.inc +++ b/asm/include/overlay_29_023008DC.inc @@ -2,5 +2,5 @@ .public CheckVariousStatuses2 .public IsBlinded .public IsChargingAnyTwoTurnMove -.public ShouldMonsterRunAway .public ov29_02300D00 +.public ShouldMonsterRunAway diff --git a/asm/include/overlay_29_023016A8.inc b/asm/include/overlay_29_023016A8.inc index 897c4c3d..62bc3f0e 100644 --- a/asm/include/overlay_29_023016A8.inc +++ b/asm/include/overlay_29_023016A8.inc @@ -5,8 +5,8 @@ .public IsExperienceLocked .public IsMonster__02301A60 .public LogMessageByIdWithPopupCheckUserTarget +.public ov29_022E62A8 +.public ov29_023527A0 .public ShouldMonsterRunAway .public SubstitutePlaceholderStringTags .public UpdateStateFlags -.public ov29_022E62A8 -.public ov29_023527A0 diff --git a/asm/include/overlay_29_02301A84.inc b/asm/include/overlay_29_02301A84.inc index ae878d27..05bb8588 100644 --- a/asm/include/overlay_29_02301A84.inc +++ b/asm/include/overlay_29_02301A84.inc @@ -6,7 +6,7 @@ .public GetExclusiveItemWithEffectFromBag .public LogMessageByIdWithPopupCheckUserTarget .public MistIsActive -.public SubstitutePlaceholderStringTags .public ov29_02314DC4 .public ov29_02324BE8 .public ov29_02344B44 +.public SubstitutePlaceholderStringTags diff --git a/asm/include/overlay_29_02301D78.inc b/asm/include/overlay_29_02301D78.inc index 4c90d21b..96d00ea0 100644 --- a/asm/include/overlay_29_02301D78.inc +++ b/asm/include/overlay_29_02301D78.inc @@ -1,7 +1,7 @@ #pragma once .public AbilityIsActive -.public DUNGEON_PTR .public DefenderAbilityIsActive__02301A0C +.public DUNGEON_PTR .public EntityIsValid__023000E4 .public GravityIsActive .public ItemIsActive__022FF898 diff --git a/asm/include/overlay_29_02301F50.inc b/asm/include/overlay_29_02301F50.inc index 5ddda830..953a8d37 100644 --- a/asm/include/overlay_29_02301F50.inc +++ b/asm/include/overlay_29_02301F50.inc @@ -1,22 +1,23 @@ #pragma once +.public _s32_div_f .public AbilityIsActive .public AbilityIsActiveVeneer .public AllocateTemp1024ByteBufferFromPool .public CanLearnIqSkill .public CanSeeTarget .public CanThrowItems -.public DUNGEON_PTR .public DisableIqSkill +.public DUNGEON_PTR .public DungeonGetSpriteIndex .public DungeonRandInt -.public EXCLUSIVE_ITEM_EXP_BOOST -.public EXP_ELITE_EXP_BOOST .public EnableIqSkill .public EntityIsValid__023000E4 .public EntityIsValid__02302A38 .public EvolveMonster +.public EXCLUSIVE_ITEM_EXP_BOOST .public ExclusiveItemEffectFlagTest .public ExclusiveItemEffectIsActive__022FFF28 +.public EXP_ELITE_EXP_BOOST .public GetEntityNaturalGiftInfo .public GetEntityWeatherBallType .public GetEvolutions @@ -43,9 +44,6 @@ .public MIN_IQ_ITEM_MASTER .public MIRACLE_CHEST_EXP_BOOST .public MultiplyByFixedPoint -.public SubstitutePlaceholderStringTags -.public WONDER_CHEST_EXP_BOOST -.public _s32_div_f .public ov29_022E2470 .public ov29_022FBDE0 .public ov29_0230040C @@ -56,3 +54,5 @@ .public ov29_0234B034 .public ov29_0234B09C .public ov29_023527F8 +.public SubstitutePlaceholderStringTags +.public WONDER_CHEST_EXP_BOOST diff --git a/asm/include/overlay_29_02308FE0.inc b/asm/include/overlay_29_02308FE0.inc index 98dc52ea..8c2a83f9 100644 --- a/asm/include/overlay_29_02308FE0.inc +++ b/asm/include/overlay_29_02308FE0.inc @@ -1,5 +1,6 @@ #pragma once .public AbilityIsActiveVeneer +.public abs .public ActivateMotorDrive .public AddExpSpecial .public AdvanceFrame @@ -10,14 +11,14 @@ .public ChangeDungeonMusic .public ChangeMonsterAnimation .public DAMAGE_STRING_IDS -.public DUNGEON_PTR .public DisplayAnimatedNumbers +.public DUNGEON_PTR .public DungeonRandOutcome__022EAB20 .public EndCurseClassStatus .public EndInvisibleClassStatus .public EntityIsValid__02308FBC -.public ExclusiveItemEffectIsActiveWithLogging .public ExclusiveItemEffectIsActive__0230A9B8 +.public ExclusiveItemEffectIsActiveWithLogging .public FreeOtherWrappedMonsters .public GetActiveTeamMember .public GetDirectionTowardsPosition @@ -29,8 +30,8 @@ .public IsBlinded .public IsCurrentMissionType .public IsExperienceLocked -.public IsMonsterIdInNormalRangeVeneer .public IsMonster__0230A994 +.public IsMonsterIdInNormalRangeVeneer .public IsSecretBazaarNpcBehavior .public IsSpecialStoryAlly .public ItemIsActive__0230A9DC @@ -41,28 +42,6 @@ .public LogMessageByIdWithPopupCheckUserTarget .public MoveMonsterToPos .public MusicTableIdxToMusicId -.public PlayEffectAnimationEntity -.public RecruitCheck -.public RemoveHolderForItemInBag -.public RestorePpAllMovesSetFlags -.public RestoreRandomMovePP -.public SET_DAMAGE_STATUS_DAMAGE -.public SetMonsterFlag2 -.public SetPokemonBattled -.public ShouldDisplayEntityWrapper -.public SpawnDroppedItemWrapper -.public SubInitMonster -.public SubstitutePlaceholderStringTags -.public TYPE_DAMAGE_NEGATING_EXCLUSIVE_ITEM_EFFECTS -.public TryIncreaseHp -.public TryRecruit -.public TrySpawnEnemyItemDrop -.public UpdateAiTargetPos -.public UpdateEntityPixelPos -.public UpdateShopkeeperModeAfterAttack -.public UpdateStatusIconFlags -.public UpdateTrapsVisibility -.public abs .public ov10_022BDC68 .public ov10_022BDE50 .public ov10_022BF964 @@ -118,4 +97,25 @@ .public ov29_02353234 .public ov29_023535D4 .public ov29_0237CA6C +.public PlayEffectAnimationEntity +.public RecruitCheck +.public RemoveHolderForItemInBag +.public RestorePpAllMovesSetFlags +.public RestoreRandomMovePP +.public SET_DAMAGE_STATUS_DAMAGE +.public SetMonsterFlag2 +.public SetPokemonBattled +.public ShouldDisplayEntityWrapper +.public SpawnDroppedItemWrapper .public sub_0204AF00 +.public SubInitMonster +.public SubstitutePlaceholderStringTags +.public TryIncreaseHp +.public TryRecruit +.public TrySpawnEnemyItemDrop +.public TYPE_DAMAGE_NEGATING_EXCLUSIVE_ITEM_EFFECTS +.public UpdateAiTargetPos +.public UpdateEntityPixelPos +.public UpdateShopkeeperModeAfterAttack +.public UpdateStatusIconFlags +.public UpdateTrapsVisibility diff --git a/asm/include/overlay_29_0230A9B8.inc b/asm/include/overlay_29_0230A9B8.inc index 3b89f7aa..f345d091 100644 --- a/asm/include/overlay_29_0230A9B8.inc +++ b/asm/include/overlay_29_0230A9B8.inc @@ -1,18 +1,20 @@ #pragma once -.public AFTERMATH_CHANCE -.public AIR_BLADE_DAMAGE_MULTIPLIER -.public AURA_BOW_STAT_BOOST +.public _s32_div_f .public AbilityIsActiveVeneer +.public abs .public AddFixedPoint64 .public AdvanceFrame +.public AFTERMATH_CHANCE +.public AIR_BLADE_DAMAGE_MULTIPLIER .public AllocateTemp1024ByteBufferFromPool .public ApplyDamageAndEffects +.public AURA_BOW_STAT_BOOST .public AuraBowIsActive .public BURN_DAMAGE_MULTIPLIER -.public CLOUDY_DAMAGE_MULTIPLIER .public CanSeeTarget .public CeilFixedPoint .public ClampedLn +.public CLOUDY_DAMAGE_MULTIPLIER .public DAMAGE_FORMULA_AT_PREFACTOR .public DAMAGE_FORMULA_CONSTANT_SHIFT .public DAMAGE_FORMULA_DEF_PREFACTOR @@ -26,13 +28,13 @@ .public DAMAGE_MULTIPLIER_0_5 .public DAMAGE_MULTIPLIER_1_5 .public DAMAGE_MULTIPLIER_2 -.public DEFENSIVE_STAT_STAGE_MULTIPLIERS -.public DEF_SCARF_STAT_BOOST -.public DUNGEON_PTR -.public DebugRecruitingEnabled .public Debug_Print0 +.public DebugRecruitingEnabled +.public DEF_SCARF_STAT_BOOST .public DefenderAbilityIsActive__0230A940 +.public DEFENSIVE_STAT_STAGE_MULTIPLIERS .public DivideFixedPoint64 +.public DUNGEON_PTR .public DungeonRandInt .public DungeonRandOutcome__022EAB20 .public EnableAllLearnableIqSkills @@ -65,6 +67,7 @@ .public GetMoveCategory .public GetNameString .public GetRandomMovementChance +.public GetRandomTile .public GetRecruitRate1 .public GetRecruitRate2 .public GetTile @@ -79,8 +82,8 @@ .public IsFloating .public IsFullFloorFixedRoom .public IsLegendaryChallengeFloor -.public IsMonsterOnTeam .public IsMonster__0230A994 +.public IsMonsterOnTeam .public IsPunchMove .public IsRecoilMove .public IsRecruitingAllowed @@ -99,7 +102,6 @@ .public MATCHUP_SUPER_EFFECTIVE_MULTIPLIER .public MATCHUP_SUPER_EFFECTIVE_MULTIPLIER_ERRATIC_PLAYER .public ME_FIRST_MULTIPLIER -.public MUNCH_BELT_STAT_BOOST .public MemZero .public MewSpawnCheck .public MonsterHasNegativeStatus @@ -107,52 +109,10 @@ .public MoveIsNotPhysical .public MultiplyByFixedPoint .public MultiplyFixedPoint64 +.public MUNCH_BELT_STAT_BOOST .public NearbyAllyIqSkillIsEnabled .public OFFENSIVE_STAT_STAGE_MULTIPLIERS .public OtherMonsterAbilityIsActive -.public POWER_BAND_STAT_BOOST -.public POWER_PITCHER_DAMAGE_MULTIPLIER -.public PlayEffectAnimation0x171 -.public PlayEffectAnimation0x171Full -.public PlayEffectAnimation0x18E -.public PlayEffectAnimation0x1A9__022E6130 -.public PlayEffectAnimation0x1A9__022E617C -.public PlayEffectAnimation0x1A9__022E61C8 -.public PlayEffectAnimation0x1A9__022E6214 -.public PlayEffectAnimation0x1A9__022E64C4 -.public PlayEffectAnimation0x1A9__022E6510 -.public PlayEffectAnimationEntity -.public PointCameraToMonster -.public PreprocessString -.public RECRUITMENT_LEVEL_BOOST_TABLE -.public ResetDamageData -.public RoundUpDiv256 -.public SCOPE_LENS_CRIT_RATE_BOOST -.public SOLID_ROCK_MULTIPLIER -.public SPAWN_CAP_NO_MONSTER_HOUSE -.public SPAWN_CAP_WITH_MONSTER_HOUSE -.public SPAWN_COOLDOWN -.public SPAWN_COOLDOWN_THIEF_ALERT -.public SPECIAL_BAND_STAT_BOOST -.public SUPER_LUCK_CRIT_RATE_BOOST -.public SetItemAcquired -.public SetPokemonJoined -.public SpawnMonster -.public StrcpySimple -.public StringFromId -.public StrncpyName -.public StrncpySimpleNoPad -.public SubstitutePlaceholderStringTags -.public TECHNICIAN_MOVE_POWER_THRESHOLD -.public TINTED_LENS_MULTIPLIER -.public TYPE_ADVANTAGE_MASTER_CRIT_RATE -.public TYPE_MATCHUP_COMBINATOR_TABLE -.public TYPE_MATCHUP_TABLE -.public TryAftermathExplosion -.public UpdateStateFlags -.public ZINC_BAND_STAT_BOOST -.public _s32_div_f -.public abs .public ov10_022BDE50 .public ov10_022BF964 .public ov10_022C4410 @@ -172,7 +132,6 @@ .public ov29_022E68BC .public ov29_022E8104 .public ov29_022E81F8 -.public ov29_022E9628 .public ov29_022EACAC .public ov29_022FBC94 .public ov29_022FBDE0 @@ -201,6 +160,37 @@ .public ov29_02352990 .public ov29_0235299C .public ov29_023535D4 +.public PlayEffectAnimation0x171 +.public PlayEffectAnimation0x171Full +.public PlayEffectAnimation0x18E +.public PlayEffectAnimation0x1A9__022E6130 +.public PlayEffectAnimation0x1A9__022E617C +.public PlayEffectAnimation0x1A9__022E61C8 +.public PlayEffectAnimation0x1A9__022E6214 +.public PlayEffectAnimation0x1A9__022E64C4 +.public PlayEffectAnimation0x1A9__022E6510 +.public PlayEffectAnimationEntity +.public PointCameraToMonster +.public POWER_BAND_STAT_BOOST +.public POWER_PITCHER_DAMAGE_MULTIPLIER +.public PreprocessString +.public RECRUITMENT_LEVEL_BOOST_TABLE +.public ResetDamageData +.public RoundUpDiv256 +.public SCOPE_LENS_CRIT_RATE_BOOST +.public SetItemAcquired +.public SetPokemonJoined +.public SOLID_ROCK_MULTIPLIER +.public SPAWN_CAP_NO_MONSTER_HOUSE +.public SPAWN_CAP_WITH_MONSTER_HOUSE +.public SPAWN_COOLDOWN +.public SPAWN_COOLDOWN_THIEF_ALERT +.public SpawnMonster +.public SPECIAL_BAND_STAT_BOOST +.public StrcpySimple +.public StringFromId +.public StrncpyName +.public StrncpySimpleNoPad .public sub_020534BC .public sub_02055CCC .public sub_02055D7C @@ -208,3 +198,13 @@ .public sub_02056830 .public sub_020584FC .public sub_020585B4 +.public SubstitutePlaceholderStringTags +.public SUPER_LUCK_CRIT_RATE_BOOST +.public TECHNICIAN_MOVE_POWER_THRESHOLD +.public TINTED_LENS_MULTIPLIER +.public TryAftermathExplosion +.public TYPE_ADVANTAGE_MASTER_CRIT_RATE +.public TYPE_MATCHUP_COMBINATOR_TABLE +.public TYPE_MATCHUP_TABLE +.public UpdateStateFlags +.public ZINC_BAND_STAT_BOOST diff --git a/asm/include/overlay_29_0230F02C.inc b/asm/include/overlay_29_0230F02C.inc index 1e59b2d4..08dc0c29 100644 --- a/asm/include/overlay_29_0230F02C.inc +++ b/asm/include/overlay_29_0230F02C.inc @@ -1,7 +1,8 @@ #pragma once -.public AI_THROWN_ITEM_ACTION_CHOICE_COUNT .public AbilityIsActiveVeneer +.public abs .public AddMoneyCarried +.public AI_THROWN_ITEM_ACTION_CHOICE_COUNT .public BAG_ITEMS_PTR_MIRROR .public CanSeeTarget .public DIRECTIONS_XY @@ -24,11 +25,6 @@ .public IsFloorOver .public IsMonster__0230F980 .public LogMessageByIdWithPopup -.public RemoveGroundItem -.public ShouldMonsterRunAwayVariation -.public SubstitutePlaceholderStringTags -.public UseThrowableItem -.public abs .public ov29_022EACCC .public ov29_022F52BC .public ov29_022F9EA0 @@ -39,4 +35,8 @@ .public ov29_02348D3C .public ov29_02348DD8 .public ov29_02348ECC +.public RemoveGroundItem +.public ShouldMonsterRunAwayVariation .public sub_0200D8AC +.public SubstitutePlaceholderStringTags +.public UseThrowableItem diff --git a/asm/include/overlay_29_0230F9A4.inc b/asm/include/overlay_29_0230F9A4.inc index e05255e2..015fdd98 100644 --- a/asm/include/overlay_29_0230F9A4.inc +++ b/asm/include/overlay_29_0230F9A4.inc @@ -3,15 +3,15 @@ .public ApplyDamageAndEffectsWrapper .public BAD_POISON_DAMAGE_COOLDOWN .public BAD_POISON_DAMAGE_TABLE -.public BURN_DAMAGE -.public BURN_DAMAGE_COOLDOWN .public BinToDecFixedPoint .public BoostSpeedOneStage +.public BURN_DAMAGE +.public BURN_DAMAGE_COOLDOWN .public CeilFixedPoint .public CheckVariousStatuses .public CheckVariousStatuses2 -.public DUNGEON_PTR .public DisplayActions +.public DUNGEON_PTR .public DungeonRandInt .public DungeonRandOutcome__022EAB20 .public EndBurnClassStatus @@ -20,9 +20,9 @@ .public EndNegativeStatusConditionWrapper .public EnsureCanStandCurrentTile .public EntityIsValid__02311010 -.public ExclusiveItemEffectIsActiveWithLogging .public ExclusiveItemEffectIsActive__0230F8AC .public ExclusiveItemEffectIsActive__02311064 +.public ExclusiveItemEffectIsActiveWithLogging .public GenerateStandardItem .public GetApparentWeather .public GetTileAtEntity @@ -40,19 +40,6 @@ .public MonsterHasNegativeStatus .public MonsterIsType .public MultiplyFixedPoint64 -.public POISON_DAMAGE -.public POISON_DAMAGE_COOLDOWN -.public SPEED_BOOST_TURNS -.public SpawnDroppedItemWrapper -.public SubFixedPoint -.public SubstitutePlaceholderStringTags -.public TickStatusTurnCounter -.public TreasureBoxDropsEnabled -.public TryActivateBadDreams -.public TryGenerateUnownStoneDrop -.public TryIncreaseHp -.public TryWarp -.public TryWeatherFormChange .public ov10_022C4454 .public ov10_022C446C .public ov10_022C44BC @@ -90,4 +77,17 @@ .public ov29_0234B084 .public ov29_0234B294 .public ov29_023529A8 +.public POISON_DAMAGE +.public POISON_DAMAGE_COOLDOWN +.public SpawnDroppedItemWrapper +.public SPEED_BOOST_TURNS .public sub_02050FF8 +.public SubFixedPoint +.public SubstitutePlaceholderStringTags +.public TickStatusTurnCounter +.public TreasureBoxDropsEnabled +.public TryActivateBadDreams +.public TryGenerateUnownStoneDrop +.public TryIncreaseHp +.public TryWarp +.public TryWeatherFormChange diff --git a/asm/include/overlay_29_0231513C.inc b/asm/include/overlay_29_0231513C.inc index c6f5736e..48716245 100644 --- a/asm/include/overlay_29_0231513C.inc +++ b/asm/include/overlay_29_0231513C.inc @@ -1,16 +1,17 @@ #pragma once -.public ATK_STAT_IDX +.public _s32_div_f .public AbilityIsActiveVeneer .public AdvanceFrame .public AiMovement .public AnimationDelayOrSomething +.public ATK_STAT_IDX .public BoostDefensiveStat .public BoostOffensiveStat .public CalcStatusDuration .public CeilFixedPoint -.public DUNGEON_PTR .public DetermineMonsterShadow .public DisplayAnimatedNumbers +.public DUNGEON_PTR .public DungeonGetSpriteIndex .public DungeonRandInt .public EndCurseClassStatus @@ -32,18 +33,6 @@ .public MonsterIsType .public MonsterSpawnListPartialCopy .public MultiplyByFixedPoint -.public PERISH_SONG_TURN_RANGE -.public SafeguardIsActive -.public ShouldDisplayEntityWrapper -.public SubFixedPoint -.public SubstitutePlaceholderStringTags -.public TryActivateQuickFeet -.public TryRemoveSnatchedMonsterFromDungeonStruct -.public UpdateCamera -.public UpdateMinimap -.public UpdateStatusIconFlags -.public UpdateTrapsVisibility -.public _s32_div_f .public ov10_022C4470 .public ov10_022C44B0 .public ov10_022C4784 @@ -95,9 +84,20 @@ .public ov29_02304830 .public ov29_0234B09C .public ov29_0234B0B4 +.public PERISH_SONG_TURN_RANGE +.public SafeguardIsActive +.public ShouldDisplayEntityWrapper .public strcpy .public sub_02001888 .public sub_02024FB8 .public sub_02050EBC .public sub_02050F78 .public sub_02050FF8 +.public SubFixedPoint +.public SubstitutePlaceholderStringTags +.public TryActivateQuickFeet +.public TryRemoveSnatchedMonsterFromDungeonStruct +.public UpdateCamera +.public UpdateMinimap +.public UpdateStatusIconFlags +.public UpdateTrapsVisibility diff --git a/asm/include/overlay_29_02317844.inc b/asm/include/overlay_29_02317844.inc index 1fcf23e2..a0f278f5 100644 --- a/asm/include/overlay_29_02317844.inc +++ b/asm/include/overlay_29_02317844.inc @@ -14,17 +14,6 @@ .public IsProtectedFromNegativeStatus .public LogMessageByIdWithPopupCheckUser .public LogMessageByIdWithPopupCheckUserTarget -.public SafeguardIsActive -.public ShowPpRestoreEffect -.public SubstitutePlaceholderStringTags -.public TryActivateQuickFeet -.public TryActivateSteadfast -.public TryIncreaseHp -.public TryRemoveSnatchedMonsterFromDungeonStruct -.public UpdateCamera -.public UpdateMinimap -.public UpdateStatusIconFlags -.public UpdateTrapsVisibility .public ov10_022C4620 .public ov10_022C4628 .public ov10_022C4764 @@ -48,4 +37,15 @@ .public ov29_022E4B3C .public ov29_022EACCC .public ov29_022FB984 +.public SafeguardIsActive +.public ShowPpRestoreEffect .public sub_01FFB62C +.public SubstitutePlaceholderStringTags +.public TryActivateQuickFeet +.public TryActivateSteadfast +.public TryIncreaseHp +.public TryRemoveSnatchedMonsterFromDungeonStruct +.public UpdateCamera +.public UpdateMinimap +.public UpdateStatusIconFlags +.public UpdateTrapsVisibility diff --git a/asm/include/overlay_29_02318AD4.inc b/asm/include/overlay_29_02318AD4.inc index b64608e8..94860567 100644 --- a/asm/include/overlay_29_02318AD4.inc +++ b/asm/include/overlay_29_02318AD4.inc @@ -5,8 +5,8 @@ .public IsMonster__02318AB0 .public LogMessageByIdWithPopupCheckUserTarget .public LogMessageWithPopupCheckUserTarget -.public SubstitutePlaceholderStringTags -.public UpdateStatusIconFlags .public ov10_022C4754 .public ov10_022C475C .public ov29_022E41B0 +.public SubstitutePlaceholderStringTags +.public UpdateStatusIconFlags diff --git a/asm/include/overlay_29_02319FB0.inc b/asm/include/overlay_29_02319FB0.inc index 2ff72d0c..b95b7e8b 100644 --- a/asm/include/overlay_29_02319FB0.inc +++ b/asm/include/overlay_29_02319FB0.inc @@ -1,5 +1,7 @@ #pragma once +.public _s32_div_f .public AbilityIsActiveVeneer +.public abs .public AreMovesEnabled .public CanAttackInDirection .public DIRECTIONS_XY @@ -18,15 +20,10 @@ .public IqSkillIsEnabled .public IsBlinded .public IsFloorOver -.public IsMonsterSleeping .public IsMonster__0231A9D4 +.public IsMonsterSleeping .public LogMessageByIdWithPopupCheckUser .public MonsterHasNegativeStatus -.public SubstitutePlaceholderStringTags -.public TryActivateTruant -.public UpdateMovePp -.public _s32_div_f -.public abs .public ov10_022C459C .public ov29_022E3ED0 .public ov29_022FA574 @@ -40,3 +37,6 @@ .public ov29_0237CA20 .public ov29_0237CA28 .public ov29_0237CA48 +.public SubstitutePlaceholderStringTags +.public TryActivateTruant +.public UpdateMovePp diff --git a/asm/include/overlay_29_0231A9F8.inc b/asm/include/overlay_29_0231A9F8.inc index e1f1518d..1895646f 100644 --- a/asm/include/overlay_29_0231A9F8.inc +++ b/asm/include/overlay_29_0231A9F8.inc @@ -22,12 +22,6 @@ .public LogMessageByIdWithPopupCheckUserTarget .public MonsterIsType .public NATURAL_GIFT_ITEM_TABLE -.public RemoveUsedItem -.public SetActionUseMoveAi -.public SubstitutePlaceholderStringTags -.public TryActivateTruant -.public UpdateAiTargetPos -.public WEATHER_BALL_TYPE_TABLE .public ov29_022E4110 .public ov29_022EB4E8 .public ov29_022FB9E0 @@ -37,3 +31,9 @@ .public ov29_02322374 .public ov29_0232E80C .public ov29_02344B44 +.public RemoveUsedItem +.public SetActionUseMoveAi +.public SubstitutePlaceholderStringTags +.public TryActivateTruant +.public UpdateAiTargetPos +.public WEATHER_BALL_TYPE_TABLE diff --git a/asm/include/overlay_29_0231B1B8.inc b/asm/include/overlay_29_0231B1B8.inc index 5c4bb826..70295999 100644 --- a/asm/include/overlay_29_0231B1B8.inc +++ b/asm/include/overlay_29_0231B1B8.inc @@ -2,8 +2,8 @@ .public ApplyDamageAndEffectsWrapper .public DUNGEON_PTR .public EntityIsValid__0231B194 -.public IsMonsterSleeping .public IsMonster__0231B318 +.public IsMonsterSleeping .public ov10_022C4530 .public ov29_022E28D4 .public ov29_02307BDC diff --git a/asm/include/overlay_29_0231B33C.inc b/asm/include/overlay_29_0231B33C.inc index 1c48d524..81bed5e2 100644 --- a/asm/include/overlay_29_0231B33C.inc +++ b/asm/include/overlay_29_0231B33C.inc @@ -1,8 +1,8 @@ #pragma once -.public APPLES_AND_BERRIES_ITEM_IDS .public AbilityIsActiveVeneer .public AddHeldItemToBag .public AnimationDelayOrSomething +.public APPLES_AND_BERRIES_ITEM_IDS .public ApplyBlastSeedEffect .public ApplyCalciumEffect .public ApplyCheriBerryEffect @@ -27,14 +27,14 @@ .public BoostIQ .public BoostSpeedOneStage .public CACNEA_SPIKE_POWER -.public CALCIUM_STAT_BOOST -.public CORSOLA_TWIG_POWER .public CalcDamageFixedNoCategory +.public CALCIUM_STAT_BOOST .public CalcStatusDuration .public CheckVariousConditions -.public DUNGEON_PTR +.public CORSOLA_TWIG_POWER .public DealDamageProjectile .public DetermineMonsterShadow +.public DUNGEON_PTR .public DungeonGetSpriteIndex .public EndNegativeStatusConditionWrapper .public EnemyEvolution @@ -42,36 +42,60 @@ .public ExclusiveItemEffectFlagTest .public FemaleToMaleForm .public GEO_PEBBLE_DAMAGE +.public GetActiveTeamMember +.public GetIdleAnimationId +.public GetItemCategoryVeneer .public GOLD_FANG_POWER .public GOLD_THORN_POWER .public GRAVELEROCK_DAMAGE .public GUMMI_STAT_BOOST -.public GetActiveTeamMember -.public GetIdleAnimationId -.public GetItemCategoryVeneer -.public IRON_STAT_BOOST -.public IRON_THORN_POWER .public InitMove .public IqSkillIsEnabled +.public IRON_STAT_BOOST +.public IRON_THORN_POWER .public IsBagFull .public IsShaymin .public IsSkyExclusiveDungeon -.public LIFE_SEED_HP_BOOST .public LevelUpItemEffect +.public LIFE_SEED_HP_BOOST .public LogMessageByIdWithPopupCheckUserTarget .public ORAN_BERRY_FULL_HP_BOOST .public ORAN_BERRY_HP_RESTORATION .public OREN_BERRY_DAMAGE +.public ov10_022C44EC +.public ov10_022C4558 +.public ov10_022C4574 +.public ov10_022C457C +.public ov10_022C4864 +.public ov29_022E3590 +.public ov29_022E5A00 +.public ov29_022E5AE4 +.public ov29_022E60E4 +.public ov29_022E81F8 +.public ov29_022E9FD0 +.public ov29_022EA370 +.public ov29_022EACCC +.public ov29_022F04F0 +.public ov29_022F0518 +.public ov29_022F9EA0 +.public ov29_022FB920 +.public ov29_022FB9BC +.public ov29_02304830 +.public ov29_0230F9A4 +.public ov29_02344B44 +.public ov29_0234BA54 .public PROTEIN_STAT_BOOST .public RARE_FOSSIL_DAMAGE .public RestoreAllMovePP +.public SetMonsterTypeAndAbility .public SILVER_SPIKE_POWER .public SITRUS_BERRY_FULL_HP_BOOST .public SITRUS_BERRY_HP_RESTORATION .public SLEEP_TURN_RANGE -.public STICK_POWER -.public SetMonsterTypeAndAbility .public SpawnDroppedItemWrapper +.public STICK_POWER +.public sub_020017EC +.public sub_0201CF80 .public SubstitutePlaceholderStringTags .public SwapMonsterWanFileIndex .public TryDecreaseLevel @@ -84,34 +108,10 @@ .public TryInflictEyedropStatus .public TryInflictInvisibleStatus .public TryInflictPetrifiedStatus -.public TryInflictSleepStatus .public TryInflictSleeplessStatus +.public TryInflictSleepStatus .public TryInflictSlipStatus .public TryWarp .public UpdateShopkeeperModeAfterAttack .public WONDER_GUMMI_STAT_BOOST .public ZINC_STAT_BOOST -.public ov10_022C44EC -.public ov10_022C4558 -.public ov10_022C4574 -.public ov10_022C457C -.public ov10_022C4864 -.public ov29_022E3590 -.public ov29_022E5A00 -.public ov29_022E5AE4 -.public ov29_022E60E4 -.public ov29_022E81F8 -.public ov29_022E9FD0 -.public ov29_022EA370 -.public ov29_022EACCC -.public ov29_022F04F0 -.public ov29_022F0518 -.public ov29_022F9EA0 -.public ov29_022FB920 -.public ov29_022FB9BC -.public ov29_02304830 -.public ov29_0230F9A4 -.public ov29_02344B44 -.public ov29_0234BA54 -.public sub_020017EC -.public sub_0201CF80 diff --git a/asm/include/overlay_29_02320788.inc b/asm/include/overlay_29_02320788.inc index ad8110b1..62ad61ef 100644 --- a/asm/include/overlay_29_02320788.inc +++ b/asm/include/overlay_29_02320788.inc @@ -15,6 +15,7 @@ .public FindUnoccupiedTileWithin3 .public GetApparentWeather .public GetLeader +.public GetRandomTile .public GetTileSafe .public InitMove .public IsFloorOver @@ -26,7 +27,6 @@ .public ov29_022E5560 .public ov29_022E55F0 .public ov29_022E5650 -.public ov29_022E9628 .public ov29_022F42F8 .public ov29_022F62CC .public ov29_022F87C0 diff --git a/asm/include/overlay_29_0232145C.inc b/asm/include/overlay_29_0232145C.inc index 73c06f3e..38b999ef 100644 --- a/asm/include/overlay_29_0232145C.inc +++ b/asm/include/overlay_29_0232145C.inc @@ -22,15 +22,15 @@ .public GetMoveNbStrikes .public GetNaturePowerVariant .public GravityIsActive -.public INTIMIDATOR_ACTIVATION_CHANCE .public InitMove .public InitMoveCheckId +.public INTIMIDATOR_ACTIVATION_CHANCE .public IqSkillIsEnabled .public Is2TurnsMove .public IsChargingTwoTurnMove .public IsFloorOver -.public IsMonsterSleeping .public IsMonster__02322DB8 +.public IsMonsterSleeping .public IsTrappingMove .public LogMessageByIdWithPopupCheckUser .public LogMessageWithPopupCheckUser @@ -38,27 +38,6 @@ .public METRONOME_TABLE .public NATURE_POWER_TABLE .public NIGHTMARE_TURN_RANGE -.public SLEEP_TURN_RANGE -.public StringFromId -.public SubstitutePlaceholderStringTags -.public TryInflictBlinkerStatus -.public TryInflictBurnStatus -.public TryInflictConfusedStatus -.public TryInflictConstrictionStatus -.public TryInflictCringeStatus -.public TryInflictFrozenStatus -.public TryInflictInfatuatedStatus -.public TryInflictInvisibleStatus -.public TryInflictNightmareStatus -.public TryInflictParalysisStatus -.public TryInflictPausedStatus -.public TryInflictPerishSongStatus -.public TryInflictPoisonedStatus -.public TryInflictShadowHoldStatus -.public TryInflictSleepStatus -.public TrySealMove -.public TryWarp -.public UpdateAiTargetPos .public ov10_022BFD6C .public ov10_022C4584 .public ov10_022C4714 @@ -86,4 +65,25 @@ .public ov29_0235370C .public ov29_0237CA68 .public ov29_0237CA88 +.public SLEEP_TURN_RANGE +.public StringFromId .public sub_0201D1B0 +.public SubstitutePlaceholderStringTags +.public TryInflictBlinkerStatus +.public TryInflictBurnStatus +.public TryInflictConfusedStatus +.public TryInflictConstrictionStatus +.public TryInflictCringeStatus +.public TryInflictFrozenStatus +.public TryInflictInfatuatedStatus +.public TryInflictInvisibleStatus +.public TryInflictNightmareStatus +.public TryInflictParalysisStatus +.public TryInflictPausedStatus +.public TryInflictPerishSongStatus +.public TryInflictPoisonedStatus +.public TryInflictShadowHoldStatus +.public TryInflictSleepStatus +.public TrySealMove +.public TryWarp +.public UpdateAiTargetPos diff --git a/asm/include/overlay_29_02322DDC.inc b/asm/include/overlay_29_02322DDC.inc index 170c2f0b..f147afe7 100644 --- a/asm/include/overlay_29_02322DDC.inc +++ b/asm/include/overlay_29_02322DDC.inc @@ -1,19 +1,20 @@ #pragma once +.public _s32_div_f .public AbilityIsActiveVeneer .public AdvanceFrame .public AnimationDelayOrSomething .public AnimationHasMoreFrames .public ChangeMonsterAnimation +.public DefenderAbilityIsActive__02322D64 .public DETECT_BAND_MOVE_ACCURACY_DROP .public DIRECTIONS_XY .public DUNGEON_PTR -.public DefenderAbilityIsActive__02322D64 .public DungeonRandInt .public DungeonRandOutcome__022EAB50 .public DungeonRandRange -.public EXCL_ITEM_EFFECTS_EVASION_BOOST .public EntityIsValid__02321438 .public EntityIsValid__02325620 +.public EXCL_ITEM_EFFECTS_EVASION_BOOST .public ExclusiveItemEffectFlagTest .public ExecuteMoveEffect .public FormatMoveStringMore @@ -45,16 +46,6 @@ .public MALE_EVASION_STAGE_MULTIPLIERS .public MoveIsNotPhysical .public NATURE_POWER_TABLE -.public PlayMoveAnimation -.public PositionHasMonster -.public QUICK_DODGER_MOVE_ACCURACY_DROP -.public SetAndLoadCurrentAttackAnimation -.public ShouldDisplayEntityAdvanced -.public ShouldDisplayEntityWrapper -.public ShouldMovePlayAlternativeAnimation -.public TWO_TURN_MOVES_AND_STATUSES -.public WanTableSpriteHasAnimationGroup -.public _s32_div_f .public ov10_022BDE50 .public ov10_022BE9E8 .public ov10_022BEB2C @@ -104,7 +95,16 @@ .public ov29_02352B1C .public ov29_0235370C .public ov29_0237CA84 +.public PlayMoveAnimation +.public PositionHasMonster +.public QUICK_DODGER_MOVE_ACCURACY_DROP +.public SetAndLoadCurrentAttackAnimation +.public ShouldDisplayEntityAdvanced +.public ShouldDisplayEntityWrapper +.public ShouldMovePlayAlternativeAnimation .public sub_020018D0 .public sub_02001980 .public sub_0201CF90 .public sub_0201D1D4 +.public TWO_TURN_MOVES_AND_STATUSES +.public WanTableSpriteHasAnimationGroup diff --git a/asm/include/overlay_29_023498A0.inc b/asm/include/overlay_29_023498A0.inc index dad46e39..ead3bbb2 100644 --- a/asm/include/overlay_29_023498A0.inc +++ b/asm/include/overlay_29_023498A0.inc @@ -7,10 +7,10 @@ .public ChangeDungeonMusic .public CloseAlertBox .public CreateAlertBox -.public DUNGEON_FADES_PTR -.public DUNGEON_PTR .public Debug_Print0 .public DisplayMessageInternal +.public DUNGEON_FADES_PTR +.public DUNGEON_PTR .public DungeonAlloc .public DungeonFree .public DungeonRandInt @@ -66,23 +66,6 @@ .public MemFree .public MemZero .public MusicTableIdxToMusicId -.public OverlayIsLoaded -.public PositionIsOnStairs -.public PreprocessString -.public RemoveEmptyItemsInBagWrapper -.public RemoveGroundItem -.public RunDungeon -.public SetAdventureLogDungeonFloor -.public SetBothScreensWindowsColor -.public SetDungeonTipShown -.public SetPortraitLayout -.public ShouldDisplayEntityWrapper -.public ShouldMonsterHeadToStairs -.public StringFromId -.public SubstitutePlaceholderStringTags -.public UnloadOverlay -.public WriteQuicksaveData -.public YesNoMenu .public ov10_022BF764 .public ov10_022BF7D4 .public ov10_022BFD20 @@ -199,6 +182,19 @@ .public ov30_02382A34 .public ov30_02382C30 .public ov30_023842F4 +.public OverlayIsLoaded +.public PositionIsOnStairs +.public PreprocessString +.public RemoveEmptyItemsInBagWrapper +.public RemoveGroundItem +.public RunDungeon +.public SetAdventureLogDungeonFloor +.public SetBothScreensWindowsColor +.public SetDungeonTipShown +.public SetPortraitLayout +.public ShouldDisplayEntityWrapper +.public ShouldMonsterHeadToStairs +.public StringFromId .public strlen .public strncmp .public strncpy @@ -267,3 +263,7 @@ .public sub_02051DD0 .public sub_02051E60 .public sub_0205BAB0 +.public SubstitutePlaceholderStringTags +.public UnloadOverlay +.public WriteQuicksaveData +.public YesNoMenu diff --git a/asm/include/overlay_29_0234D484.inc b/asm/include/overlay_29_0234D484.inc index a843c6fd..41b2c7bc 100644 --- a/asm/include/overlay_29_0234D484.inc +++ b/asm/include/overlay_29_0234D484.inc @@ -14,11 +14,6 @@ .public MemAlloc .public MemFree .public MemZero -.public OverlayIsLoaded -.public ShowPortraitInPortraitBox -.public ShowStringInDialogueBox -.public StringFromId -.public UnloadOverlay .public ov29_022E0B44 .public ov29_022EA370 .public ov29_022EA428 @@ -31,9 +26,14 @@ .public ov29_0234D304 .public ov29_02353398 .public ov29_02382800 +.public OverlayIsLoaded +.public ShowPortraitInPortraitBox +.public ShowStringInDialogueBox +.public StringFromId .public sub_02006B70 .public sub_020282F4 .public sub_0202AB94 .public sub_0202ABB0 .public sub_0202F334 .public sub_0202F474 +.public UnloadOverlay diff --git a/asm/itcm.s b/asm/itcm.s index a8bf65cb..f6d418a2 100644 --- a/asm/itcm.s +++ b/asm/itcm.s @@ -3,8 +3,8 @@ .section .itcm,4,1,4 - arm_func_start sub_01FF8000 -sub_01FF8000: ; 0x01FF8000 + arm_func_start CopyAndInterleave +CopyAndInterleave: ; 0x01FF8000 stmdb sp!, {r0, r1, r2, r3, r4, r5, r6, r7, lr} and r3, r3, #0xf mov r6, #0 @@ -55,7 +55,7 @@ _01FF8090: blt _01FF8014 _01FF80AC: ldmia sp!, {r0, r1, r2, r3, r4, r5, r6, r7, pc} - arm_func_end sub_01FF8000 + arm_func_end CopyAndInterleave arm_func_start sub_01FF80B0 sub_01FF80B0: ; 0x01FF80B0 @@ -91,13 +91,13 @@ _01FF811C: ldmia sp!, {r0, r1, r2, r3, r4, r5, r6, r7, pc} arm_func_end sub_01FF80B0 _01FF8120: - .word sub_01FF8224 - .word sub_01FF849C - .word sub_01FF8728 - .word sub_01FF8C28 + .word Render3dRectangle + .word Render3dQuadrilateral + .word Render3dTiling + .word Render3dTexture - arm_func_start sub_01FF8130 -sub_01FF8130: ; 0x01FF8130 + arm_func_start Render3dSetTextureParams +Render3dSetTextureParams: ; 0x01FF8130 stmdb sp!, {r4, r5, r6, lr} sub sp, sp, #0x10 ldr r2, _01FF81B8 ; =RENDER_3D @@ -139,10 +139,10 @@ _01FF81BC: .word _02099734 _01FF81C0: .word _02099744 _01FF81C4: .word _02099764 _01FF81C8: .word _02099784 - arm_func_end sub_01FF8130 + arm_func_end Render3dSetTextureParams - arm_func_start sub_01FF81CC -sub_01FF81CC: ; 0x01FF81CC + arm_func_start Render3dSetPaletteBase +Render3dSetPaletteBase: ; 0x01FF81CC ldr r2, _01FF8218 ; =RENDER_3D ldr r2, [r2, #4] cmp r2, r1 @@ -166,10 +166,10 @@ sub_01FF81CC: ; 0x01FF81CC _01FF8218: .word RENDER_3D _01FF821C: .word _02099744 _01FF8220: .word 0x040004AC - arm_func_end sub_01FF81CC + arm_func_end Render3dSetPaletteBase - arm_func_start sub_01FF8224 -sub_01FF8224: ; 0x01FF8224 + arm_func_start Render3dRectangle +Render3dRectangle: ; 0x01FF8224 stmdb sp!, {r4, r5, r6, lr} sub sp, sp, #0x40 mov r4, r0 @@ -209,7 +209,7 @@ sub_01FF8224: ; 0x01FF8224 str r0, [sp, #0x3c] ldrb r0, [r4, #0x22] ldrb r1, [r4, #0x23] - bl sub_01FF8480 + bl GeomSetPolygonAttributes mov r0, #0 str r0, [sp] str r0, [sp, #4] @@ -323,10 +323,10 @@ _01FF8470: .word 0x04000444 _01FF8474: .word 0x0400046C _01FF8478: .word 0x04000500 _01FF847C: .word 0x0400048C - arm_func_end sub_01FF8224 + arm_func_end Render3dRectangle - arm_func_start sub_01FF8480 -sub_01FF8480: ; 0x01FF8480 + arm_func_start GeomSetPolygonAttributes +GeomSetPolygonAttributes: ; 0x01FF8480 mov r0, r0, lsl #0x18 orr r2, r0, #0xc0 ldr r0, _01FF8498 ; =0x040004A4 @@ -335,10 +335,10 @@ sub_01FF8480: ; 0x01FF8480 bx lr .align 2, 0 _01FF8498: .word 0x040004A4 - arm_func_end sub_01FF8480 + arm_func_end GeomSetPolygonAttributes - arm_func_start sub_01FF849C -sub_01FF849C: ; 0x01FF849C + arm_func_start Render3dQuadrilateral +Render3dQuadrilateral: ; 0x01FF849C stmdb sp!, {r4, lr} sub sp, sp, #0x48 mov r4, r0 @@ -372,7 +372,7 @@ sub_01FF849C: ; 0x01FF849C str r1, [sp, #0x44] ldrb r1, [r4, #0x23] str ip, [sp, #0x14] - bl sub_01FF8480 + bl GeomSetPolygonAttributes mov r0, #0 str r0, [sp] str r0, [sp, #4] @@ -504,10 +504,10 @@ _01FF8718: .word 0x04000444 _01FF871C: .word 0x0400046C _01FF8720: .word 0x04000500 _01FF8724: .word 0x0400048C - arm_func_end sub_01FF849C + arm_func_end Render3dQuadrilateral - arm_func_start sub_01FF8728 -sub_01FF8728: ; 0x01FF8728 + arm_func_start Render3dTiling +Render3dTiling: ; 0x01FF8728 stmdb sp!, {r4, r5, r6, r7, r8, sb, sl, fp, lr} sub sp, sp, #0x4c mov sl, r0 @@ -521,10 +521,10 @@ sub_01FF8728: ; 0x01FF8728 add r0, sl, #0x14 str r3, [sp, #0x14] str r2, [sp, #0x18] - bl sub_01FF8130 + bl Render3dSetTextureParams ldr r1, [sl, #8] add r0, sl, #0x14 - bl sub_01FF81CC + bl Render3dSetPaletteBase ldrsh r7, [sl, #0xc] ldrsh r0, [sl, #0x10] ldrsh r6, [sl, #0xe] @@ -580,7 +580,7 @@ sub_01FF8728: ; 0x01FF8728 str r0, [sp, #0x48] ldrb r0, [sl, #0x30] ldrb r1, [sl, #0x31] - bl sub_01FF8480 + bl GeomSetPolygonAttributes ldr r1, _01FF89F8 ; =0x04000444 mov r2, #0 add r0, sp, #0x1c @@ -696,10 +696,10 @@ _01FF8A00: .word 0x04000500 _01FF8A04: .word 0x04000488 _01FF8A08: .word 0x04000480 _01FF8A0C: .word 0x04000504 - arm_func_end sub_01FF8728 + arm_func_end Render3dTiling - arm_func_start sub_01FF8A10 -sub_01FF8A10: ; 0x01FF8A10 + arm_func_start Render3dTextureInternal +Render3dTextureInternal: ; 0x01FF8A10 stmdb sp!, {r3, r4, r5, r6, r7, r8, sb, sl, fp, lr} sub sp, sp, #0x30 mov r8, r0 @@ -746,7 +746,7 @@ sub_01FF8A10: ; 0x01FF8A10 str r0, [sp, #0x2c] ldrb r0, [r8, #0x26] ldrb r1, [r8, #0x27] - bl sub_01FF8480 + bl GeomSetPolygonAttributes ldr r1, _01FF8C20 ; =0x04000444 mov r2, #0 add r0, sp, #0 @@ -835,10 +835,10 @@ sub_01FF8A10: ; 0x01FF8A10 _01FF8C1C: .word TRIG_TABLE _01FF8C20: .word 0x04000444 _01FF8C24: .word 0x0400046C - arm_func_end sub_01FF8A10 + arm_func_end Render3dTextureInternal - arm_func_start sub_01FF8C28 -sub_01FF8C28: ; 0x01FF8C28 + arm_func_start Render3dTexture +Render3dTexture: ; 0x01FF8C28 stmdb sp!, {r4, lr} mov r4, r0 ldrb r0, [r4, #0x27] @@ -846,27 +846,27 @@ sub_01FF8C28: ; 0x01FF8C28 ldmeqia sp!, {r4, pc} ldr r1, [r4, #4] add r0, r4, #0x14 - bl sub_01FF8130 + bl Render3dSetTextureParams ldr r1, [r4, #8] add r0, r4, #0x14 - bl sub_01FF81CC + bl Render3dSetPaletteBase mov r0, r4 - bl sub_01FF8A10 + bl Render3dTextureInternal ldmia sp!, {r4, pc} - arm_func_end sub_01FF8C28 + arm_func_end Render3dTexture - arm_func_start sub_01FF8C60 -sub_01FF8C60: ; 0x01FF8C60 + arm_func_start Render3dTextureNoSetup +Render3dTextureNoSetup: ; 0x01FF8C60 stmdb sp!, {r3, lr} ldrb r1, [r0, #0x27] cmp r1, #0 ldmeqia sp!, {r3, pc} - bl sub_01FF8A10 + bl Render3dTextureInternal ldmia sp!, {r3, pc} - arm_func_end sub_01FF8C60 + arm_func_end Render3dTextureNoSetup - arm_func_start AllocateRender3dElement -AllocateRender3dElement: ; 0x01FF8C78 + arm_func_start NewRender3dElement +NewRender3dElement: ; 0x01FF8C78 ldr r0, _01FF8CA8 ; =RENDER_3D ldrsh r2, [r0] ldrsh r1, [r0, #2] @@ -881,13 +881,13 @@ AllocateRender3dElement: ; 0x01FF8C78 bx lr .align 2, 0 _01FF8CA8: .word RENDER_3D - arm_func_end AllocateRender3dElement + arm_func_end NewRender3dElement - arm_func_start sub_01FF8CAC -sub_01FF8CAC: ; 0x01FF8CAC + arm_func_start EnqueueRender3dTexture +EnqueueRender3dTexture: ; 0x01FF8CAC stmdb sp!, {r3, r4, r5, lr} mov r5, r0 - bl AllocateRender3dElement + bl NewRender3dElement movs r4, r0 ldmeqia sp!, {r3, r4, r5, pc} mov r0, r5 @@ -897,13 +897,13 @@ sub_01FF8CAC: ; 0x01FF8CAC mov r0, #3 strh r0, [r4] ldmia sp!, {r3, r4, r5, pc} - arm_func_end sub_01FF8CAC + arm_func_end EnqueueRender3dTexture - arm_func_start sub_01FF8CDC -sub_01FF8CDC: ; 0x01FF8CDC + arm_func_start EnqueueRender3dTiling +EnqueueRender3dTiling: ; 0x01FF8CDC stmdb sp!, {r3, r4, r5, lr} mov r5, r0 - bl AllocateRender3dElement + bl NewRender3dElement movs r4, r0 ldmeqia sp!, {r3, r4, r5, pc} mov r0, r5 @@ -913,12 +913,12 @@ sub_01FF8CDC: ; 0x01FF8CDC mov r0, #2 strh r0, [r4] ldmia sp!, {r3, r4, r5, pc} - arm_func_end sub_01FF8CDC + arm_func_end EnqueueRender3dTiling - arm_func_start sub_01FF8D0C -sub_01FF8D0C: ; 0x01FF8D0C + arm_func_start NewRender3dRectangle +NewRender3dRectangle: ; 0x01FF8D0C stmdb sp!, {r4, lr} - bl AllocateRender3dElement + bl NewRender3dElement movs r4, r0 moveq r0, #0 ldmeqia sp!, {r4, pc} @@ -929,12 +929,12 @@ sub_01FF8D0C: ; 0x01FF8D0C mov r0, r4 strh r1, [r4] ldmia sp!, {r4, pc} - arm_func_end sub_01FF8D0C + arm_func_end NewRender3dRectangle - arm_func_start sub_01FF8D3C -sub_01FF8D3C: ; 0x01FF8D3C + arm_func_start NewRender3dQuadrilateral +NewRender3dQuadrilateral: ; 0x01FF8D3C stmdb sp!, {r4, lr} - bl AllocateRender3dElement + bl NewRender3dElement movs r4, r0 moveq r0, #0 ldmeqia sp!, {r4, pc} @@ -945,12 +945,12 @@ sub_01FF8D3C: ; 0x01FF8D3C mov r0, r4 strh r1, [r4] ldmia sp!, {r4, pc} - arm_func_end sub_01FF8D3C + arm_func_end NewRender3dQuadrilateral - arm_func_start sub_01FF8D6C -sub_01FF8D6C: ; 0x01FF8D6C + arm_func_start NewRender3dTexture +NewRender3dTexture: ; 0x01FF8D6C stmdb sp!, {r4, lr} - bl AllocateRender3dElement + bl NewRender3dElement movs r4, r0 moveq r0, #0 ldmeqia sp!, {r4, pc} @@ -961,12 +961,12 @@ sub_01FF8D6C: ; 0x01FF8D6C mov r0, r4 strh r1, [r4] ldmia sp!, {r4, pc} - arm_func_end sub_01FF8D6C + arm_func_end NewRender3dTexture - arm_func_start sub_01FF8D9C -sub_01FF8D9C: ; 0x01FF8D9C + arm_func_start NewRender3dTiling +NewRender3dTiling: ; 0x01FF8D9C stmdb sp!, {r4, lr} - bl AllocateRender3dElement + bl NewRender3dElement movs r4, r0 moveq r0, #0 ldmeqia sp!, {r4, pc} @@ -977,10 +977,10 @@ sub_01FF8D9C: ; 0x01FF8D9C mov r0, r4 strh r1, [r4] ldmia sp!, {r4, pc} - arm_func_end sub_01FF8D9C + arm_func_end NewRender3dTiling - arm_func_start Render3dStack -Render3dStack: ; 0x01FF8DCC + arm_func_start Render3dProcessQueue +Render3dProcessQueue: ; 0x01FF8DCC stmdb sp!, {r3, r4, r5, r6, r7, lr} sub sp, sp, #0x200 ldr r0, _01FF8EFC ; =RENDER_3D @@ -1072,7 +1072,7 @@ _01FF8EF4: .align 2, 0 _01FF8EFC: .word RENDER_3D _01FF8F00: .word _01FF8120 - arm_func_end Render3dStack + arm_func_end Render3dProcessQueue arm_func_start sub_01FF8F04 sub_01FF8F04: ; 0x01FF8F04 @@ -1785,8 +1785,8 @@ _01FF95D8: _01FF95E4: .word 0x00000483 arm_func_end GetKeyM2NBaseForm - arm_func_start sub_01FF95E8 -sub_01FF95E8: ; 0x01FF95E8 + arm_func_start HardwareInterrupt +HardwareInterrupt: ; 0x01FF95E8 stmdb sp!, {lr} mov ip, #0x4000000 add ip, ip, #0x210 @@ -1814,15 +1814,15 @@ _01FF9620: rsbs r0, r0, #0x1f ldr r1, _01FF9648 ; =OS_IRQTable ldr r0, [r1, r0, lsl #2] - ldr lr, _01FF964C ; =sub_01FF9650 + ldr lr, _01FF964C ; =ReturnFromInterrupt bx r0 .align 2, 0 _01FF9648: .word OS_IRQTable -_01FF964C: .word sub_01FF9650 - arm_func_end sub_01FF95E8 +_01FF964C: .word ReturnFromInterrupt + arm_func_end HardwareInterrupt - arm_func_start sub_01FF9650 -sub_01FF9650: ; 0x01FF9650 + arm_func_start ReturnFromInterrupt +ReturnFromInterrupt: ; 0x01FF9650 ldr ip, _01FF97BC ; =DTCM_BSS mov r3, #0 ldr ip, [ip] @@ -1934,7 +1934,7 @@ _01FF97BC: .word DTCM_BSS _01FF97C0: .word _022B966C _01FF97C4: .word sub_02080EF0 _01FF97C8: .word sub_02080F30 - arm_func_end sub_01FF9650 + arm_func_end ReturnFromInterrupt arm_func_start sub_01FF97CC sub_01FF97CC: ; 0x01FF97CC @@ -2140,8 +2140,8 @@ _01FF9A60: .word 0x040001A1 _01FF9A64: .word 0x04100010 arm_func_end sub_01FF9990 - arm_func_start sub_01FF9A68 -sub_01FF9A68: ; 0x01FF9A68 + arm_func_start InitDmaTransfer_Standard +InitDmaTransfer_Standard: ; 0x01FF9A68 stmdb sp!, {r3, r4, r5, r6, r7, lr} mov r7, r0 mov r6, r1 @@ -2158,7 +2158,7 @@ sub_01FF9A68: ; 0x01FF9A68 str r4, [r1, #8] bl SetIrqFlag ldmia sp!, {r3, r4, r5, r6, r7, pc} - arm_func_end sub_01FF9A68 + arm_func_end InitDmaTransfer_Standard arm_func_start sub_01FF9AA8 sub_01FF9AA8: ; 0x01FF9AA8 diff --git a/asm/main_0200ED1C.s b/asm/main_0200ED1C.s index 2d8a3c87..d6a96040 100644 --- a/asm/main_0200ED1C.s +++ b/asm/main_0200ED1C.s @@ -15492,7 +15492,7 @@ _0201AB40: ldrh r3, [ip, #0xc] ldr r0, [ip, #8] mov r2, r2, asr #1 - bl sub_01FF8000 + bl CopyAndInterleave ldmia sp!, {r3, pc} _0201AB60: cmp r0, #2 @@ -17104,11 +17104,11 @@ _0201BFEC: .word _020AFC4C arm_func_start sub_0201BFF0 sub_0201BFF0: ; 0x0201BFF0 - ldr ip, _0201BFFC ; =sub_01FF8000 + ldr ip, _0201BFFC ; =CopyAndInterleave mov r2, r2, asr #1 bx ip .align 2, 0 -_0201BFFC: .word sub_01FF8000 +_0201BFFC: .word CopyAndInterleave arm_func_end sub_0201BFF0 arm_func_start sub_0201C000 @@ -17779,7 +17779,7 @@ _0201C860: tst r0, #2 bne _0201C910 add r0, sp, #0x5c - bl sub_01FF8CAC + bl EnqueueRender3dTexture _0201C910: ldrb r0, [sb, #0x22] cmp r0, #0 @@ -20043,7 +20043,7 @@ _0201E5AC: .word 0x040004A4 sub_0201E5B0: ; 0x0201E5B0 stmdb sp!, {r3, lr} sub sp, sp, #0x10 - bl Render3dStack + bl Render3dProcessQueue mov r0, #0 str r0, [sp] str r0, [sp, #4] @@ -20244,7 +20244,7 @@ sub_0201E7D8: ; 0x0201E7D8 Render3d64Texture0x7: ; 0x0201E844 stmdb sp!, {r3, r4, r5, r6, r7, r8, sb, sl, fp, lr} mov r4, r0 - bl sub_01FF8D6C + bl NewRender3dTexture ldrsh r1, [r4] mov r5, #0 strh r1, [r0, #0x16] @@ -20535,7 +20535,7 @@ _0201EA04: EnqueueRender3d64Tiling: ; 0x0201EC9C stmdb sp!, {r4, lr} mov r4, r0 - bl sub_01FF8D9C + bl NewRender3dTiling ldrsh r2, [r4] mov r1, #0 strh r2, [r0, #0x16] @@ -20600,7 +20600,7 @@ _0201ED74: Render3d64Tiling: ; 0x0201ED88 stmdb sp!, {r3, r4, r5, lr} mov r4, r0 - bl sub_01FF8D9C + bl NewRender3dTiling mov r1, #0 _0201ED98: mov r2, r1, lsl #2 @@ -20656,7 +20656,7 @@ _0201EE3C: Render3d64Quadrilateral: ; 0x0201EE50 stmdb sp!, {r3, r4, r5, lr} mov r4, r0 - bl sub_01FF8D3C + bl NewRender3dQuadrilateral mov r1, #0 _0201EE60: mov r2, r1, lsl #2 @@ -20701,7 +20701,7 @@ _0201EE60: Render3d64RectangleMulticolor: ; 0x0201EEF0 stmdb sp!, {r4, lr} mov r4, r0 - bl sub_01FF8D0C + bl NewRender3dRectangle ldrh r1, [r4] strh r1, [r0, #4] ldrh r1, [r4, #2] @@ -20797,7 +20797,7 @@ _0201F034: Render3d64Rectangle: ; 0x0201F05C stmdb sp!, {r4, lr} mov r4, r0 - bl sub_01FF8D0C + bl NewRender3dRectangle ldrh r1, [r4] mov r2, #0 strh r1, [r0, #4] @@ -20849,7 +20849,7 @@ Render3d64Nothing: ; 0x0201F108 Render3d64Texture: ; 0x0201F10C stmdb sp!, {r4, lr} mov r4, r0 - bl sub_01FF8D6C + bl NewRender3dTexture ldrsh r1, [r4] add ip, r4, #0x16 add r3, r0, #0xc diff --git a/asm/main_0202598C.s b/asm/main_0202598C.s index 647bb107..f843d3f2 100644 --- a/asm/main_0202598C.s +++ b/asm/main_0202598C.s @@ -849,7 +849,7 @@ sub_02026020: ; 0x02026020 stmdb sp!, {r4, lr} mov r4, r0 mov r0, r1 - bl sub_020265C4 + bl GetColorCodePaletteOffset str r0, [r4, #0x110] ldmia sp!, {r4, pc} arm_func_end sub_02026020 @@ -1308,7 +1308,7 @@ sub_020264F8: ; 0x020264F8 addlo r6, r6, r0, asr #1 #endif ldrb r0, [sp, #0x18] - bl sub_020265C4 + bl GetColorCodePaletteOffset str r0, [sp] mov r0, r7 mov r1, r6 @@ -1378,8 +1378,8 @@ _020265BC: .word sub_0202654C _020265C0: .word sub_02026594 arm_func_end sub_020265A8 - arm_func_start sub_020265C4 -sub_020265C4: ; 0x020265C4 + arm_func_start GetColorCodePaletteOffset +GetColorCodePaletteOffset: ; 0x020265C4 sub r0, r0, #0x41 cmp r0, #0x31 addls pc, pc, r0, lsl #2 @@ -1513,7 +1513,7 @@ _0202675C: _02026764: mov r0, #0x17 bx lr - arm_func_end sub_020265C4 + arm_func_end GetColorCodePaletteOffset arm_func_start sub_0202676C sub_0202676C: ; 0x0202676C diff --git a/asm/main_02054C24.s b/asm/main_02054C24.s index 16954ee2..aaf0ff6a 100644 --- a/asm/main_02054C24.s +++ b/asm/main_02054C24.s @@ -20015,7 +20015,7 @@ _02064EB0: add r0, sp, #0x10 strh r2, [sp, #0x32] strh r1, [sp, #0x34] - bl sub_01FF8CDC + bl EnqueueRender3dTiling add r0, sb, #1 mov r0, r0, lsl #0x10 mov sb, r0, asr #0x10 diff --git a/asm/main_0207BC3C.s b/asm/main_0207BC3C.s index 7ef4780f..1a07a702 100644 --- a/asm/main_0207BC3C.s +++ b/asm/main_0207BC3C.s @@ -204,7 +204,7 @@ _0207BEAC: mov r1, r7 mov r2, r6 orr r3, r3, #0xc4000000 - bl sub_01FF9A68 + bl InitDmaTransfer_Standard ldmia sp!, {r4, r5, r6, r7, r8, pc} _0207BEE8: mov r3, r5, lsr #2 @@ -212,7 +212,7 @@ _0207BEE8: mov r1, r7 mov r2, r6 orr r3, r3, #0x84000000 - bl sub_01FF9A68 + bl InitDmaTransfer_Standard ldmia sp!, {r4, r5, r6, r7, r8, pc} arm_func_end sub_0207BE6C @@ -249,7 +249,7 @@ _0207BF44: mov r1, r7 mov r2, r6 orr r3, r3, r5, lsr #2 - bl sub_01FF9A68 + bl InitDmaTransfer_Standard ldmia sp!, {r4, r5, r6, r7, r8, pc} _0207BF84: ldr r3, _0207BFA0 ; =0x84400000 @@ -257,7 +257,7 @@ _0207BF84: mov r1, r7 mov r2, r6 orr r3, r3, r5, lsr #2 - bl sub_01FF9A68 + bl InitDmaTransfer_Standard ldmia sp!, {r4, r5, r6, r7, r8, pc} .align 2, 0 _0207BFA0: .word 0x84400000 @@ -295,7 +295,7 @@ _0207BFE4: mov r1, r7 mov r2, r6 orr r3, r3, #0xc0000000 - bl sub_01FF9A68 + bl InitDmaTransfer_Standard ldmia sp!, {r4, r5, r6, r7, r8, pc} _0207C020: mov r3, r5, lsr #1 @@ -303,7 +303,7 @@ _0207C020: mov r1, r7 mov r2, r6 orr r3, r3, #0x80000000 - bl sub_01FF9A68 + bl InitDmaTransfer_Standard ldmia sp!, {r4, r5, r6, r7, r8, pc} arm_func_end sub_0207BFA4 @@ -340,7 +340,7 @@ _0207C07C: mov r1, r7 mov r2, r6 orr r3, r3, r5, lsr #1 - bl sub_01FF9A68 + bl InitDmaTransfer_Standard ldmia sp!, {r4, r5, r6, r7, r8, pc} _0207C0BC: ldr r3, _0207C0D8 ; =0x80400000 @@ -348,7 +348,7 @@ _0207C0BC: mov r1, r7 mov r2, r6 orr r3, r3, r5, lsr #1 - bl sub_01FF9A68 + bl InitDmaTransfer_Standard ldmia sp!, {r4, r5, r6, r7, r8, pc} .align 2, 0 _0207C0D8: .word 0x80400000 @@ -957,7 +957,7 @@ _0207C79C: mov r0, r6 mov r1, r5 mov r2, r4 - bl sub_01FF9A68 + bl InitDmaTransfer_Standard ldmia sp!, {r3, r4, r5, r6, r7, pc} .align 2, 0 _0207C7C0: .word 0xAF000001 diff --git a/asm/main_0207F894.s b/asm/main_0207F894.s index 067f480d..b17700d4 100644 --- a/asm/main_0207F894.s +++ b/asm/main_0207F894.s @@ -5369,7 +5369,7 @@ _02083ED4: cmp r1, #0 beq _02083F28 bl sub_0207AACC - ldr r1, _02084018 ; =sub_01FF8000 + ldr r1, _02084018 ; =CopyAndInterleave add r3, sb, r5 cmp r3, r1 mov r1, #1 @@ -5459,7 +5459,7 @@ _0208400C: ldmia sp!, {r3, r4, r5, r6, r7, r8, sb, sl, fp, pc} .align 2, 0 _02084014: .word _022BB7E0 -_02084018: .word sub_01FF8000 +_02084018: .word CopyAndInterleave _0208401C: .word 0x000001FF _02084020: .word _020B2ED0 _02084024: .word sub_02083DCC diff --git a/asm/overlay_00.s b/asm/overlay_00.s index 7b04b43f..ea61caaa 100644 --- a/asm/overlay_00.s +++ b/asm/overlay_00.s @@ -32294,7 +32294,7 @@ ov00_022D73E0: ; 0x022D73E0 ldr r2, [r0, #8] cmp r2, #0 bne _022D7408 - ldr r1, _022D742C ; =sub_01FF95E8 + ldr r1, _022D742C ; =HardwareInterrupt str r1, [r0, #8] ldr r1, [r0, #0xc] add r1, r1, #1 @@ -32302,7 +32302,7 @@ ov00_022D73E0: ; 0x022D73E0 mov r0, #1 bx lr _022D7408: - ldr r1, _022D742C ; =sub_01FF95E8 + ldr r1, _022D742C ; =HardwareInterrupt cmp r2, r1 movne r0, #0 bxne lr @@ -32312,14 +32312,14 @@ _022D7408: mov r0, #1 bx lr .align 2, 0 -_022D742C: .word sub_01FF95E8 +_022D742C: .word HardwareInterrupt arm_func_end ov00_022D73E0 arm_func_start ov00_022D7430 ov00_022D7430: ; 0x022D7430 stmdb sp!, {r3, lr} ldr r2, [r0, #8] - ldr r1, _022D7464 ; =sub_01FF95E8 + ldr r1, _022D7464 ; =HardwareInterrupt cmp r2, r1 ldmneia sp!, {r3, pc} ldr r1, [r0, #0xc] @@ -32331,7 +32331,7 @@ ov00_022D7430: ; 0x022D7430 bl sub_020798D8 ldmia sp!, {r3, pc} .align 2, 0 -_022D7464: .word sub_01FF95E8 +_022D7464: .word HardwareInterrupt arm_func_end ov00_022D7430 arm_func_start ov00_022D7468 diff --git a/asm/overlay_29_022DC314.s b/asm/overlay_29_022DC314.s index 1c276086..2abd5362 100644 --- a/asm/overlay_29_022DC314.s +++ b/asm/overlay_29_022DC314.s @@ -77,10 +77,10 @@ ov29_022DC33C: ; 0x022DC33C ldr r4, [r3, #0xe0] add r0, sp, #0 mov r1, #0x1b000 - bl sub_01FF8130 + bl Render3dSetTextureParams add r0, sp, #0 add r1, r4, #0x3c00 - bl sub_01FF81CC + bl Render3dSetPaletteBase ldr r0, _022DC53C ; =0x00018304 mov r5, #0 ldr r4, _022DC530 ; =ov29_02353880 @@ -136,7 +136,7 @@ _022DC454: strh r3, [r4, #0x12] strh r2, [r4, #0x22] strh r1, [r4] - bl sub_01FF8C60 + bl Render3dTextureNoSetup _022DC50C: add r0, r5, #1 mov r0, r0, lsl #0x10 diff --git a/asm/overlay_29_022E9618.s b/asm/overlay_29_022E9618.s index ecc7e81f..9215ec33 100644 --- a/asm/overlay_29_022E9618.s +++ b/asm/overlay_29_022E9618.s @@ -11,8 +11,8 @@ GetLeaderMonster: ; 0x022E9618 ldmia sp!, {r3, pc} arm_func_end GetLeaderMonster - arm_func_start ov29_022E9628 -ov29_022E9628: ; 0x022E9628 + arm_func_start GetRandomTile +GetRandomTile: ; 0x022E9628 stmdb sp!, {r3, r4, r5, r6, r7, r8, sb, sl, fp, lr} sub sp, sp, #0xe20 mov sl, r0 @@ -165,7 +165,7 @@ _022E9830: _022E983C: add sp, sp, #0xe20 ldmia sp!, {r3, r4, r5, r6, r7, r8, sb, sl, fp, pc} - arm_func_end ov29_022E9628 + arm_func_end GetRandomTile arm_func_start FindNearbyUnoccupiedTile FindNearbyUnoccupiedTile: ; 0x022E9844 diff --git a/asm/overlay_29_022FC9C0.s b/asm/overlay_29_022FC9C0.s index 47162ca7..50fe1462 100644 --- a/asm/overlay_29_022FC9C0.s +++ b/asm/overlay_29_022FC9C0.s @@ -194,7 +194,7 @@ _022FCC48: _022FCC60: mov r0, r5 mov r1, fp - bl ov29_022E9628 + bl GetRandomTile cmp r0, #0 beq _022FCCC4 ldrsh r0, [sp, #0x14] diff --git a/asm/overlay_29_0230A9B8.s b/asm/overlay_29_0230A9B8.s index fa5599c7..afa279a2 100644 --- a/asm/overlay_29_0230A9B8.s +++ b/asm/overlay_29_0230A9B8.s @@ -4585,7 +4585,7 @@ _0230E844: beq _0230E8D0 add r0, sp, #0xa mov r1, #0 - bl ov29_022E9628 + bl GetRandomTile cmp r0, #0 beq _0230E8D0 mov r1, #0 diff --git a/asm/overlay_29_02320788.s b/asm/overlay_29_02320788.s index cdc340b5..39a4e65f 100644 --- a/asm/overlay_29_02320788.s +++ b/asm/overlay_29_02320788.s @@ -556,7 +556,7 @@ _02320EB0: ; jump table _02320EC8: add r0, sp, #0 mov r1, #1 - bl ov29_022E9628 + bl GetRandomTile cmp r0, #0 bne _02321008 ldrh r0, [r8, #4] @@ -643,7 +643,7 @@ _02320FB0: _02320FE4: add r0, sp, #0 mov r1, #1 - bl ov29_022E9628 + bl GetRandomTile cmp r0, #0 ldreqh r0, [r8, #4] moveq r4, #1 diff --git a/lib/asm/crt0.s b/lib/asm/crt0.s index 5b5e9bc9..f82f406f 100644 --- a/lib/asm/crt0.s +++ b/lib/asm/crt0.s @@ -76,7 +76,7 @@ _020008D4: ldr r1, _02000930 ; =OS_IRQTable add r1, r1, #0x3fc0 add r1, r1, #0x3c - ldr r0, _02000948 ; =sub_01FF95E8 + ldr r0, _02000948 ; =HardwareInterrupt str r0, [r1] bl _fp_init bl sub_02000B98 @@ -97,7 +97,7 @@ _02000938: .word 0x05000000 _0200093C: .word 0x07000000 _02000940: .word _start_ModuleParams _02000944: .word 0x027FFF9C -_02000948: .word sub_01FF95E8 +_02000948: .word HardwareInterrupt _0200094C: .word NitroMain _02000950: .word 0xFFFF0000 arm_func_end _start diff --git a/lib/asm/include/crt0.inc b/lib/asm/include/crt0.inc index 5736ed82..618616b2 100644 --- a/lib/asm/include/crt0.inc +++ b/lib/asm/include/crt0.inc @@ -1,5 +1,6 @@ #pragma once .public _fp_init +.public HardwareInterrupt .public NitroMain .public OS_IRQTable .public SDK_AUTOLOAD_LIST @@ -7,5 +8,4 @@ .public SDK_AUTOLOAD_START .public SDK_STATIC_BSS_END .public SDK_STATIC_BSS_START -.public sub_01FF95E8 .public sub_020908A8 diff --git a/tools/sync_pmdsky_debug/pmdsky_debug_reader.py b/tools/sync_pmdsky_debug/pmdsky_debug_reader.py index 2865e09c..1108480e 100644 --- a/tools/sync_pmdsky_debug/pmdsky_debug_reader.py +++ b/tools/sync_pmdsky_debug/pmdsky_debug_reader.py @@ -19,6 +19,7 @@ # Symbols with duplicate addresses that should be ignored. SYMBOL_BLACKLIST = set([ 'GAME_STATE_VALUES', + 'MEMORY_ALLOCATION_TABLE' ]) """ diff --git a/tools/sync_pmdsky_debug/symbol_details.py b/tools/sync_pmdsky_debug/symbol_details.py index 631e903c..04b813c7 100644 --- a/tools/sync_pmdsky_debug/symbol_details.py +++ b/tools/sync_pmdsky_debug/symbol_details.py @@ -101,6 +101,12 @@ WRAM_OFFSET = 0x1477E18 +ITCM_RAM_START_ADDRESSES = { + 'NA': 0x20B3380, + 'EU': 0x20B3CC0, + 'JP': 0x20B4BE0 +} + @dataclass class SymbolDetails: name: str diff --git a/tools/sync_pmdsky_debug/sync_to_pmdsky_debug.py b/tools/sync_pmdsky_debug/sync_to_pmdsky_debug.py index f03c5a3c..1b8f7fec 100644 --- a/tools/sync_pmdsky_debug/sync_to_pmdsky_debug.py +++ b/tools/sync_pmdsky_debug/sync_to_pmdsky_debug.py @@ -7,7 +7,7 @@ from ruamel.yaml.scalarint import HexCapsInt from pmdsky_debug_reader import LANGUAGE_KEYS_XMAP_TO_PMDSKY_DEBUG, SYMBOLS_FOLDER, get_pmdsky_debug_location, read_pmdsky_debug_symbols -from symbol_details import NONMATCHING_SYMBOLS_ARM7, NONMATCHING_SYMBOLS_ARM9, WRAM_OFFSET, SymbolDetails +from symbol_details import ITCM_RAM_START_ADDRESSES, NONMATCHING_SYMBOLS_ARM7, NONMATCHING_SYMBOLS_ARM9, WRAM_OFFSET, SymbolDetails from xmap_reader import HEADER_FOLDER, read_xmap_symbols from yaml_writer import YamlManager, yaml @@ -202,9 +202,14 @@ def sync_xmap_symbol(address: int, symbol: SymbolDetails, language: str, section symbol_entry_addresses.sort() return else: - symbol_entry_language_addresses[language_key] = HexCapsInt(hex_address) - if reorder_languages: - symbol_entry_language_addresses.move_to_end(language_key, last=False) + if section_name == 'ITCM': + # ITCM needs to be handled specially to add both ROM and RAM addresses. + symbol_entry_language_addresses[language_key] = HexCapsInt(ITCM_RAM_START_ADDRESSES[language_key] + (hex_address - 0x1FF8000)) + symbol_entry_language_addresses[f'{language_key}-ITCM'] = hex_address + else: + symbol_entry_language_addresses[language_key] = HexCapsInt(hex_address) + if reorder_languages: + symbol_entry_language_addresses.move_to_end(language_key, last=False) if wram_address is not None: symbol_entry_language_addresses[language_key + '-WRAM'] = HexCapsInt(wram_address) diff --git a/tools/sync_pmdsky_debug/xmap_reader.py b/tools/sync_pmdsky_debug/xmap_reader.py index 25e3232d..5df09440 100644 --- a/tools/sync_pmdsky_debug/xmap_reader.py +++ b/tools/sync_pmdsky_debug/xmap_reader.py @@ -70,9 +70,9 @@ def read_xmap_file(xmap_lines): if current_section is not None and is_ram: current_section = 'ram' if current_section is not None and current_section not in xmap_symbols: - xmap_symbols[current_section]: Dict[str, int] = {} + xmap_symbols[current_section] = {} - elif current_section is not None and line.startswith(' ') and ('.text' in line or '.data' in line or '.bss' in line) and len(line) > 28 and line[28] not in NON_FUNCTION_SYMBOLS: + elif current_section is not None and line.startswith(' ') and ('.text' in line or '.data' in line or '.bss' in line or '.itcm' in line) and len(line) > 28 and line[28] not in NON_FUNCTION_SYMBOLS: symbol_split = line[28:-1].split('\t') symbol_name = symbol_split[0] symbol_address = int(line[2:10], 16)