This commit is contained in:
AnonymousRandomPerson 2024-10-18 18:54:33 -04:00
commit 1999f0b9eb
18 changed files with 49760 additions and 617 deletions

View File

@ -0,0 +1,816 @@
#pragma once
.public ADVENTURE_LOG_ENCOUNTERS_MONSTER_IDS
.public ADVENTURE_LOG_PTR
.public ARM9_UNKNOWN_DATA__NA_209E6BC
.public ARM9_UNKNOWN_PTR__NA_20A2C84
.public ARM9_UNKNOWN_TABLE__NA_209E12C
.public ARM9_UNKNOWN_TABLE__NA_209E164
.public ARM9_UNKNOWN_TABLE__NA_209E280
.public ARM9_UNKNOWN_TABLE__NA_20A20B0
.public AddItemToStorage
.public AddMoneyCarried
.public Arm9LoadUnkFieldNa0x2029EC8
.public Arm9StoreUnkFieldNa0x2029ED8
.public ArrayCopy32
.public ArrayFill32
.public BAG_CAPACITY_TABLE
.public BAG_CAPACITY_TABLE_SPECIAL_EPISODES
.public BAG_ITEMS_PTR_MIRROR
.public CLIENT_LEVEL_TABLE
.public CanMonsterUseMove
.public CardBackupError
.public CardPullOutWithStatus
.public CheckDebugMenuField0x1A4
.public CheckOptionsMenuField0x1A4
.public CheckParentMenuField0x1A0
.public ClearWindow
.public CloseAdvancedMenu
.public CloseAdvancedTextBox
.public CloseAdvancedTextBox2
.public CloseCollectionMenu
.public CloseDebugMenu
.public CloseDialogueBox
.public CloseOptionsMenu
.public CloseParentMenu
.public ClosePortraitBox
.public CloseScrollBox
.public CloseSimpleMenu
.public CloseTeamSelectionMenu
.public CloseTextBox
.public CloseTextBox2
.public ConvertStorageItemAtIdxToItem
.public CopyNStringFromId
.public CountNbOfItemsInStorage
.public CountNbOfValidItemsInStorage
.public CountNbOfValidItemsInTimeDarknessInStorage
.public CreateAdvancedMenu
.public CreateAdvancedTextBox
.public CreateAdvancedTextBoxWithArg
.public CreateCollectionMenu
.public CreateDebugMenu
.public CreateDialogueBox
.public CreateOptionsMenu
.public CreateParentMenu
.public CreateParentMenuFromStringIds
.public CreatePortraitBox
.public CreateScrollBoxMulti
.public CreateScrollBoxSingle
.public CreateSimpleMenu
.public CreateSimpleMenuFromStringIds
.public CreateTeamSelectionMenu
.public CreateTextBox
.public CreateTextBoxWithArg
.public DEFAULT_HERO_ID
.public DUNGEON_DATA_LIST
.public DUNGEON_PTR
.public DUNGEON_RESTRICTIONS
.public Debug_FatalError
.public Debug_GetDebugFlag
.public Debug_GetLogFlag
.public Debug_Print
.public Debug_Print0
.public Debug_SetDebugFlag
.public Debug_SetLogFlag
.public DecompressAtNormalVeneer
.public DexNumbersEqual
.public DirectoryFileMngr_OpenDirectoryFile
.public DisableIqSkill
.public DrawTextInWindow
.public DrawTileGrid
.public DungeonSwapIdToIdx
.public DungeonSwapIdxToId
.public DungeonToGroundMoveset
.public EnableAllLearnableIqSkills
.public FORBIDDEN_FORGOT_MOVE_LIST
.public FemaleToMaleForm
.public FileClose
.public FileRom_HandleOpen
.public FileRom_HandleRead
.public FileRom_HandleSeek
.public FileRom_InitDataTransfer
.public FileRom_StopDataTransfer
.public FileRom_Veneer_FileInit
.public FormatMoveStringMore
.public GAME_MODE
.public GLOBAL_PROGRESS_PTR
.public GUEST_MONSTER_DATA
.public GetActiveRosterIndex
.public GetActiveTeamMember
.public GetActualSellPrice
.public GetAdvancedMenuCurrentOption
.public GetAdvancedMenuResult
.public GetAdvancedTextBoxFlags2
.public GetAtSize
.public GetCurrentBagCapacity
.public GetDungeonModeSpecial
.public GetDungeonResultString
.public GetEvolutionPossibilities
.public GetHeldButtons
.public GetHero
.public GetHeroMemberIdx
.public GetInfoGroundMoveset
.public GetInfoMoveGround
.public GetIqSkillStringId
.public GetItemAtIdx
.public GetItemCategory
.public GetItemCategoryVeneer
.public GetItemIdFromList
.public GetItemMoveId16
.public GetKeyM2NSwitch
.public GetKeyN2MSwitch
.public GetLanguage
.public GetLanguageType
.public GetLearnableIqSkills
.public GetMainCharacter1MemberIdx
.public GetMainCharacter2MemberIdx
.public GetMainCharacter3MemberIdx
.public GetMaxPp
.public GetMoneyCarried
.public GetMoneyStored
.public GetMonsterName
.public GetMoveRangeId
.public GetMoveType
.public GetMovesetEggPtr
.public GetMovesetHmTmPtr
.public GetMovesetIdx__02013CAC
.public GetMovesetLevelUpPtr
.public GetNbItemsInBag
.public GetNbMoves
.public GetNextIqSkill
.public GetPartner
.public GetPartnerMemberIdx
.public GetPartyMembers
.public GetPpIncrease
.public GetPressedButtons
.public GetReleasedStylus
.public GetRngSeed
.public GetSimpleMenuResult
.public GetSosMailCount
.public GetStringFromFileVeneer
.public GetTeamMember
.public GetTime
.public GetWindow
.public GroundToDungeonMoveset
.public HIDDEN_POWER_BASE_POWER_TABLE
.public HandleSir0Translation
.public HidePortraitBox
.public InitMove
.public InitPreprocessorArgs
.public IqSkillFlagTest
.public Is2TurnsMove
.public IsAdvancedMenuActive2
.public IsAdvancedTextBoxActive
.public IsCollectionMenuActive
.public IsCollectionMenuState3
.public IsDebugMenuActive
.public IsDialogueBoxActive
.public IsExclusiveItemIdForMonster
.public IsExperienceLocked
.public IsGummi
.public IsItemInTimeDarkness
.public IsItemValidVeneer
.public IsMainCharacter
.public IsMovesetValidInTimeDarkness
.public IsNot2TurnsMoveOrSketch
.public IsOptionsMenuActive
.public IsParentMenuActive
.public IsRealMove
.public IsScrollBoxActive
.public IsShoppableItem
.public IsSimpleMenuActive
.public IsStorableItem
.public IsStorageFull
.public IsTeamSelectionMenuActive
.public IsTeamSelectionMenuState3
.public IsThrownItem
.public IsTreasureBox
.public IsValidTeamMember
.public ItemZInit
.public KAOMADO_FILEPATH
.public KEYBOARD_STRING_IDS
.public LearnMoves
.public LoadFileFromRom
.public LoadOverlay
.public MISSION_FLOORS_FORBIDDEN
.public MISSION_FLOOR_RANKS_PTRS
.public MONSTER_SPRITE_DATA
.public MemAlloc
.public MemFree
.public MemZero
.public MemcpySimple
.public MemsetSimple
.public NOTIFY_NOTE
.public NormalizeTreasureBox
.public OS_GetLockID
.public OUTLAW_LEVEL_TABLE
.public OUTLAW_MINION_LEVEL_TABLE
.public OverlayIsLoaded
.public PARTNER_TALK_KIND_TABLE
.public PORTRAIT_LAYOUTS
.public PlayAdvancedTextBoxInputSound
.public PlayBgmByIdVeneer
.public PlaySeVolumeWrapper
.public PointsToZero
.public PreprocessString
.public PreprocessStringFromId
.public RANK_UP_TABLE
.public Rand16Bit
.public Rand32Bit
.public RandInt
.public RandIntSafe
.public ReadItemsFromSave
.public ReadMonsterInfoFromSave
.public ReadStringFromDialogueBox
.public RemoveActiveMembersFromAllTeams
.public RemoveActiveMembersFromRescueTeam
.public RemoveActiveMembersFromSpecialEpisodeTeam
.public RemoveEmptyItemsInBag
.public ResumeAdvancedMenu
.public SCRIPT_VARS
.public SCRIPT_VARS_LOCALS
.public SECONDARY_TERRAIN_TYPES
.public SPECIAL_EPISODE_MAIN_CHARACTERS
.public STATUSES_FULL_DESCRIPTION_STRING_IDS
.public SetActiveInventory
.public SetActiveKecleonShop
.public SetActiveTeam
.public SetAdvancedTextBoxField0x1C2
.public SetAdvancedTextBoxPartialMenu
.public SetAdvancedTextBoxState5
.public SetBothScreensWindowsColor
.public SetCollectionMenuField0x1BC
.public SetCollectionMenuVoidFn
.public SetCollectionMenuWidth
.public SetMoneyCarried
.public SetMoneyStored
.public SetRngSeed
.public SetSimpleMenuField0x1AC
.public SetTeamSetupHeroAndPartnerOnly
.public SetUnkAdvancedTextBoxFn
.public SetUnkAdvancedTextBoxWindowFn
.public ShowDialogueBox
.public ShowPortraitInPortraitBox
.public ShowStringIdInDialogueBox
.public ShowStringInDialogueBox
.public SortItemsInBag
.public SortItemsInStorage
.public StrcpyName
.public StrcpySimple
.public StringFromId
.public StrncmpSimple
.public StrncpyName
.public StrncpySimple
.public StrncpySimpleNoPad
.public StrncpySimpleNoPadSafe
.public TEAM_MEMBER_TABLE_PTR
.public TryPointCameraToMonster
.public UNOWN_SPECIES_ADDITIONAL_CHAR_PTR_TABLE
.public UnloadFile
.public UpdateWindow
.public VERSION_EXCLUSIVE_MONSTERS
.public WONDER_MAIL_BITS_MAP
.public WONDER_MAIL_BITS_SWAP
.public WONDER_MAIL_ENCRYPTION_TABLE
.public WriteItemsToSave
.public WriteMonsterInfoToSave
.public ZInit8
.public _0209B08C
.public _0209B09C
.public _0209B0EC
.public _0209B0FC
.public _0209B10C
.public _0209B11C
.public _0209B134
.public _0209B1B8
.public _0209B1C8
.public _0209B1D8
.public _0209B1F0
.public _0209B208
.public _0209B218
.public _0209B228
.public _0209B244
.public _0209B254
.public _0209B264
.public _0209B288
.public _0209B28C
.public _0209B298
.public _0209B2B8
.public _0209B2C4
.public _0209B2D0
.public _0209B2DC
.public _0209B2E0
.public _0209B2E1
.public _0209B2E2
.public _0209B2E3
.public _0209B2EC
.public _0209B2FC
.public _0209B30C
.public _0209B31C
.public _0209B32C
.public _0209B32E
.public _0209B3B4
.public _0209B3B6
.public _0209B48C
.public _0209B4A4
.public _0209B4AC
.public _0209B4B8
.public _0209B4C0
.public _0209B4C4
.public _0209B4D4
.public _0209B4E4
.public _0209B4FC
.public _0209B50C
.public _0209C29C_JP
.public _0209C29D_JP
.public _0209C29E_JP
.public _0209C5C0
.public _0209C5D0
.public _0209C5E0
.public _0209C604
.public _0209C60C
.public _0209C618
.public _0209C628
.public _0209C638
.public _0209C648
.public _0209C658
.public _0209C668
.public _0209C678
.public _0209C688
.public _0209C6B8
.public _0209C70C
.public _0209C764
.public _0209C798
.public _0209C7B8
.public _0209C7CC
.public _0209C7D4
.public _0209C7E4
.public _0209C7F4
.public _0209C820
.public _0209C82C
.public _0209C83C
.public _0209C844
.public _0209C846
.public _0209C850
.public _0209C85C
.public _0209C86C
.public _0209C884
.public _0209C89C
.public _0209C8A8
.public _0209C8B8
.public _0209C8C8
.public _0209C928
.public _0209C92C
.public _0209C93C
.public _0209C94C
.public _0209C95C
.public _0209C96C
.public _0209C97C
.public _0209C98C
.public _0209C99C
.public _0209C9AC
.public _0209C9B0
.public _0209C9CC
.public _0209C9D4
.public _0209C9DC
.public _0209C9E4
.public _0209C9F4
.public _0209C9FC
.public _0209CA08
.public _0209CA18
.public _0209CA2C
.public _0209CA3C
.public _0209CA48
.public _0209CA58
.public _0209CA68
.public _0209CA78
.public _0209CA88
.public _0209CA98
.public _0209CAB4
.public _0209CB0C
.public _0209CB3C
.public _0209CB4C
.public _0209CB6C
.public _0209CB78
.public _0209CB88
.public _0209CB98
.public _0209CBA8
.public _0209CBB0
.public _0209CBB8
.public _0209CBC0
.public _0209CBC8
.public _0209CBD0
.public _0209CBD8
.public _0209CBE0
.public _0209CBE8
.public _0209CC0C
.public _0209CC18
.public _0209CC28
.public _0209CC38
.public _0209CC48
.public _0209CC60
.public _0209CC80
.public _0209CC90
.public _0209CCA0
.public _0209CCB0
.public _0209CCC0
.public _0209CCD0
.public _0209CCE0
.public _0209CD4C
.public _0209CD6C
.public _0209CD84
.public _0209CD94
.public _0209CDA4
.public _0209CDB8
.public _0209CDD0
.public _0209CDE0
.public _0209CDF8
.public _0209CE10
.public _0209CE40
.public _0209CE50
.public _0209CE54
.public _0209CE58
.public _0209CE68
.public _0209CE78
.public _0209CE88
.public _0209CE89
.public _0209CEAC
.public _0209CF0C
.public _0209CF28
.public _0209CF48
.public _0209CF64
.public _0209CF84
.public _0209DF70
.public _0209DFA0
.public _0209DFC8
.public _0209DFE8
.public _0209E008
.public _0209E010
.public _0209E011
.public _0209E264
.public _0209E3A1
.public _0209E3A2
.public _0209E3A3
.public _0209E6BD
.public _0209E912
.public _020A0C68
.public _020A0C69
.public _020A0C6A
.public _020A0C6C
.public _020A0C6E
.public _020A1864
.public _020A1880
.public _020A1884
.public _020A189C
.public _020A18C0
.public _020A192C
.public _020A20B1
.public _020A2808
.public _020A281C
.public _020A2830
.public _020A2844
.public _020A2858
.public _020A286C
.public _020A2880
.public _020A2894
.public _020A28A8
.public _020A28E0
.public _020A2904
.public _020A2928
.public _020A294C
.public _020A2970
.public _020A2994
.public _020A29B8
.public _020A29DC
.public _020A2A00
.public _020A2A24
.public _020A2A48
.public _020A2A6C
.public _020A2A90
.public _020A2AB4
.public _020A2AD8
.public _020A2AFC
.public _020A2B20
.public _020A2D09
.public _020A31B8
.public _020A31D4
.public _020A31E4
.public _020A31F4
.public _020A31FC
.public _020A3200
.public _020A3210
.public _020A322C
.public _020A3248
.public _020A3258
.public _020A327C
.public _020A328C
.public _020A32D4
.public _020A32F8
.public _020A3330
.public _020A45C8_JP
.public _020AFDB8
.public _020AFDBC
.public _020AFDD0
.public _020AFDD8
.public _020AFDE0
.public _020AFDE8
.public _020AFDF0
.public _020AFE40
.public _020AFE58
.public _020AFE5C
.public _020AFE70
.public _020AFE74
.public _020AFE78
.public _020AFE7C
.public _020AFE8C
.public _020AFE90
.public _020AFE98
.public _020AFEA8
.public _020AFEB4
.public _020AFEC8
.public _020AFECC
.public _020AFED0
.public _020AFED4
.public _020AFED8
.public _020AFEDC
.public _020AFEE0
.public _020AFEE4
.public _020AFEE8
.public _020AFEEC
.public _020AFEF4
.public _020AFF00
.public _020AFF14
.public _020AFF38
.public _020AFF40
.public _020AFF4C
.public _020AFF54
.public _020AFF5C
.public _020AFF64
.public _020AFF68
.public _020AFF6C
.public _020AFF7C
.public _020AFF80
.public _020AFF88
.public _020B09B0
.public _020B09B4
.public _020B09C0
.public _020B09C8
.public _020B09D0
.public _020B12A0_JP
.public _020B12F4_EU
.public _020B1308_EU
.public _022AADF8
.public _022AADFC
.public _022AAE00
.public _022AAE2A
.public _022AAE2E
.public _022AAE4C
.public _022AAE58
.public _022AAE64
.public _022AAE68
.public _022AAE70
.public _022AAE74
.public _022AAE78
.public _022AAEA4
.public _022AAEA8
.public _022AAEAC
.public _022AB09C
.public _022AB0A0
.public _022AB0A1
.public _022AB0A2
.public _022AB0A9
.public _022AB0AC
.public _022AB4AC
.public _022AB4B0
.public _022AB4F8
.public _022AB4FC
.public _022AB510
.public _022AB518
.public _022AB5A8
.public _022AB5AC
.public _022AB694
.public _022AB69C
.public _022AB918
.public _022AB924
.public _022AB92C
.public _022AB930
.public _022ABDE0
.public _f2d
.public _fsub
.public _s32_div_f
.public memcpy
.public ov11_022E6E68
.public ov11_023061CC
.public ov11_023061E4
.public ov11_02306C64
.public ov11_02306C9C
.public ov11_0230D000
.public ov11_0230D220
.public ov11_0230D71C
.public ov11_0230D92C
.public ov11_02310BDC
.public ov11_02310C18
.public ov29_022E2A78
.public ov29_022EA62C
.public ov29_023002F0
.public ov29_02347100
.public sprintf
.public strcat
.public strcpy
.public strlen
.public strncmp
.public strncpy
.public sub_01FF8F28
.public sub_02001808
.public sub_02002580
.public sub_020027F8
.public sub_0200302C
.public sub_020030FC
.public sub_02003B94
.public sub_02003BC8
.public sub_02004F80
.public sub_020063F4
.public sub_02006498
.public sub_02006BFC
.public sub_02006C8C
.public sub_0200A124
.public sub_0200A158
.public sub_0200A184
.public sub_0200A478
.public sub_0200A4C4
.public sub_0200A504
.public sub_0200A510
.public sub_0200A590
.public sub_0200B2C4
.public sub_0200B314
.public sub_0200B330
.public sub_0200B340
.public sub_0200B3C0
.public sub_0200B3D4
.public sub_0200B3FC
.public sub_0200C4CC
.public sub_0200C5DC
.public sub_0200CABC
.public sub_0200CAD4
.public sub_0200CAE4
.public sub_0200D310
.public sub_0200D65C
.public sub_0200D670
.public sub_0200FD48
.public sub_02010044
.public sub_02010060
.public sub_02010154
.public sub_0201077C
.public sub_02010794
.public sub_020107F4
.public sub_02012AB8
.public sub_02013190
.public sub_020131F0
.public sub_02013E54
.public sub_02013F58
.public sub_02015090
.public sub_02017C50
.public sub_02017C74
.public sub_02017C80
.public sub_0202059C
.public sub_020205C0
.public sub_0202065C
.public sub_020236FC
.public sub_0202372C
.public sub_02024B94
.public sub_02024D7C
.public sub_020251F0
.public sub_02025304_JP
.public sub_02025888
.public sub_02025C7C
.public sub_02025D50
.public sub_02025E84
.public sub_0202613C
.public sub_020261D4
.public sub_02026204
.public sub_02026268
.public sub_020262E0
.public sub_020264A4
.public sub_020264F8
.public sub_020265A8
.public sub_02027180
.public sub_02027B1C
.public sub_0202810C
.public sub_0202812C
.public sub_020282F4
.public sub_02028324
.public sub_02028354
.public sub_0202836C
.public sub_020288DC
.public sub_020288FC
.public sub_02029F88
.public sub_02029FBC
.public sub_0202A2A4
.public sub_0202AAE8
.public sub_0202AB80
.public sub_0202ABB0
.public sub_0202C1E4
.public sub_0202C620
.public sub_0202C654
.public sub_0202C6D4
.public sub_0202C748
.public sub_0202C75C
.public sub_0202D068
.public sub_0202D0EC
.public sub_0202D134
.public sub_0202D16C
.public sub_0202D59C
.public sub_0202D5B0
.public sub_0202D5E4
.public sub_0202DF64
.public sub_0202F16C
.public sub_0202F190
.public sub_0202F2C4
.public sub_0202F334
.public sub_0202F3F8
.public sub_0202F954
.public sub_0202F9B8
.public sub_020307EC
.public sub_020308E4
.public sub_02030908
.public sub_02030940
.public sub_02030978
.public sub_020309B8
.public sub_02030A18
.public sub_02030A50
.public sub_02030A64
.public sub_02030A74
.public sub_02030A90
.public sub_02030AAC
.public sub_02030EF0
.public sub_0203111C
.public sub_0203115C
.public sub_0203117C
.public sub_020311D4
.public sub_020311E8
.public sub_02031220
.public sub_02031888
.public sub_0203189C
.public sub_020318D0
.public sub_02031914
.public sub_020347A0
.public sub_020347F0
.public sub_02034840
.public sub_020348E4
.public sub_02054F18
.public sub_02054FB8
.public sub_02054FEC
.public sub_02055020
.public sub_020550DC
.public sub_020550E0
.public sub_02055118
.public sub_02055B78
.public sub_02055D4C
.public sub_020560B8
.public sub_02056228
.public sub_0205633C
.public sub_02056360
.public sub_02056410
.public sub_02056460
.public sub_020564B0
.public sub_02056504
.public sub_020568A4
.public sub_02056B58
.public sub_02056BD4
.public sub_02056F60
.public sub_02058460
.public sub_020584F8
.public sub_020584FC
.public sub_020597B0
.public sub_02059A74
.public sub_02059B08
.public sub_0205A4B4
.public sub_0205B028
.public sub_0205B0A0
.public sub_0205B0B8
.public sub_0205B478
.public sub_0205B77C
.public sub_0205BB7C
.public sub_0205BD14
.public sub_0205BD9C
.public sub_0205BFB0
.public sub_0205C2A4
.public sub_0205C548
.public sub_0205C75C
.public sub_0205EE40
.public sub_0205F00C
.public sub_0205FAB0
.public sub_0205FC20
.public sub_0205FD88
.public sub_0205FE80
.public sub_02062B64
.public sub_0206637C
.public sub_02079094
.public sub_0207B9EC
.public sub_0208346C
.public sub_0208347C
.public sub_02083A18
.public sub_02083B00
.public sub_02083B14
.public sub_02083B3C
.public sub_02084304
.public vsprintf

View File

@ -1,5 +1,4 @@
#pragma once
.public _020A1870
.public AddDungeonSubMenuOption
.public AdvanceFrame
.public AiMovement
@ -11,7 +10,6 @@
.public BaseFormsEqual
.public CanAiUseMove
.public CanMonsterSpawn
.public CeilFixedPoint
.public CheckTeamMemberIdxVeneer
.public CheckVariousConditions
.public CheckVariousStatuses2
@ -33,19 +31,48 @@
.public CreateScrollBoxSingle
.public CreateTextBox
.public CreateTextBoxWithArg
.public DUNGEON_PTR
.public DUNGEON_SUBMENU_ITEMS_1
.public DUNGEON_SUBMENU_ITEMS_5
.public DUNGEON_SUBMENU_ITEMS_6
.public DUNGEON_WINDOW_PARAMS_10
.public DUNGEON_WINDOW_PARAMS_11
.public DUNGEON_WINDOW_PARAMS_12
.public DUNGEON_WINDOW_PARAMS_13
.public DUNGEON_WINDOW_PARAMS_14
.public DUNGEON_WINDOW_PARAMS_15
.public DUNGEON_WINDOW_PARAMS_16
.public DUNGEON_WINDOW_PARAMS_17
.public DUNGEON_WINDOW_PARAMS_18
.public DUNGEON_WINDOW_PARAMS_19
.public DUNGEON_WINDOW_PARAMS_20
.public DUNGEON_WINDOW_PARAMS_21
.public DUNGEON_WINDOW_PARAMS_22
.public DUNGEON_WINDOW_PARAMS_23
.public DUNGEON_WINDOW_PARAMS_24
.public DUNGEON_WINDOW_PARAMS_25
.public DUNGEON_WINDOW_PARAMS_26
.public DUNGEON_WINDOW_PARAMS_27
.public DUNGEON_WINDOW_PARAMS_28
.public DUNGEON_WINDOW_PARAMS_29
.public DUNGEON_WINDOW_PARAMS_30
.public DUNGEON_WINDOW_PARAMS_31
.public DUNGEON_WINDOW_PARAMS_32
.public DUNGEON_WINDOW_PARAMS_5
.public DUNGEON_WINDOW_PARAMS_6
.public DUNGEON_WINDOW_PARAMS_7
.public DUNGEON_WINDOW_PARAMS_8
.public DUNGEON_WINDOW_PARAMS_9
.public Debug_Print0
.public DisableDungeonSubMenuOption
.public DisplayMessage
.public DrawTextInWindow
.public DrawTileGrid
.public DUNGEON_PTR
.public FormatMoveString
.public FormatMoveStringMore
.public GetActiveTeamMember
.public GetApparentWeather
.public GetCurrentBagCapacity
.public GetDexNumber
.public GetFloorType
.public GetItemAction
.public GetItemCategoryVeneer
.public GetItemInfo
@ -57,7 +84,6 @@
.public GetLeaderChangeFlag
.public GetLeaderMonster
.public GetMaxPp
.public GetMoneyCarried
.public GetMonsterIdFromSpawnEntry
.public GetMonsterName
.public GetNbItemsInBag
@ -70,7 +96,6 @@
.public GetTile
.public GetTrapInfo
.public GetUnlockedTactics
.public GetWindow
.public GetWindowRectangle
.public HideTileGrid
.public InitPreprocessorArgs
@ -91,12 +116,48 @@
.public JoinedAtRangeCheck2Veneer
.public LogMessageByIdWithPopupCheckUser
.public MemAlloc
.public memcpy
.public MemFree
.public memset
.public MemZero
.public MonsterCanThrowItems
.public MonsterHasEmbargoStatus
.public OVERLAY31_JP_STRING
.public OVERLAY31_UNKNOWN_POINTER__NA_238A268
.public OVERLAY31_UNKNOWN_POINTER__NA_238A26C
.public OVERLAY31_UNKNOWN_POINTER__NA_238A270
.public OVERLAY31_UNKNOWN_POINTER__NA_238A27C
.public OVERLAY31_UNKNOWN_POINTER__NA_238A280
.public OVERLAY31_UNKNOWN_POINTER__NA_238A284
.public OVERLAY31_UNKNOWN_POINTER__NA_238A288
.public OVERLAY31_UNKNOWN_POINTER__NA_238A28C
.public OVERLAY31_UNKNOWN_STRING_IDS
.public OVERLAY31_UNKNOWN_STRUCT__NA_2389EF0
.public OVERLAY31_UNKNOWN_STRUCT__NA_2389FE8
.public OVERLAY31_UNKNOWN_STRUCT__NA_238A144
.public OVERLAY31_UNKNOWN_STRUCT__NA_238A190
.public PlaySeVolumeWrapper
.public PlayWindowInputSound
.public PopInventoryMenuField0x1A3
.public PositionHasItem
.public PreprocessString
.public PreprocessStringFromId
.public PrintIqSkillsMenu
.public ResumeParentMenu
.public SetAdvancedTextBoxField0x1C2
.public SetAdvancedTextBoxField0x1C4
.public SetAdvancedTextBoxState5
.public SetMonsterActionFields
.public ShowStringInDialogueBox
.public SortItemsInBag
.public SpecificRecruitCheck
.public StringFromId
.public TeamMemberHasEnabledIqSkill
.public TryPointCameraToMonster
.public UpdateMapSurveyorFlag
.public UpdateWindow
.public YesNoMenu
.public _020A1870
.public memcpy
.public memset
.public ov10_022BCC60
.public ov10_022BCC7C
.public ov10_022BCCB0
@ -107,9 +168,7 @@
.public ov10_022BCE44
.public ov10_022BD394
.public ov10_022BD474
.public ov29_02056264
.public ov29_022E08F4
.public ov29_022E0C2C
.public ov29_022E1618
.public ov29_022E1620
.public ov29_022E2A78
@ -156,39 +215,45 @@
.public ov29_0234F77C
.public ov29_0234FB50
.public ov29_0234FB60
.public ov29_0234FB6C
.public ov29_0234FBD4
.public ov29_0235352C
.public ov29_0237C91C
.public ov29_0238280C
.public OVERLAY31_UNKNOWN_STRING_IDS
.public PlaySeVolumeWrapper
.public PlayWindowInputSound
.public PopInventoryMenuField0x1A3
.public PositionHasItem
.public PositionIsOnHiddenStairs
.public PreprocessString
.public PreprocessStringFromId
.public PrintIqSkillsMenu
.public ResumeParentMenu
.public SetAdvancedTextBoxField0x1C2
.public SetAdvancedTextBoxField0x1C4
.public SetAdvancedTextBoxState5
.public SetMonsterActionFields
.public ShouldMonsterRunAwayVariation
.public ShowStringInDialogueBox
.public SortItemsInBag
.public SpecificRecruitCheck
.public ov31_02382B54
.public ov31_02382DAC
.public ov31_02382F68
.public ov31_02389E22
.public ov31_02389F5C
.public ov31_0238A044
.public ov31_0238A04C
.public ov31_0238A054
.public ov31_0238A05C
.public ov31_0238A064
.public ov31_0238A06C
.public ov31_0238A074
.public ov31_0238A07C
.public ov31_0238A084
.public ov31_0238A0A8
.public ov31_0238A0B0
.public ov31_0238A0B8
.public ov31_0238A0C0
.public ov31_0238A0C8
.public ov31_0238A0D0
.public ov31_0238A0D8
.public ov31_0238A0E0
.public ov31_0238A0E8
.public ov31_0238A154
.public ov31_0238A228
.public ov31_0238A23C
.public ov31_0238A2A0
.public ov31_0238A2A8
.public strcpy
.public StringFromId
.public sub_02001808
.public sub_0200B3D4
.public sub_0200D310
.public sub_0200D894
.public sub_02017C74
.public sub_02017C80
.public sub_02025888
.public sub_020265A8
.public sub_02027B1C
.public sub_0202810C
.public sub_0202812C
@ -216,7 +281,6 @@
.public sub_0203FD14
.public sub_0203FD38
.public sub_0203FD44
.public sub_0203FE5C
.public sub_0204018C
.public sub_0204019C
.public sub_020407C0
@ -237,14 +301,8 @@
.public sub_020420F4
.public sub_0204AEA0
.public sub_0204F10C
.public sub_0204F9E0
.public sub_02053CA0
.public sub_02054F44
.public sub_02056228
.public sub_020585B4
.public TeamMemberHasEnabledIqSkill
.public TryPointCameraToMonster
.public UpdateMapSurveyorFlag
.public UpdateWindow
.public vsprintf
.public YesNoMenu

41015
asm/main_02034974.s Normal file

File diff suppressed because it is too large Load Diff

View File

@ -1,577 +1,10 @@
.include "asm/macros.inc"
.include "overlay_31.inc"
.include "overlay_31002382FBC.inc"
.text
arm_func_start EntryOverlay31
EntryOverlay31: ; 0x02382820
stmdb sp!, {r3, lr}
ldr r0, _0238285C ; =DUNGEON_WINDOW_PARAMS_3
bl sub_020348E4
cmp r0, #0
ldmeqia sp!, {r3, pc}
mov r0, #0x10
mov r1, #8
bl MemAlloc
ldr r1, _02382860 ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
mov r2, #0
str r0, [r1]
str r2, [r0, #4]
mov r0, #0xa
str r0, [r1, #4]
ldmia sp!, {r3, pc}
.align 2, 0
_0238285C: .word DUNGEON_WINDOW_PARAMS_3
_02382860: .word OVERLAY31_UNKNOWN_POINTER__NA_238A260
arm_func_end EntryOverlay31
arm_func_start DrawDungeonMenuStatusWindow
DrawDungeonMenuStatusWindow: ; 0x02382864
#ifdef JAPAN
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_OFFSET -4
#else
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_OFFSET 0
#endif
stmdb sp!, {r4, r5, r6, r7, r8, sb, sl, fp, lr}
sub sp, sp, #0x254
mov sl, r0
bl GetLeader
ldr r4, [r0, #0xb4]
sub r2, sp, #4
add r0, r4, #0x100
ldrh r1, [r0, #0x46 + DRAW_DUNGEON_MENU_STATUS_WINDOW_OFFSET]
strh r1, [r2]
ldrh r0, [r0, #0x48 + DRAW_DUNGEON_MENU_STATUS_WINDOW_OFFSET]
strh r0, [r2, #2]
ldr r0, [r2]
bl CeilFixedPoint
str r0, [sp, #0x228]
add r0, r4, #0x100
ldrh r1, [r0, #0x4a + DRAW_DUNGEON_MENU_STATUS_WINDOW_OFFSET]
sub r2, sp, #4
strh r1, [r2]
ldrh r0, [r0, #0x4c + DRAW_DUNGEON_MENU_STATUS_WINDOW_OFFSET]
strh r0, [r2, #2]
ldr r0, [r2]
bl CeilFixedPoint
str r0, [sp, #0x22c]
ldr r0, _02382AA0 ; =0x000008B2
bl StringFromId
add r1, sp, #0x204
mov r2, r0
str r1, [sp]
add r0, sp, #0x104
mov r1, #0x100
mov r3, #0
bl PreprocessString
mov r0, sl
mov r1, #0x73
mov r2, #0
add r3, sp, #0x104
bl DrawTextInWindow
bl GetMoneyCarried
str r0, [sp, #0x228]
ldr r0, _02382AA4 ; =0x000008B5
bl StringFromId
add r1, sp, #0x204
mov r2, r0
str r1, [sp]
add r0, sp, #0x104
mov r1, #0x100
mov r3, #0
bl PreprocessString
mov r0, sl
mov r1, #0x73
mov r2, #0xc
add r3, sp, #0x104
bl DrawTextInWindow
mov r0, #0
bl GetApparentWeather
str r0, [sp, #0x204]
ldr r0, _02382AA8 ; =0x000008B6
bl StringFromId
add r1, sp, #0x204
mov r2, r0
str r1, [sp]
add r0, sp, #0x104
mov r1, #0x100
mov r3, #0
bl PreprocessString
add r3, sp, #0x104
mov r0, sl
mov r1, #0x73
mov r2, #0x18
bl DrawTextInWindow
bl sub_0204F9E0
str r0, [sp, #0x228]
ldr r0, _02382AAC ; =0x000008B7
bl StringFromId
add r1, sp, #0x204
mov r2, r0
str r1, [sp]
ldr r3, _02382AB0 ; =0x0000C402
add r0, sp, #0x104
mov r1, #0x100
bl PreprocessString
mov r0, sl
mov r1, #0x73
mov r2, #0x24
add r3, sp, #0x104
bl DrawTextInWindow
mov r7, #0
mov r8, r7
add r6, sp, #4
ldr r5, _02382AB4 ; =0x000003E7
add r4, sp, #0x204
ldr fp, _02382AB8 ; =DUNGEON_PTR
b _02382A88
_023829D8:
ldr r0, [fp]
add r0, r0, r8, lsl #2
add r0, r0, #0x12000
#ifdef JAPAN
ldr r1, [r0, #0xa84]
#else
ldr r1, [r0, #0xb28]
#endif
cmp r1, #0
moveq r0, #0
beq _02382A08
ldr r0, [r1]
cmp r0, #0
movne r0, #1
moveq r0, #0
and r0, r0, #0xff
_02382A08:
cmp r0, #0
beq _02382A84
ldr sb, [r1, #0xb4]
mov r0, r6
mov r2, #0
bl ov29_022E2A78
str r6, [sp, #0x23c]
ldrsh r0, [sb, #0x10]
str r0, [sp, #0x228]
ldrsh r1, [sb, #0x12]
ldrsh r0, [sb, #0x16]
add r0, r1, r0
cmp r0, r5
movgt r0, r5
str r0, [sp, #0x22c]
ldr r0, _02382ABC ; =0x000008B8
bl StringFromId
mov r2, r0
add r0, sp, #0x104
mov r1, #0x100
mov r3, #0
str r4, [sp]
bl PreprocessString
mov r0, sl
mov r1, #4
mov r2, r7
add r3, sp, #0x104
bl DrawTextInWindow
add r7, r7, #0xc
cmp r7, #0x30
bge _02382A90
_02382A84:
add r8, r8, #1
_02382A88:
cmp r8, #4
blt _023829D8
_02382A90:
mov r0, sl
bl UpdateWindow
add sp, sp, #0x254
ldmia sp!, {r4, r5, r6, r7, r8, sb, sl, fp, pc}
.align 2, 0
#ifdef JAPAN
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET 0x1458
#else
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET 0
#endif
_02382AA0: .word 0x000008B2 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET
_02382AA4: .word 0x000008B5 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET
_02382AA8: .word 0x000008B6 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET
_02382AAC: .word 0x000008B7 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET
_02382AB0: .word 0x0000C402
_02382AB4: .word 0x000003E7
_02382AB8: .word DUNGEON_PTR
_02382ABC: .word 0x000008B8 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET
arm_func_end DrawDungeonMenuStatusWindow
arm_func_start DungeonMenuSwitch
DungeonMenuSwitch: ; 0x02382AC0
stmdb sp!, {r3, r4, r5, r6, lr}
sub sp, sp, #0x54
ldr r1, _02382B4C ; =DUNGEON_PTR
mov r4, r0
ldr r1, [r1]
ldrb r0, [r1, #0x748]
orr r0, r0, #0x40000
str r0, [sp, #0x14]
ldrb r0, [r1, #0x749]
str r0, [sp, #0x28]
bl sub_02025888
add r5, sp, #4
ldr r2, _02382B50 ; =ov31_02389E14
mov r1, #0x400
mov r3, #0
mov r6, r0
str r5, [sp]
bl PreprocessString
mov r0, r4
bl GetWindow
mov r5, r0
mov r0, r6
bl sub_020265A8
ldrb r1, [r5, #6]
mov r3, r6
mov r2, #2
rsb r0, r0, r1, lsl #3
add r0, r0, r0, lsr #31
mov r1, r0, asr #1
mov r0, r4
bl DrawTextInWindow
mov r0, r4
bl UpdateWindow
add sp, sp, #0x54
ldmia sp!, {r3, r4, r5, r6, pc}
.align 2, 0
_02382B4C: .word DUNGEON_PTR
_02382B50: .word ov31_02389E14
arm_func_end DungeonMenuSwitch
arm_func_start ov31_02382B54
ov31_02382B54: ; 0x02382B54
stmdb sp!, {lr}
sub sp, sp, #0x9c
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r2, [r0]
ldr r1, [r2, #4]
cmp r1, #3
addls pc, pc, r1, lsl #2
b _02382D80
_02382B74: ; jump table
b _02382B84 ; case 0
b _02382B90 ; case 1
b _02382C6C ; case 2
b _02382D58 ; case 3
_02382B84:
add r0, r1, #1
str r0, [r2, #4]
b _02382D80
_02382B90:
mov r3, #0
mov r2, r3
_02382B98:
ldr r1, [r0]
add r1, r1, r3
add r3, r3, #1
strb r2, [r1, #8]
cmp r3, #7
blt _02382B98
bl GetLeader
mov r1, #1
bl ShouldMonsterRunAwayVariation
cmp r0, #0
beq _02382BEC
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
mov r2, #3
ldr r1, [r0]
strb r2, [r1, #8]
ldr r1, [r0]
strb r2, [r1, #9]
ldr r1, [r0]
strb r2, [r1, #0xa]
ldr r0, [r0]
strb r2, [r0, #0xc]
_02382BEC:
ldr r1, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
mov r0, #5
ldr r1, [r1]
add r1, r1, #8
str r1, [sp, #0x64]
bl Arm9LoadUnkFieldNa0x2029EC8
str r0, [sp, #4]
ldr r0, _02382D90 ; =DUNGEON_WINDOW_PARAMS_1
ldr r1, _02382D94 ; =0x00000233
ldr r3, _02382D98 ; =DUNGEON_MAIN_MENU_ITEMS
add r2, sp, #4
bl CreateParentMenuFromStringIds
ldr r2, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r1, _02382D9C ; =DrawDungeonMenuStatusWindow
ldr r2, [r2]
strb r0, [r2]
ldr r0, _02382DA0 ; =DUNGEON_WINDOW_PARAMS_4
bl CreateTextBox
ldr r2, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r1, _02382DA4 ; =DungeonMenuSwitch
ldr r2, [r2]
strb r0, [r2, #2]
ldr r0, _02382DA8 ; =DUNGEON_WINDOW_PARAMS_2
bl CreateTextBox
ldr r1, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r2, [r1]
strb r0, [r2, #1]
ldr r1, [r1]
ldr r0, [r1, #4]
add r0, r0, #1
str r0, [r1, #4]
b _02382D80
_02382C6C:
ldrsb r0, [r2]
bl IsParentMenuActive
cmp r0, #0
beq _02382D20
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
ldrsb r0, [r0]
bl sub_0202AB80
and r1, r0, #0xff
mov r0, #5
bl Arm9StoreUnkFieldNa0x2029ED8
add r1, sp, #0
mov r0, #0
bl GetPressedButtons
ldrh r0, [sp]
tst r0, #0x400
beq _02382D80
bl GetLeader
mov r1, #1
bl ShouldMonsterRunAwayVariation
cmp r0, #0
bne _02382D80
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
mov r1, #0
ldr r0, [r0]
ldrsb r0, [r0]
bl sub_0202AB94
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
ldrsb r0, [r0]
bl sub_0202B030
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
ldrsb r0, [r0, #1]
bl sub_0202F954
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
ldrsb r0, [r0, #2]
bl sub_0202F954
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r1, [r0]
ldr r0, [r1, #4]
add r0, r0, #1
str r0, [r1, #4]
b _02382D80
_02382D20:
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
ldrsb r0, [r0, #1]
bl sub_0202F954
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
ldrsb r0, [r0, #2]
bl sub_0202F954
ldr r0, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r1, [r0]
ldr r0, [r1, #4]
add r0, r0, #1
str r0, [r1, #4]
b _02382D80
_02382D58:
ldrsb r0, [r2]
bl sub_0202ABB0
ldr r1, _02382D8C ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
str r0, [r1, #4]
ldr r2, [r1]
mov r0, #4
ldr r1, [r2, #4]
add r1, r1, #1
str r1, [r2, #4]
b _02382D84
_02382D80:
mov r0, #1
_02382D84:
add sp, sp, #0x9c
ldmia sp!, {pc}
.align 2, 0
_02382D8C: .word OVERLAY31_UNKNOWN_POINTER__NA_238A260
_02382D90: .word DUNGEON_WINDOW_PARAMS_1
_02382D94: .word 0x00000233
_02382D98: .word DUNGEON_MAIN_MENU_ITEMS
_02382D9C: .word DrawDungeonMenuStatusWindow
_02382DA0: .word DUNGEON_WINDOW_PARAMS_4
_02382DA4: .word DungeonMenuSwitch
_02382DA8: .word DUNGEON_WINDOW_PARAMS_2
arm_func_end ov31_02382B54
arm_func_start ov31_02382DAC
ov31_02382DAC: ; 0x02382DAC
stmdb sp!, {r3, lr}
ldr r0, _02382E04 ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
cmp r0, #0
ldmeqia sp!, {r3, pc}
ldrsb r0, [r0, #1]
bl CloseTextBox
ldr r0, _02382E04 ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
ldrsb r0, [r0, #2]
bl CloseTextBox
ldr r0, _02382E04 ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
ldrsb r0, [r0]
bl CloseParentMenu
ldr r0, _02382E04 ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0]
bl MemFree
ldr r0, _02382E04 ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
mov r1, #0
str r1, [r0]
ldmia sp!, {r3, pc}
.align 2, 0
_02382E04: .word OVERLAY31_UNKNOWN_POINTER__NA_238A260
arm_func_end ov31_02382DAC
arm_func_start ov31_02382E08
ov31_02382E08: ; 0x02382E08
ldr r0, _02382E14 ; =OVERLAY31_UNKNOWN_POINTER__NA_238A260
ldr r0, [r0, #4]
bx lr
.align 2, 0
_02382E14: .word OVERLAY31_UNKNOWN_POINTER__NA_238A260
arm_func_end ov31_02382E08
arm_func_start ov31_02382E18
ov31_02382E18: ; 0x02382E18
stmdb sp!, {r4, r5, r6, r7, r8, lr}
mov r4, r0
mov r8, r1
mov r0, #6
mov r1, #0
bl ov29_022EA428
mov r0, #0x62
bl AdvanceFrame
mov r0, #0x62
bl AdvanceFrame
mov r0, r4
bl CreateStairsMenuState
mov r5, #0
mov r6, #1
mov r7, #0x62
ldr r4, _02382ED0 ; =ov31_0238A2A0
b _02382E64
_02382E5C:
mov r0, r7
bl AdvanceFrame
_02382E64:
ldr r0, [r4, #4]
cmp r0, #0
movne r0, r6
moveq r0, r5
tst r0, #0xff
bne _02382E5C
mov r0, #0x62
bl AdvanceFrame
bl ov29_022F0B9C
cmp r0, #0
beq _02382EA0
mov r0, #0xb
mov r1, #0
bl ov29_022EA428
b _02382EC4
_02382EA0:
cmp r8, #0
beq _02382EB8
mov r0, #0xb
mov r1, #0
bl ov29_022EA428
b _02382EC4
_02382EB8:
mov r0, #0
mov r1, r0
bl ov29_022EA428
_02382EC4:
mov r0, #1
bl ov29_022E0C2C
ldmia sp!, {r4, r5, r6, r7, r8, pc}
.align 2, 0
_02382ED0: .word ov31_0238A2A0
arm_func_end ov31_02382E18
arm_func_start CreateStairsMenuState
CreateStairsMenuState: ; 0x02382ED4
stmdb sp!, {r3, r4, r5, lr}
mov r5, r0
ldr r0, _02382F60 ; =OVERLAY31_UNKNOWN_STRUCT__NA_2389E30
bl sub_020348E4
cmp r0, #0
ldmeqia sp!, {r3, r4, r5, pc}
mov r0, #0x18
mov r1, #8
bl MemAlloc
ldr r1, _02382F64 ; =ov31_0238A2A0
mov r2, #0
str r0, [r1, #4]
str r2, [r0, #4]
ldr r0, [r1, #4]
str r5, [r0, #8]
ldr r0, [r1, #4]
str r2, [r0, #0xc]
ldr r0, [r1, #4]
str r2, [r0, #0x10]
bl GetFloorType
mov r4, #0
cmp r0, #2
moveq r4, #2
beq _02382F50
cmp r0, #1
moveq r4, #1
beq _02382F50
add r0, r5, #4
bl PositionIsOnHiddenStairs
cmp r0, #0
movne r4, #3
_02382F50:
ldr r0, _02382F64 ; =ov31_0238A2A0
ldr r0, [r0, #4]
str r4, [r0, #0x14]
ldmia sp!, {r3, r4, r5, pc}
.align 2, 0
_02382F60: .word OVERLAY31_UNKNOWN_STRUCT__NA_2389E30
_02382F64: .word ov31_0238A2A0
arm_func_end CreateStairsMenuState
arm_func_start StairsSubheadingCallback
StairsSubheadingCallback: ; 0x02382F68
stmdb sp!, {r4, lr}
ldr r1, _02382FB4 ; =ov31_0238A2A0
ldr r2, _02382FB8 ; =ov31_02389E22
ldr r1, [r1, #4]
mov r4, r0
ldr r0, [r1, #0x14]
mov r0, r0, lsl #2
ldrh r0, [r2, r0]
bl StringFromId
mov r3, r0
ldr ip, _02382FB4 ; =ov31_0238A2A0
mov r0, r4
mov r1, #0x10
mov r2, #0x12
str r3, [ip]
bl DrawTextInWindow
mov r0, r4
bl UpdateWindow
ldmia sp!, {r4, pc}
.align 2, 0
_02382FB4: .word ov31_0238A2A0
_02382FB8: .word ov31_02389E22
arm_func_end StairsSubheadingCallback
arm_func_start HandleStairsMenu
HandleStairsMenu: ; 0x02382FBC
arm_func_start ov31_02382FBC
ov31_02382FBC: ; 0x02382FBC
stmdb sp!, {r4, lr}
sub sp, sp, #0x138
ldr r0, _02383218 ; =ov31_0238A2A0
@ -9490,8 +8923,8 @@ DUNGEON_MAIN_MENU_ITEMS:
.byte 0x05, 0x00, 0x00, 0x00
.word 0x8B4 + OV31_DATA_OFFSET
.byte 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF
.global ov31_02389E14
ov31_02389E14:
.global DUNGEON_MENU_SWITCH_STR1
DUNGEON_MENU_SWITCH_STR1:
.byte 0x5B, 0x64, 0x75, 0x6E, 0x67, 0x65, 0x6F, 0x6E, 0x3A, 0x30, 0x5D, 0x00
.global OVERLAY31_UNKNOWN_STRING_IDS
OVERLAY31_UNKNOWN_STRING_IDS:

View File

@ -118,7 +118,7 @@ XMAP := $(NEF).xMAP
EXCCFLAGS := -Cpp_exceptions off
MWCFLAGS = $(DEFINES) -enum int -lang c99 $(EXCCFLAGS) -gccext,on -proc $(PROC) -msgstyle gcc -gccinc -i ./include -i ./include/library -i $(WORK_DIR)/files -I$(WORK_DIR)/lib/include -interworking -inline on,noauto -char signed -W all -W pedantic -W noimpl_signedunsigned -W noimplicitconv -W nounusedarg -W nomissingreturn -W error
MWCFLAGS = $(DEFINES) -enum min -lang c99 $(EXCCFLAGS) -gccext,on -proc $(PROC) -msgstyle gcc -gccinc -i ./include -i ./include/library -i $(WORK_DIR)/files -I$(WORK_DIR)/lib/include -interworking -inline on,noauto -char signed -W all -W pedantic -W noimpl_signedunsigned -W noimplicitconv -W nounusedarg -W nomissingreturn -W error
MWASFLAGS = $(DEFINES) -proc $(PROC_S) -gccinc -i . -i ./include -i $(WORK_DIR)/asm/include -i $(WORK_DIR)/files -i $(WORK_DIR)/lib/asm/include -i $(WORK_DIR)/lib/syscall/asm/include -I$(WORK_DIR)/lib/include -DSDK_ASM
MWLDFLAGS := -proc $(PROC) -nopic -nopid -interworking -map closure,unused -symtab sort -m _start -msgstyle gcc

1743
include/dungeon.h Normal file

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,39 @@
#ifndef HEADERS_TYPES_DUNGEON_MODE_COMMON_H_
#define HEADERS_TYPES_DUNGEON_MODE_COMMON_H_
#include "enums.h"
// Monster move info
struct move {
// 0x0: flags0: 1-byte bitfield
u8 flags0;
/* bool f_exists : 1; // This move will show up in the move list */
/* bool f_subsequent_in_link_chain : 1; // This move is in a link chain, but not the first move */
/* bool f_enabled_for_ai : 1; // AI can use this move */
/* bool f_set : 1; // Usable by L+A */
/* bool f_last_used : 1; // This move was the last one used (for things like Torment?) */
/* bool f_disabled : 1; // For Torment (and maybe others) */
/* u8 flags0_unk6 : 2; */
u8 field_0x1;
// 0x2: flags2: 2-byte bitfield
u16 flags2;
/* bool f_sealed : 1; // Sealed by a Seal Trap. Also prevents AI from using this move */
/* u16 flags2_unk1 : 2; */
/* bool f_consume_pp : 1; // This move will consume PP this turn */
/* bool f_consume_2_pp : 1; // Consume 2 PP this turn. No effect unless f_consume_pp is set */
/* u16 flags2_unk5 : 1; */
/* // Consume 4 PP this turn. No effect unless f_consume_pp is set, overrides f_consume_2_pp */
/* bool f_consume_4_pp : 1; */
/* u16 flags2_unk7 : 1; */
/* u16 flags2_unk8 : 1; */
/* bool f_exclusive_item_pp_boost : 1; // A PP-boosting exclusive item is in effect */
/* u16 flags3_unk10 : 6; */
enum move_id id : 16; // 0x4
u8 pp; // 0x6: Current PP
u8 ginseng; // 0x7: Ginseng boost
};
#endif

4124
include/enums.h Normal file

File diff suppressed because it is too large Load Diff

23
include/main_020348E4.h Normal file
View File

@ -0,0 +1,23 @@
#ifndef PMDSKY_MAIN_020348E4_H
#define PMDSKY_MAIN_020348E4_H
struct struct_1 {
s8 f[4]; // 0x0
u32 a; // 0x4
u8 b[7]; // 0x8
};
struct struct_02AFDB8 {
u8 PAD1[16];
u8 a; // 0x10
u8 PAD2[3];
struct struct_1 c; // 0x14
u32 e; // 0x24
u8 PAD3[152];
u8 d; // 0xc4
struct struct_1 b; // 0xc4
};
u32 sub_020348E4(struct struct_1* dst);
#endif //PMDSKY_MAIN_020348E4_H

View File

@ -0,0 +1,93 @@
#ifndef PMDSKY_OVERLAY_3102382820_H
#define PMDSKY_OVERLAY_3102382820_H
#include "main_020348E4.h"
#include "util.h"
#include "preprocessString.h"
#include "dungeon_mode.h"
#include "dungeon.h"
struct Window {
u8 PAD[6];
u8 width; // 0x6: Window width in multiples of 8 pixels
};
void EntryOverlay31(void);
#ifdef JAPAN
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET 0x1458
#else
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET 0
#endif
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_1 (0x000008B2 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET)
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_2 (0x000008B5 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET)
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_3 (0x000008B6 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET)
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_4 (0x000008B7 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET)
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_5 (0x000008B8 + DRAW_DUNGEON_MENU_STATUS_WINDOW_DATA_OFFSET)
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_CONST_1 (0x0000C402)
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_CONST_2 (999)
#define DRAW_DUNGEON_MENU_STATUS_WINDOW_BUFF_SIZE (256)
#define LINE_HEIGHT 12
#define X_OFFSET 115
void DrawDungeonMenuStatusWindow(struct Window* window);
void DungeonMenuSwitch(struct Window* window);
struct struct_2 {
u32 b; // 0x0
u8 PAD1[92];
u8* c; // 0x60
u8 PAD2[50];
};
struct struct_3 {
s8 e[4]; // 0x0
u32 f; // 0x4
struct entity* a; // 0x8
u32 b; // 0xC
u32 c; // 0x10
u32 d; // 0x14
};
struct struct_5 {
u32 field_0x0;
u32 field_0x4;
u8 PAD1[172];
struct struct_6* a; // 0xB4
};
struct struct_6 {
u8 PAD[74];
u16 a; // 0x4A
u16 field_0x4c;
u8 b; // 0x4E
u8 field_0x4f;
u16 c; // 0x50
u16 d; // 0x52
u8 e; // 0x54
u8 field_0x55;
u16 f; // 0x56
u16 g; // 0x58
};
struct struct_4 {
u8* str;
struct struct_3* st3;
};
#define OV31_02382B54_CONST_1 (0x00000233)
u32 ov31_02382B54(void);
void ov31_02382DAC(void);
struct struct_1* ov31_02382E08(void);
void ov31_02382E18(struct entity* arg_1, u32 arg_2);
void ov31_02382ED4(struct entity* arg_1);
void ov31_02382F68(struct Window* window);
#endif //PMDSKY_OVERLAY_3102382820_H

View File

@ -0,0 +1,35 @@
#ifndef PREPROCESS_STRING_H
#define PREPROCESS_STRING_H
struct PPStrValues {
u8* weather_0; // 0x0
u32 field_0x4;
u32 field_0x8;
u32 field_0xB;
u32 dungeon_0; // 0xC
u32 field_0x10;
u32 field_0x14;
u32 field_0x18;
u32 field_0x1c;
union { // 0x20
u32 digits_0;
u32 value_0;
u32 time_0;
u32 gold_left_0;
};
union { // 0x24
u32 digits_1;
u32 value_1;
};
u32 field_0x28;
u32 field_0x2c;
u32 field_0x30;
u8* string0; // 0x34
u32 field_0x38;
u32 field_0x3c;
u32 field_0x40;
u32 field_0x44;
u32 field_0x48;
};
#endif

View File

@ -1,6 +1,13 @@
#ifndef PMDSKY_UTIL_H
#define PMDSKY_UTIL_H
typedef s32 fx32_8; // 32-bit signed fixed-point number with 8 fraction bits
typedef u32 ufx32_8; // 32-bit unsigned fixed-point number with 8 fraction bits
typedef u8 undefined;
typedef u16 undefined2;
typedef u32 undefined4;
typedef u8 bool;
// RGBA8 structure. Sometimes alpha is ignored and only used for padding
struct rgba {
u8 r;
@ -21,4 +28,13 @@ struct uvec2_16 {
u16 y;
};
#endif //PMDSKY_UTIL_H
// a (16b.16b) fixed-point rational
struct fixed_point {
u16 integer;
u16 fractional;
};
// Compares two numbers and return the minimum
#define MIN(A, B) ((A > B) ? B : A)
#endif //PMDSKY_UTIL_H

View File

@ -22,6 +22,8 @@ Static main
Object asm/main_0200ED1C.o
Object src/main_02025788.o
Object asm/main_020257FC.o
Object src/main_020348E4.o
Object asm/main_02034974.o
Object src/main_02054BE0.o
Object asm/main_02054C24.o
Object lib/DSE/src/dc_envelope.o
@ -326,7 +328,8 @@ Overlay OVY_30
Overlay OVY_31
{
After OVY_29
Object asm/overlay_31.o
Object src/overlay_31_02382820.o
Object asm/overlay_31_02382FBC.o
}
Overlay OVY_32
{

20
src/main_020348E4.c Normal file
View File

@ -0,0 +1,20 @@
#include "main_020348E4.h"
extern struct struct_02AFDB8* _020AFDB8;
extern u32 sub_020347A0(struct struct_1*, struct struct_1*);
u32 sub_020348E4(struct struct_1* src)
{
if (sub_020347A0(src, &(_020AFDB8->b)) == 0) {
if (_020AFDB8->a != 0 && sub_020347A0(src, &(_020AFDB8->c))) {
return 0;
}
_020AFDB8->a = 1;
_020AFDB8->d = 0;
_020AFDB8->c = *src;
_020AFDB8->e = 0;
return 1;
}
return 0;
}

308
src/overlay_3102382820.c Normal file
View File

@ -0,0 +1,308 @@
#include "overlay_3102382820.h"
extern struct dungeon* DUNGEON_PTR;
extern const u8 DUNGEON_MENU_SWITCH_STR1[];// = "[dungeon:0]";
extern struct struct_1* OVERLAY31_UNKNOWN_POINTER__NA_238A260[2];
extern u32 DUNGEON_WINDOW_PARAMS_1;
extern u32 DUNGEON_WINDOW_PARAMS_2;
extern struct struct_1 DUNGEON_WINDOW_PARAMS_3;
extern u32 DUNGEON_WINDOW_PARAMS_4;
extern u32 DUNGEON_MAIN_MENU_ITEMS;
extern struct struct_4 ov31_0238A2A0;
extern struct struct_1 OVERLAY31_UNKNOWN_STRUCT__NA_2389E30;
extern u16 ov31_02389E22[];
extern void* MemAlloc(u32 size, u32 nmemb);
//extern u32 sub_020348E4(struct struct_1*);
extern struct entity* GetLeader(void);
extern s32 CeilFixedPoint(struct fixed_point);
extern u32 GetMoneyCarried(void);
extern void* GetApparentWeather(u32);
extern u32 sub_0204F9E0(void);
extern void ov29_022E2A78(u8*, void*, u32); // The third argument isn't actually used in the
// function (../asm/overlay_29_022E1A40.s#L1378)
extern u8* StringFromId(u32);
extern void PreprocessString(u8* dst, u32 dsize, const u8* src, u32 flags, struct PPStrValues* ptr);
extern void DrawTextInWindow(struct Window*, u32, u32, u8*);
extern void UpdateWindow(struct Window*);
extern u8* sub_02025888(void);
extern struct Window* GetWindow(struct Window*);
extern s32 sub_020265A8(u8*); // Measures the text's width in pixels
extern u32 ShouldMonsterRunAwayVariation(struct entity*, u32);
extern u32 Arm9LoadUnkFieldNa0x2029EC8(u32, u8*);
extern u8 CreateParentMenuFromStringIds(u32*, u32, struct struct_2*, u32*);
extern u8 CreateTextBox(u32*, void (*fun)(struct Window*));
extern u32 IsParentMenuActive(s8);
extern u32 sub_0202AB80(s8);
extern void Arm9StoreUnkFieldNa0x2029ED8(u32, u8);
extern u32 GetPressedButtons(u32, u16*);
extern u32 ShouldMonsterRunAwayVariation(struct entity*, u32);
extern void sub_0202AB94(s8, u32);
extern void sub_0202B030(s8);
extern void sub_0202F954(s8);
extern struct struct_1* sub_0202ABB0(s8);
extern void CloseTextBox(s8);
extern void CloseParentMenu(s8);
extern void MemFree(void*);
extern void ov29_022EA428(u32, u32);
extern void AdvanceFrame(u8);
extern u32 ov29_022F0B9C(void);
extern void ov29_022E0C2C(u32);
extern u32 GetFloorType(void);
extern u32 ov29_02338708(struct position*);
void EntryOverlay31(void) {
struct struct_1* r0;
if (sub_020348E4(&DUNGEON_WINDOW_PARAMS_3) == 0) {
return;
}
r0 = (struct struct_1*)MemAlloc(16, 0x8);
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0] = r0;
r0->a = 0;
OVERLAY31_UNKNOWN_POINTER__NA_238A260[1] = (struct struct_1*)0xa;
}
void DrawDungeonMenuStatusWindow(struct Window* window)
{
struct PPStrValues str_values;
u8 str_buff[DRAW_DUNGEON_MENU_STATUS_WINDOW_BUFF_SIZE];
u8 member_name_buffer[256];
struct entity* leader;
struct monster* leader_info;
u8* str;
s32 line_offset;
u8 is_valid_member;
s32 i;
leader = GetLeader();
leader_info = (struct monster*)leader->info;
//str_values.dungeon_0 = leader_info->roost;
str_values.digits_0 = CeilFixedPoint(leader_info->belly);
str_values.digits_1 = CeilFixedPoint(leader_info->max_belly);
str = StringFromId(DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_1);
PreprocessString(str_buff, DRAW_DUNGEON_MENU_STATUS_WINDOW_BUFF_SIZE, str, 0, &str_values);
DrawTextInWindow(window, X_OFFSET, 0, str_buff);
str_values.gold_left_0 = GetMoneyCarried();
str = StringFromId(DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_2);
PreprocessString(str_buff, DRAW_DUNGEON_MENU_STATUS_WINDOW_BUFF_SIZE, str, 0, &str_values);
DrawTextInWindow(window, X_OFFSET, LINE_HEIGHT, str_buff);
str_values.weather_0 = GetApparentWeather(0);
str = StringFromId(DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_3);
PreprocessString(str_buff, DRAW_DUNGEON_MENU_STATUS_WINDOW_BUFF_SIZE, str, 0, &str_values);
DrawTextInWindow(window, X_OFFSET, LINE_HEIGHT * 2, str_buff);
str_values.time_0 = sub_0204F9E0();
str = StringFromId(DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_4);
PreprocessString(str_buff, DRAW_DUNGEON_MENU_STATUS_WINDOW_BUFF_SIZE, str, DRAW_DUNGEON_MENU_STATUS_WINDOW_CONST_1, &str_values);
DrawTextInWindow(window, X_OFFSET, LINE_HEIGHT * 3, str_buff);
line_offset = 0;
for (i = 0; i < 4; i++) {
struct entity* party_member = DUNGEON_PTR->party_members[i];
if (party_member == NULL) {
is_valid_member = FALSE;
} else {
is_valid_member = (party_member->type != ENTITY_NOTHING);
}
if (is_valid_member) {
struct monster* member_info = party_member->info;
ov29_022E2A78(member_name_buffer, party_member, 0);
str_values.string0 = member_name_buffer;
str_values.value_0 = member_info->hp;
str_values.value_1 = MIN(member_info->max_hp_stat + member_info->max_hp_boost,
DRAW_DUNGEON_MENU_STATUS_WINDOW_CONST_2);
str = StringFromId(DRAW_DUNGEON_MENU_STATUS_WINDOW_STR_ID_5);
PreprocessString(str_buff, DRAW_DUNGEON_MENU_STATUS_WINDOW_BUFF_SIZE, str, 0, &str_values);
DrawTextInWindow(window, 4, line_offset, str_buff);
line_offset += 12;
if (line_offset >= 0x30) {
break;
}
}
}
UpdateWindow(window);
}
void DungeonMenuSwitch(struct Window* window)
{
struct PPStrValues str_values;
str_values.dungeon_0 = DUNGEON_PTR->id | 0x40000;
str_values.digits_0 = DUNGEON_PTR->floor;
u8* str_buff = sub_02025888();
PreprocessString(str_buff, 0x400, DUNGEON_MENU_SWITCH_STR1, 0, &str_values);
struct Window* window2 = GetWindow(window);
s32 text_width = sub_020265A8(str_buff);
s32 x_offset = (window2->width * 8 - text_width) / 2;
DrawTextInWindow(window, x_offset, 2, str_buff);
UpdateWindow(window);
}
u32 ov31_02382B54(void)
{
u16 pressed_buttons;
struct struct_2 sp;
struct entity* leader;
switch (OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->a) {
case 0:
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->a++;
break;
case 1:
for (int i = 0; i<7; i++) {
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->b[i] = 0;
}
leader = GetLeader();
if (ShouldMonsterRunAwayVariation(leader, 1)) {
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->b[0] = 3;
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->b[1] = 3;
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->b[2] = 3;
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->b[4] = 3;
}
sp.c = OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->b;
sp.b = Arm9LoadUnkFieldNa0x2029EC8(5, sp.c);
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[0] = CreateParentMenuFromStringIds(&DUNGEON_WINDOW_PARAMS_1, OV31_02382B54_CONST_1, &sp, &DUNGEON_MAIN_MENU_ITEMS);
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[2] = CreateTextBox(&DUNGEON_WINDOW_PARAMS_4, DrawDungeonMenuStatusWindow);
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[1] = CreateTextBox(&DUNGEON_WINDOW_PARAMS_2, DungeonMenuSwitch);
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->a++;
break;
case 2:
if (IsParentMenuActive(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[0])) {
u8 tmp4 = sub_0202AB80(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[0]);
Arm9StoreUnkFieldNa0x2029ED8(5, tmp4);
GetPressedButtons(0, &pressed_buttons);
if ((pressed_buttons & 0x400) == 0)
break;
struct entity* leader = GetLeader();
if (ShouldMonsterRunAwayVariation(leader, 1))
break;
sub_0202AB94(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[0], 0);
sub_0202B030(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[0]);
sub_0202F954(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[1]);
sub_0202F954(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[2]);
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->a++;
} else {
sub_0202F954(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[1]);
sub_0202F954(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[2]);
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->a++;
}
break;
case 3:
OVERLAY31_UNKNOWN_POINTER__NA_238A260[1] = sub_0202ABB0(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[0]);
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->a++;
return 4;
break;
}
return 1;
}
void ov31_02382DAC(void)
{
if (OVERLAY31_UNKNOWN_POINTER__NA_238A260[0] == NULL)
return;
CloseTextBox(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[1]);
CloseTextBox(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[2]);
CloseParentMenu(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]->f[0]);
MemFree(OVERLAY31_UNKNOWN_POINTER__NA_238A260[0]);
OVERLAY31_UNKNOWN_POINTER__NA_238A260[0] = NULL;
}
struct struct_1* ov31_02382E08(void)
{
return OVERLAY31_UNKNOWN_POINTER__NA_238A260[1];
}
void ov31_02382E18(struct entity* arg_1, u32 arg_2)
{
ov29_022EA428(6, 0);
AdvanceFrame(0x62);
AdvanceFrame(0x62);
ov31_02382ED4(arg_1);
while ((u8)(ov31_0238A2A0.st3 != NULL)) {
AdvanceFrame(0x62);
}
AdvanceFrame(0x62);
if (ov29_022F0B9C()) {
ov29_022EA428(11, 0);
} else if (arg_2) {
ov29_022EA428(11, 0);
} else {
ov29_022EA428(0, 0);
}
ov29_022E0C2C(1);
}
void ov31_02382ED4(struct entity* arg_1)
{
struct struct_3* tmp1;
if (sub_020348E4(&OVERLAY31_UNKNOWN_STRUCT__NA_2389E30) == 0)
return;
tmp1 = MemAlloc(sizeof(struct struct_3), 8);
ov31_0238A2A0.st3 = tmp1;
ov31_0238A2A0.st3->f = 0;
ov31_0238A2A0.st3->a = arg_1;
ov31_0238A2A0.st3->b = 0;
ov31_0238A2A0.st3->c = 0;
u32 floor_type = GetFloorType();
u32 r4 = 0;
if (floor_type == 2) {
r4 = 2;
} else if (floor_type == 1) {
r4 = 1;
} else if (ov29_02338708(&(arg_1->pos))) {
r4 = 3;
}
ov31_0238A2A0.st3->d = r4;
}
void ov31_02382F68(struct Window* window)
{
u8* str = StringFromId(ov31_02389E22[ov31_0238A2A0.st3->d * 2]);
ov31_0238A2A0.str = str;
DrawTextInWindow(window, 16, 18, str);
UpdateWindow(window);
}

View File

@ -16,6 +16,8 @@ if len(sys.argv) != 3:
_, function_location, function_header = sys.argv
if function_location.endswith('.s'):
function_location = function_location[:-2]
if function_location.startswith("./asm/"):
function_location = function_location[6:]
if function_header.endswith(';'):
function_header = function_header[:-1]

View File

@ -4,7 +4,7 @@ OUT_FILE=ctx.c
GCC=gcc
FLAGS="-E -P -dD -undef"
INCLUDES="-Iinclude -Iinclude/library -Ifiles -Ilib/include -include global.h"
INCLUDES="-Iinclude -Iinclude/library -Ifiles -Ilib/include" # -include global.h"
DEFINES="-DGAME_REMASTER=0 -DNORTH_AMERICA -DPM_KEEP_ASSERTS -DSDK_ARM9 -DSDK_CODE_ARM -DSDK_FINALROM"