mirror of
https://github.com/pret/pmd-sky.git
synced 2026-09-13 13:57:25 -05:00
Decomp 50 functions in five themed groups
Located as five groups of ten before any matching was attempted, then all fifty matched, then one build, then one commit. overlay_04/06 global accessors 10 ov04_0233CA80 .. ov06_0233CAA8 hardware register bit-fields 10 sub_02009BE8 .. sub_02009D20 save reset / play timer 10 sub_020483B8 .. sub_0204F9E0 sound veneers + window accessors 10 sub_02017C90 .. sub_02030A74 dungeon fixed-room / item 10 CloseFixedBin .. GenerateStandardItem Every group is a contiguous run at a file head or tail, so extract_function merges each function into an adjacent source instead of splitting a .s. None of the fifty carries a region conditional -- checked per function, not per file -- so US alone verifies this commit. Twelve of the fifty are interworking tail-call veneers (ldr ip, =f; bx ip). That falls straight out of an ordinary forwarding call, and survives both argument reordering (GenerateStandardItem) and a computed argument (sub_020483B8). Nothing in the tree had a veneer decompiled, so the shape was proven on one before the other forty-nine were written. Their parameter lists are guesses: a veneer forwards registers untouched, so the emitted code is identical for any arity and the match constrains nothing. sub_020483D8 returns its callee's result. It sat at 40 through five spellings with the pointer one register low; the target never reuses r0 after the call because that value is the return value. Adding `return ok;` gives 0, and the return is invisible in the asm because the value is already in place. Two type corrections found by probing: the Are*Allowed family compares the dungeon id unsigned (bcc, not blt -- 200 signed), and the register setters need a u32 intermediate, since a u16 local forces a lsl/lsr truncation the target lacks (615). New placeholder structs: unk_0233F660, unk_0233EEE0, unk_020AFEF4, unk_02030A50. src/main_02017C80.c's existing PlaySeByIdVolume(s32, s32) declaration is kept in preference to this commit's; both affected functions were re-scored against it and still match. Authored by Claude (Opus 5) under human direction. All fifty verified at score 0. Confirmed by a matching build: build/pmdsky.us/pmdsky.us.nds: OK. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#pragma once
|
||||
.public G2x_SetBlendAlpha_
|
||||
.public G3X_SetClearColor
|
||||
.public GXS_SetGraphicsMode
|
||||
.public GX_SetBankForBG
|
||||
.public GX_SetBankForBGExtPltt
|
||||
.public GX_SetBankForOBJ
|
||||
@@ -11,7 +12,6 @@
|
||||
.public GX_SetBankForTex
|
||||
.public GX_SetBankForTexPltt
|
||||
.public GX_SetGraphicsMode
|
||||
.public GXS_SetGraphicsMode
|
||||
.public sub_02009120
|
||||
.public sub_020091CC
|
||||
.public sub_020091F8
|
||||
@@ -20,3 +20,9 @@
|
||||
.public sub_020092F4
|
||||
.public sub_02009358
|
||||
.public sub_02009514
|
||||
.public sub_02009BE8
|
||||
.public sub_02009C10
|
||||
.public sub_02009CA8
|
||||
.public sub_02009CD0
|
||||
.public sub_02009CF8
|
||||
.public sub_02009D20
|
||||
|
||||
@@ -62,7 +62,6 @@
|
||||
.public Snd_LockChannel
|
||||
.public Snd_UnlockChannel
|
||||
.public ZInit8
|
||||
.public _0209915C
|
||||
.public _0209916C
|
||||
.public _0209918C
|
||||
.public _020991C8
|
||||
@@ -124,7 +123,6 @@
|
||||
.public _020AFB6C
|
||||
.public _020AFC28
|
||||
.public _020AFC30
|
||||
.public _022A4BE8
|
||||
.public _022A4BEC
|
||||
.public _022A4C00
|
||||
.public _022A4C28
|
||||
@@ -2,7 +2,6 @@
|
||||
.public AppendStandardStringToMission
|
||||
.public Arm9LoadUnkFieldNa0x2029EC8
|
||||
.public BAG_ITEMS_PTR_MIRROR
|
||||
.public ClearAdventureLogStruct
|
||||
.public ClearStorageSelectedItemTable
|
||||
.public CloseAdvancedMenu
|
||||
.public CloseAdvancedTextBox
|
||||
@@ -28,7 +27,6 @@
|
||||
.public CreateTextBox
|
||||
.public CreateTextBoxWithArg
|
||||
.public DUNGEON_PTR
|
||||
.public DebugPrintEventFlagSize
|
||||
.public DrawTextInWindow
|
||||
.public DrawTileGrid
|
||||
.public FreeUnkStorageStruct0x18c0
|
||||
@@ -183,16 +181,8 @@
|
||||
.public sub_02043400
|
||||
.public sub_02043434
|
||||
.public sub_02043468
|
||||
.public sub_02048B48
|
||||
.public sub_02048B74
|
||||
.public sub_02048C0C
|
||||
.public sub_02048C3C
|
||||
.public sub_02048C4C
|
||||
.public sub_02048C5C
|
||||
.public sub_0204F9B8
|
||||
.public sub_020547C8
|
||||
.public sub_020547D8
|
||||
.public sub_02054804
|
||||
.public sub_02056228
|
||||
.public sub_02058460
|
||||
.public sub_0206637C
|
||||
|
||||
@@ -13,7 +13,6 @@
|
||||
.public GetNameString
|
||||
.public GetNbItemsInBag
|
||||
.public GetPartyMembers
|
||||
.public GetPlayTimeSeconds
|
||||
.public GetResolvedPerformanceProgressFlag
|
||||
.public GuestMonsterToGroundMonster
|
||||
.public IsLevelResetDungeon
|
||||
@@ -23,9 +22,6 @@
|
||||
.public MISSION_FLOOR_RANKS_PTRS
|
||||
.public OUTLAW_LEVEL_TABLE
|
||||
.public OUTLAW_MINION_LEVEL_TABLE
|
||||
.public PLAY_TIME_SECONDS
|
||||
.public PlayTimerTick
|
||||
.public ResetPlayTimer
|
||||
.public SECONDARY_TERRAIN_TYPES
|
||||
.public StrncpyName
|
||||
.public TEAM_MEMBER_TABLE_PTR
|
||||
@@ -35,6 +31,4 @@
|
||||
.public _022AB4F8
|
||||
.public _022AB5AC
|
||||
.public sub_0204CEE0
|
||||
.public sub_02050E5C
|
||||
.public sub_02050E8C
|
||||
.public sub_0205EE40
|
||||
|
||||
4
asm/include/main_0204F9F4.inc
Normal file
4
asm/include/main_0204F9F4.inc
Normal file
@@ -0,0 +1,4 @@
|
||||
#pragma once
|
||||
.public PLAY_TIME_SECONDS
|
||||
.public sub_02050E5C
|
||||
.public sub_02050E8C
|
||||
@@ -16,7 +16,6 @@
|
||||
.public GetLanguageType
|
||||
.public GetMainTeamNameWithCheck
|
||||
.public GetPressedButtons
|
||||
.public GetRankStorageSize
|
||||
.public GetStringFromFileVeneer
|
||||
.public IncrementNbSkyGiftsSent
|
||||
.public InitPreprocessorArgs
|
||||
@@ -33,6 +32,12 @@
|
||||
.public MemFree
|
||||
.public MemZero
|
||||
.public NoteSaveBase
|
||||
.public PlaySeVolumeWrapper
|
||||
.public RandInt
|
||||
.public RemoveItemAtIdxInStorage
|
||||
.public StrncpySimpleNoPadSafe
|
||||
.public UnloadFile
|
||||
.public ZeroInitMissionRewardDataStruct
|
||||
.public ov01_0232B540
|
||||
.public ov01_0232B5D0
|
||||
.public ov01_0232E94C
|
||||
@@ -51,10 +56,30 @@
|
||||
.public ov01_02337DD0
|
||||
.public ov01_02337E0C
|
||||
.public ov01_0233C1DC
|
||||
.public PlaySeVolumeWrapper
|
||||
.public RandInt
|
||||
.public RemoveItemAtIdxInStorage
|
||||
.public StrncpySimpleNoPadSafe
|
||||
.public ov04_0233CA80
|
||||
.public ov04_0233CA98
|
||||
.public ov04_0233CAA8
|
||||
.public ov04_0233CAB8
|
||||
.public ov04_0233CAC8
|
||||
.public ov04_0233CAD8
|
||||
.public ov04_0233CAE8
|
||||
.public ov04_0233F568
|
||||
.public ov04_0233F56C
|
||||
.public ov04_0233F580
|
||||
.public ov04_0233F584
|
||||
.public ov04_0233F598
|
||||
.public ov04_0233F59C
|
||||
.public ov04_0233F5B8
|
||||
.public ov04_0233F5BC
|
||||
.public ov04_0233F5D8
|
||||
.public ov04_0233F5DC
|
||||
.public ov04_0233F5F8
|
||||
.public ov04_0233F604
|
||||
.public ov04_0233F614
|
||||
.public ov04_0233F624
|
||||
.public ov04_0233F640
|
||||
.public ov04_0233F644
|
||||
.public ov04_0233F670
|
||||
.public sub_02003B5C
|
||||
.public sub_02003B94
|
||||
.public sub_02003BC8
|
||||
@@ -87,5 +112,3 @@
|
||||
.public sub_02046C78
|
||||
.public sub_02046D20
|
||||
.public sub_0204A018
|
||||
.public UnloadFile
|
||||
.public ZeroInitMissionRewardDataStruct
|
||||
@@ -20,10 +20,13 @@
|
||||
.public IsSpecialEpisodeOpen
|
||||
.public IsTouchScreenNotOff
|
||||
.public MemAlloc
|
||||
.public MemcpySimple
|
||||
.public MemFree
|
||||
.public MemZero
|
||||
.public MemcpySimple
|
||||
.public NoteSaveBase
|
||||
.public SetSpecialEpisodeOpen
|
||||
.public ShowKeyboard
|
||||
.public WonderMailPasswordToMission
|
||||
.public ov00_022BCA80
|
||||
.public ov00_022BCBAC
|
||||
.public ov00_022BD264
|
||||
@@ -53,8 +56,30 @@
|
||||
.public ov01_02338EC4
|
||||
.public ov01_02339888
|
||||
.public ov01_023398A4
|
||||
.public SetSpecialEpisodeOpen
|
||||
.public ShowKeyboard
|
||||
.public ov06_0233CA80
|
||||
.public ov06_0233CA98
|
||||
.public ov06_0233CAA8
|
||||
.public ov06_0233ED04
|
||||
.public ov06_0233ED1C
|
||||
.public ov06_0233ED34
|
||||
.public ov06_0233ED4C
|
||||
.public ov06_0233ED64
|
||||
.public ov06_0233ED68
|
||||
.public ov06_0233ED84
|
||||
.public ov06_0233EDA4
|
||||
.public ov06_0233EDCC
|
||||
.public ov06_0233EDD0
|
||||
.public ov06_0233EDD4
|
||||
.public ov06_0233EDFC
|
||||
.public ov06_0233EE24
|
||||
.public ov06_0233EE4C
|
||||
.public ov06_0233EE84
|
||||
.public ov06_0233EEC0
|
||||
.public ov06_0233EEC4
|
||||
.public ov06_0233EEC8
|
||||
.public ov06_0233EEE0
|
||||
.public ov06_0233EEEC
|
||||
.public ov06_0233EEF0
|
||||
.public sub_02003B94
|
||||
.public sub_02003BC8
|
||||
.public sub_02003BFC
|
||||
@@ -91,4 +116,3 @@
|
||||
.public sub_02069D40
|
||||
.public sub_02069D94
|
||||
.public sub_02069DC0
|
||||
.public WonderMailPasswordToMission
|
||||
@@ -26,10 +26,6 @@
|
||||
.public UpdateMinimap
|
||||
.public UpdateTrapsVisibility
|
||||
.public ZInit8
|
||||
.public ov10_022C6C75
|
||||
.public ov10_022C6C77
|
||||
.public ov10_022C6C78
|
||||
.public ov10_022C6C79
|
||||
.public ov29_022EA370
|
||||
.public ov29_02336694
|
||||
.public ov29_02342BEC
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
#pragma once
|
||||
.public GenerateItem
|
||||
.public SetPreprocessorArgsIdVal
|
||||
.public SubstitutePlaceholderItemTags
|
||||
.public ov29_023531A4
|
||||
.public ov29_023531BC
|
||||
.public ov29_023537B0
|
||||
3
asm/include/overlay_29_02344BA8.inc
Normal file
3
asm/include/overlay_29_02344BA8.inc
Normal file
@@ -0,0 +1,3 @@
|
||||
#pragma once
|
||||
.public SubstitutePlaceholderItemTags
|
||||
.public ov29_023531BC
|
||||
@@ -377,141 +377,3 @@ sub_02009BC0: ; 0x02009BC0
|
||||
.align 2, 0
|
||||
_02009BE4: .word 0x04000048
|
||||
arm_func_end sub_02009BC0
|
||||
|
||||
arm_func_start sub_02009BE8
|
||||
sub_02009BE8: ; 0x02009BE8
|
||||
ldr r2, _02009C0C ; =0x0400004A
|
||||
cmp r1, #0
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #0x3f00
|
||||
orr r1, r1, r0, lsl #8
|
||||
ldr r0, _02009C0C ; =0x0400004A
|
||||
orrne r1, r1, #0x2000
|
||||
strh r1, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009C0C: .word 0x0400004A
|
||||
arm_func_end sub_02009BE8
|
||||
|
||||
arm_func_start sub_02009C10
|
||||
sub_02009C10: ; 0x02009C10
|
||||
ldr r2, _02009C34 ; =0x0400004A
|
||||
cmp r1, #0
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #0x3f
|
||||
orr r1, r1, r0
|
||||
ldr r0, _02009C34 ; =0x0400004A
|
||||
orrne r1, r1, #0x20
|
||||
strh r1, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009C34: .word 0x0400004A
|
||||
arm_func_end sub_02009C10
|
||||
|
||||
arm_func_start sub_02009C38
|
||||
sub_02009C38: ; 0x02009C38
|
||||
ldr r2, _02009C50 ; =0x0400000A
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #3
|
||||
orr r0, r1, r0
|
||||
strh r0, [r2]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009C50: .word 0x0400000A
|
||||
arm_func_end sub_02009C38
|
||||
|
||||
arm_func_start sub_02009C54
|
||||
sub_02009C54: ; 0x02009C54
|
||||
ldr r2, _02009C6C ; =0x04000008
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #3
|
||||
orr r0, r1, r0
|
||||
strh r0, [r2]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009C6C: .word 0x04000008
|
||||
arm_func_end sub_02009C54
|
||||
|
||||
arm_func_start sub_02009C70
|
||||
sub_02009C70: ; 0x02009C70
|
||||
ldr r2, _02009C88 ; =0x0400000C
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #3
|
||||
orr r0, r1, r0
|
||||
strh r0, [r2]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009C88: .word 0x0400000C
|
||||
arm_func_end sub_02009C70
|
||||
|
||||
arm_func_start sub_02009C8C
|
||||
sub_02009C8C: ; 0x02009C8C
|
||||
ldr r2, _02009CA4 ; =0x0400000E
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #3
|
||||
orr r0, r1, r0
|
||||
strh r0, [r2]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009CA4: .word 0x0400000E
|
||||
arm_func_end sub_02009C8C
|
||||
|
||||
arm_func_start sub_02009CA8
|
||||
sub_02009CA8: ; 0x02009CA8
|
||||
ldr r2, _02009CCC ; =0x04001048
|
||||
cmp r1, #0
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #0x3f
|
||||
orr r1, r1, r0
|
||||
ldr r0, _02009CCC ; =0x04001048
|
||||
orrne r1, r1, #0x20
|
||||
strh r1, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009CCC: .word 0x04001048
|
||||
arm_func_end sub_02009CA8
|
||||
|
||||
arm_func_start sub_02009CD0
|
||||
sub_02009CD0: ; 0x02009CD0
|
||||
ldr r2, _02009CF4 ; =0x04001048
|
||||
cmp r1, #0
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #0x3f00
|
||||
orr r1, r1, r0, lsl #8
|
||||
ldr r0, _02009CF4 ; =0x04001048
|
||||
orrne r1, r1, #0x2000
|
||||
strh r1, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009CF4: .word 0x04001048
|
||||
arm_func_end sub_02009CD0
|
||||
|
||||
arm_func_start sub_02009CF8
|
||||
sub_02009CF8: ; 0x02009CF8
|
||||
ldr r2, _02009D1C ; =0x0400104A
|
||||
cmp r1, #0
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #0x3f00
|
||||
orr r1, r1, r0, lsl #8
|
||||
ldr r0, _02009D1C ; =0x0400104A
|
||||
orrne r1, r1, #0x2000
|
||||
strh r1, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009D1C: .word 0x0400104A
|
||||
arm_func_end sub_02009CF8
|
||||
|
||||
arm_func_start sub_02009D20
|
||||
sub_02009D20: ; 0x02009D20
|
||||
ldr r2, _02009D44 ; =0x0400104A
|
||||
cmp r1, #0
|
||||
ldrh r1, [r2]
|
||||
bic r1, r1, #0x3f
|
||||
orr r1, r1, r0
|
||||
ldr r0, _02009D44 ; =0x0400104A
|
||||
orrne r1, r1, #0x20
|
||||
strh r1, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02009D44: .word 0x0400104A
|
||||
arm_func_end sub_02009D20
|
||||
|
||||
@@ -1,79 +1,8 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "main_02017C90.inc"
|
||||
.include "main_02017D20.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start sub_02017C90
|
||||
sub_02017C90: ; 0x02017C90
|
||||
ldr ip, _02017C98 ; =sub_0201831C
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02017C98: .word sub_0201831C
|
||||
arm_func_end sub_02017C90
|
||||
|
||||
arm_func_start sub_02017C9C
|
||||
sub_02017C9C: ; 0x02017C9C
|
||||
ldr ip, _02017CA4 ; =sub_020183A0
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02017CA4: .word sub_020183A0
|
||||
arm_func_end sub_02017C9C
|
||||
|
||||
arm_func_start sub_02017CA8
|
||||
sub_02017CA8: ; 0x02017CA8
|
||||
ldr ip, _02017CB0 ; =sub_020183E4
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02017CB0: .word sub_020183E4
|
||||
arm_func_end sub_02017CA8
|
||||
|
||||
arm_func_start sub_02017CB4
|
||||
sub_02017CB4: ; 0x02017CB4
|
||||
ldr ip, _02017CBC ; =sub_02018428
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02017CBC: .word sub_02018428
|
||||
arm_func_end sub_02017CB4
|
||||
|
||||
arm_func_start sub_02017CC0
|
||||
sub_02017CC0: ; 0x02017CC0
|
||||
ldr ip, _02017CC8 ; =sub_02018460
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02017CC8: .word sub_02018460
|
||||
arm_func_end sub_02017CC0
|
||||
|
||||
arm_func_start PlaySeVolumeWrapper
|
||||
PlaySeVolumeWrapper: ; 0x02017CCC
|
||||
ldr r1, _02017CE4 ; =_0209915C
|
||||
mov r0, r0, lsl #1
|
||||
ldrh r0, [r1, r0]
|
||||
ldr ip, _02017CE8 ; =PlaySeByIdVolume
|
||||
mov r1, #0x100
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02017CE4: .word _0209915C
|
||||
_02017CE8: .word PlaySeByIdVolume
|
||||
arm_func_end PlaySeVolumeWrapper
|
||||
|
||||
arm_func_start sub_02017CEC
|
||||
sub_02017CEC: ; 0x02017CEC
|
||||
stmdb sp!, {r3, lr}
|
||||
ldr r2, _02017D18 ; =_022A4BE8
|
||||
ldrsh r0, [r2]
|
||||
cmp r0, #0
|
||||
ldmgtia sp!, {r3, pc}
|
||||
ldr r0, _02017D1C ; =0x00003F05
|
||||
mov r3, #3
|
||||
mov r1, #0x100
|
||||
strh r3, [r2]
|
||||
bl PlaySeByIdVolume
|
||||
ldmia sp!, {r3, pc}
|
||||
.align 2, 0
|
||||
_02017D18: .word _022A4BE8
|
||||
_02017D1C: .word 0x00003F05
|
||||
arm_func_end sub_02017CEC
|
||||
|
||||
arm_func_start sub_02017D20
|
||||
sub_02017D20: ; 0x02017D20
|
||||
stmdb sp!, {r3, lr}
|
||||
@@ -1,36 +1,8 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "main_02030A50.inc"
|
||||
.include "main_02030A90.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start sub_02030A50
|
||||
sub_02030A50: ; 0x02030A50
|
||||
stmdb sp!, {r4, lr}
|
||||
mov r4, r1
|
||||
bl GetWindowContents
|
||||
str r4, [r0, #0xc0]
|
||||
ldmia sp!, {r4, pc}
|
||||
arm_func_end sub_02030A50
|
||||
|
||||
arm_func_start sub_02030A64
|
||||
sub_02030A64: ; 0x02030A64
|
||||
stmdb sp!, {r3, lr}
|
||||
bl GetWindowContents
|
||||
ldr r0, [r0, #0xc0]
|
||||
ldmia sp!, {r3, pc}
|
||||
arm_func_end sub_02030A64
|
||||
|
||||
arm_func_start sub_02030A74
|
||||
sub_02030A74: ; 0x02030A74
|
||||
stmdb sp!, {r4, lr}
|
||||
mov r4, r1
|
||||
bl GetWindowContents
|
||||
mov r1, r4
|
||||
add r0, r0, #4
|
||||
bl sub_02031C74
|
||||
ldmia sp!, {r4, pc}
|
||||
arm_func_end sub_02030A74
|
||||
|
||||
arm_func_start sub_02030A90
|
||||
sub_02030A90: ; 0x02030A90
|
||||
stmdb sp!, {r4, lr}
|
||||
@@ -6066,92 +6066,3 @@ sub_02048384: ; 0x02048384
|
||||
.align 2, 0
|
||||
_020483B4: .word _020AFEF4
|
||||
arm_func_end sub_02048384
|
||||
|
||||
arm_func_start sub_020483B8
|
||||
sub_020483B8: ; 0x020483B8
|
||||
ldr r0, _020483D0 ; =_020AFEF4
|
||||
ldr ip, _020483D4 ; =sub_020476EC
|
||||
ldr r0, [r0]
|
||||
add r0, r0, #0x3100
|
||||
ldrsh r0, [r0, #0xb8]
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_020483D0: .word _020AFEF4
|
||||
_020483D4: .word sub_020476EC
|
||||
arm_func_end sub_020483B8
|
||||
|
||||
arm_func_start sub_020483D8
|
||||
sub_020483D8: ; 0x020483D8
|
||||
stmdb sp!, {r3, lr}
|
||||
bl sub_0204771C
|
||||
cmp r0, #0
|
||||
ldrne r1, _020483FC ; =_020AFEF4
|
||||
movne r2, #0
|
||||
ldrne r1, [r1]
|
||||
addne r1, r1, #0x3000
|
||||
strneb r2, [r1, #0x1b2]
|
||||
ldmia sp!, {r3, pc}
|
||||
.align 2, 0
|
||||
_020483FC: .word _020AFEF4
|
||||
arm_func_end sub_020483D8
|
||||
|
||||
arm_func_start sub_02048400
|
||||
sub_02048400: ; 0x02048400
|
||||
ldr r0, _0204841C ; =_020AFEF4
|
||||
ldr r0, [r0]
|
||||
cmp r0, #0
|
||||
movne r0, #1
|
||||
moveq r0, #0
|
||||
and r0, r0, #0xff
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0204841C: .word _020AFEF4
|
||||
arm_func_end sub_02048400
|
||||
|
||||
arm_func_start sub_02048420
|
||||
sub_02048420: ; 0x02048420
|
||||
stmdb sp!, {r3, lr}
|
||||
bl DebugPrintEventFlagSize
|
||||
bl sub_02048B74
|
||||
ldmia sp!, {r3, pc}
|
||||
arm_func_end sub_02048420
|
||||
|
||||
arm_func_start sub_02048430
|
||||
sub_02048430: ; 0x02048430
|
||||
stmdb sp!, {r3, lr}
|
||||
bl sub_0206637C
|
||||
mov r0, #0
|
||||
bl sub_02048C0C
|
||||
mvn r0, #0
|
||||
bl sub_02048C4C
|
||||
bl sub_0204F9B8
|
||||
bl sub_02048B48
|
||||
ldmia sp!, {r3, pc}
|
||||
arm_func_end sub_02048430
|
||||
|
||||
arm_func_start sub_02048454
|
||||
sub_02048454: ; 0x02048454
|
||||
stmdb sp!, {r3, lr}
|
||||
bl ClearAdventureLogStruct
|
||||
bl sub_0206637C
|
||||
mov r0, #0
|
||||
bl sub_02048C0C
|
||||
mvn r0, #0
|
||||
bl sub_02048C4C
|
||||
bl sub_0204F9B8
|
||||
bl sub_02048B48
|
||||
bl sub_02048C5C
|
||||
ldmia sp!, {r3, pc}
|
||||
arm_func_end sub_02048454
|
||||
|
||||
arm_func_start sub_02048480
|
||||
sub_02048480: ; 0x02048480
|
||||
stmdb sp!, {r3, lr}
|
||||
bl sub_02048C3C
|
||||
mvn r1, #0
|
||||
cmp r0, r1
|
||||
movne r0, #1
|
||||
moveq r0, #0
|
||||
and r0, r0, #0xff
|
||||
ldmia sp!, {r3, pc}
|
||||
arm_func_end sub_02048480
|
||||
|
||||
@@ -783,55 +783,3 @@ _0204F9B0: .word 0x000042B9
|
||||
_0204F9B4: .word 0x000042BA
|
||||
#endif
|
||||
arm_func_end GetGroundNameId
|
||||
|
||||
arm_func_start sub_0204F9B8
|
||||
sub_0204F9B8: ; 0x0204F9B8
|
||||
ldr ip, _0204F9C4 ; =ResetPlayTimer
|
||||
ldr r0, _0204F9C8 ; =PLAY_TIME_SECONDS
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_0204F9C4: .word ResetPlayTimer
|
||||
_0204F9C8: .word PLAY_TIME_SECONDS
|
||||
arm_func_end sub_0204F9B8
|
||||
|
||||
arm_func_start sub_0204F9CC
|
||||
sub_0204F9CC: ; 0x0204F9CC
|
||||
ldr ip, _0204F9D8 ; =PlayTimerTick
|
||||
ldr r0, _0204F9DC ; =PLAY_TIME_SECONDS
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_0204F9D8: .word PlayTimerTick
|
||||
_0204F9DC: .word PLAY_TIME_SECONDS
|
||||
arm_func_end sub_0204F9CC
|
||||
|
||||
arm_func_start sub_0204F9E0
|
||||
sub_0204F9E0: ; 0x0204F9E0
|
||||
ldr ip, _0204F9EC ; =GetPlayTimeSeconds
|
||||
ldr r0, _0204F9F0 ; =PLAY_TIME_SECONDS
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_0204F9EC: .word GetPlayTimeSeconds
|
||||
_0204F9F0: .word PLAY_TIME_SECONDS
|
||||
arm_func_end sub_0204F9E0
|
||||
|
||||
arm_func_start sub_0204F9F4
|
||||
sub_0204F9F4: ; 0x0204F9F4
|
||||
ldr ip, _0204FA04 ; =sub_02050E5C
|
||||
mov r1, r0
|
||||
ldr r0, _0204FA08 ; =PLAY_TIME_SECONDS
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_0204FA04: .word sub_02050E5C
|
||||
_0204FA08: .word PLAY_TIME_SECONDS
|
||||
arm_func_end sub_0204F9F4
|
||||
|
||||
arm_func_start sub_0204FA0C
|
||||
sub_0204FA0C: ; 0x0204FA0C
|
||||
ldr ip, _0204FA1C ; =sub_02050E8C
|
||||
mov r1, r0
|
||||
ldr r0, _0204FA20 ; =PLAY_TIME_SECONDS
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_0204FA1C: .word sub_02050E8C
|
||||
_0204FA20: .word PLAY_TIME_SECONDS
|
||||
arm_func_end sub_0204FA0C
|
||||
|
||||
26
asm/main_0204F9F4.s
Normal file
26
asm/main_0204F9F4.s
Normal file
@@ -0,0 +1,26 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "main_0204F9F4.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start sub_0204F9F4
|
||||
sub_0204F9F4: ; 0x0204F9F4
|
||||
ldr ip, _0204FA04 ; =sub_02050E5C
|
||||
mov r1, r0
|
||||
ldr r0, _0204FA08 ; =PLAY_TIME_SECONDS
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_0204FA04: .word sub_02050E5C
|
||||
_0204FA08: .word PLAY_TIME_SECONDS
|
||||
arm_func_end sub_0204F9F4
|
||||
|
||||
arm_func_start sub_0204FA0C
|
||||
sub_0204FA0C: ; 0x0204FA0C
|
||||
ldr ip, _0204FA1C ; =sub_02050E8C
|
||||
mov r1, r0
|
||||
ldr r0, _0204FA20 ; =PLAY_TIME_SECONDS
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_0204FA1C: .word sub_02050E8C
|
||||
_0204FA20: .word PLAY_TIME_SECONDS
|
||||
arm_func_end sub_0204FA0C
|
||||
@@ -1,73 +1,8 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "overlay_04.inc"
|
||||
.include "overlay_04_0233CAF8.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start ov04_0233CA80
|
||||
ov04_0233CA80: ; 0x0233CA80
|
||||
ldr ip, _0233CA90 ; =MemZero
|
||||
ldr r0, _0233CA94 ; =ov04_0233F660
|
||||
mov r1, #0x10
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_0233CA90: .word MemZero
|
||||
_0233CA94: .word ov04_0233F660
|
||||
arm_func_end ov04_0233CA80
|
||||
|
||||
arm_func_start ov04_0233CA98
|
||||
ov04_0233CA98: ; 0x0233CA98
|
||||
ldr r1, _0233CAA4 ; =ov04_0233F660
|
||||
str r0, [r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0233CAA4: .word ov04_0233F660
|
||||
arm_func_end ov04_0233CA98
|
||||
|
||||
arm_func_start ov04_0233CAA8
|
||||
ov04_0233CAA8: ; 0x0233CAA8
|
||||
ldr r0, _0233CAB4 ; =ov04_0233F660
|
||||
ldr r0, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0233CAB4: .word ov04_0233F660
|
||||
arm_func_end ov04_0233CAA8
|
||||
|
||||
arm_func_start ov04_0233CAB8
|
||||
ov04_0233CAB8: ; 0x0233CAB8
|
||||
ldr r1, _0233CAC4 ; =ov04_0233F660
|
||||
str r0, [r1, #4]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0233CAC4: .word ov04_0233F660
|
||||
arm_func_end ov04_0233CAB8
|
||||
|
||||
arm_func_start ov04_0233CAC8
|
||||
ov04_0233CAC8: ; 0x0233CAC8
|
||||
ldr r0, _0233CAD4 ; =ov04_0233F660
|
||||
ldr r0, [r0, #4]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0233CAD4: .word ov04_0233F660
|
||||
arm_func_end ov04_0233CAC8
|
||||
|
||||
arm_func_start ov04_0233CAD8
|
||||
ov04_0233CAD8: ; 0x0233CAD8
|
||||
ldr r1, _0233CAE4 ; =ov04_0233F660
|
||||
strb r0, [r1, #0xc]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0233CAE4: .word ov04_0233F660
|
||||
arm_func_end ov04_0233CAD8
|
||||
|
||||
arm_func_start ov04_0233CAE8
|
||||
ov04_0233CAE8: ; 0x0233CAE8
|
||||
ldr r0, _0233CAF4 ; =ov04_0233F660
|
||||
ldrb r0, [r0, #0xc]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0233CAF4: .word ov04_0233F660
|
||||
arm_func_end ov04_0233CAE8
|
||||
|
||||
arm_func_start ov04_0233CAF8
|
||||
ov04_0233CAF8: ; 0x0233CAF8
|
||||
stmdb sp!, {lr}
|
||||
@@ -1,37 +1,8 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "overlay_06.inc"
|
||||
.include "overlay_06_0233CAB8.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start ov06_0233CA80
|
||||
ov06_0233CA80: ; 0x0233CA80
|
||||
ldr ip, _0233CA90 ; =MemZero
|
||||
ldr r0, _0233CA94 ; =ov06_0233EEE0
|
||||
mov r1, #0xc
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_0233CA90: .word MemZero
|
||||
_0233CA94: .word ov06_0233EEE0
|
||||
arm_func_end ov06_0233CA80
|
||||
|
||||
arm_func_start ov06_0233CA98
|
||||
ov06_0233CA98: ; 0x0233CA98
|
||||
ldr r1, _0233CAA4 ; =ov06_0233EEE0
|
||||
str r0, [r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0233CAA4: .word ov06_0233EEE0
|
||||
arm_func_end ov06_0233CA98
|
||||
|
||||
arm_func_start ov06_0233CAA8
|
||||
ov06_0233CAA8: ; 0x0233CAA8
|
||||
ldr r0, _0233CAB4 ; =ov06_0233EEE0
|
||||
ldr r0, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0233CAB4: .word ov06_0233EEE0
|
||||
arm_func_end ov06_0233CAA8
|
||||
|
||||
arm_func_start ov06_0233CAB8
|
||||
ov06_0233CAB8: ; 0x0233CAB8
|
||||
ldr r1, _0233CAC4 ; =ov06_0233EEE0
|
||||
@@ -560,93 +560,3 @@ OpenFixedBin: ; 0x02344054
|
||||
.align 2, 0
|
||||
_02344084: .word FIXED_ROOM_DATA_PTR
|
||||
arm_func_end OpenFixedBin
|
||||
|
||||
arm_func_start CloseFixedBin
|
||||
CloseFixedBin: ; 0x02344088
|
||||
stmdb sp!, {r3, lr}
|
||||
ldr r0, _023440A8 ; =FIXED_ROOM_DATA_PTR
|
||||
ldr r0, [r0]
|
||||
bl MemFree
|
||||
ldr r0, _023440A8 ; =FIXED_ROOM_DATA_PTR
|
||||
mov r1, #0
|
||||
str r1, [r0]
|
||||
ldmia sp!, {r3, pc}
|
||||
.align 2, 0
|
||||
_023440A8: .word FIXED_ROOM_DATA_PTR
|
||||
arm_func_end CloseFixedBin
|
||||
|
||||
arm_func_start AreOrbsAllowed
|
||||
AreOrbsAllowed: ; 0x023440AC
|
||||
cmp r0, #0
|
||||
beq _023440BC
|
||||
cmp r0, #0xa5
|
||||
blo _023440C4
|
||||
_023440BC:
|
||||
mov r0, #1
|
||||
bx lr
|
||||
_023440C4:
|
||||
mov r1, #0xc
|
||||
mul r1, r0, r1
|
||||
ldr r0, _023440D8 ; =ov10_022C6C77
|
||||
ldrb r0, [r0, r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_023440D8: .word ov10_022C6C77
|
||||
arm_func_end AreOrbsAllowed
|
||||
|
||||
arm_func_start AreTileJumpsAllowed
|
||||
AreTileJumpsAllowed: ; 0x023440DC
|
||||
cmp r0, #0
|
||||
beq _023440EC
|
||||
cmp r0, #0xa5
|
||||
blo _023440F4
|
||||
_023440EC:
|
||||
mov r0, #1
|
||||
bx lr
|
||||
_023440F4:
|
||||
mov r1, #0xc
|
||||
mul r1, r0, r1
|
||||
ldr r0, _02344108 ; =ov10_022C6C78
|
||||
ldrb r0, [r0, r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02344108: .word ov10_022C6C78
|
||||
arm_func_end AreTileJumpsAllowed
|
||||
|
||||
arm_func_start AreTrawlOrbsAllowed
|
||||
AreTrawlOrbsAllowed: ; 0x0234410C
|
||||
cmp r0, #0
|
||||
beq _0234411C
|
||||
cmp r0, #0xa5
|
||||
blo _02344124
|
||||
_0234411C:
|
||||
mov r0, #1
|
||||
bx lr
|
||||
_02344124:
|
||||
mov r1, #0xc
|
||||
mul r1, r0, r1
|
||||
ldr r0, _02344138 ; =ov10_022C6C79
|
||||
ldrb r0, [r0, r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02344138: .word ov10_022C6C79
|
||||
arm_func_end AreTrawlOrbsAllowed
|
||||
|
||||
arm_func_start AreOrbsAllowedVeneer
|
||||
AreOrbsAllowedVeneer: ; 0x0234413C
|
||||
ldr ip, _02344144 ; =AreOrbsAllowed
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02344144: .word AreOrbsAllowed
|
||||
arm_func_end AreOrbsAllowedVeneer
|
||||
|
||||
arm_func_start AreLateGameTrapsEnabled
|
||||
AreLateGameTrapsEnabled: ; 0x02344148
|
||||
mov r1, #0xc
|
||||
mul r1, r0, r1
|
||||
ldr r0, _0234415C ; =ov10_022C6C75
|
||||
ldrb r0, [r0, r1]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_0234415C: .word ov10_022C6C75
|
||||
arm_func_end AreLateGameTrapsEnabled
|
||||
|
||||
@@ -1,89 +0,0 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "overlay_29_02344B1C.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start ov29_02344B1C
|
||||
ov29_02344B1C: ; 0x02344B1C
|
||||
ldr r0, _02344B2C ; =ov29_023537B0
|
||||
mov r1, #1
|
||||
strb r1, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02344B2C: .word ov29_023537B0
|
||||
arm_func_end ov29_02344B1C
|
||||
|
||||
arm_func_start ov29_02344B30
|
||||
ov29_02344B30: ; 0x02344B30
|
||||
ldr r0, _02344B40 ; =ov29_023537B0
|
||||
mov r1, #0
|
||||
strb r1, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_02344B40: .word ov29_023537B0
|
||||
arm_func_end ov29_02344B30
|
||||
|
||||
arm_func_start PrepareItemForPrinting__02345728
|
||||
PrepareItemForPrinting__02345728: ; 0x02344B44
|
||||
stmdb sp!, {r3, r4, r5, lr}
|
||||
mov r5, r0
|
||||
mov r4, r1
|
||||
orr r1, r5, #0x40000
|
||||
bl SetPreprocessorArgsIdVal
|
||||
ldr r2, _02344B6C ; =ov29_023531BC
|
||||
mov r0, r5
|
||||
mov r1, r4
|
||||
bl SubstitutePlaceholderItemTags
|
||||
ldmia sp!, {r3, r4, r5, pc}
|
||||
.align 2, 0
|
||||
_02344B6C: .word ov29_023531BC
|
||||
arm_func_end PrepareItemForPrinting__02345728
|
||||
|
||||
arm_func_start PrepareItemForPrinting__02345754
|
||||
PrepareItemForPrinting__02345754: ; 0x02344B70
|
||||
stmdb sp!, {r3, r4, r5, lr}
|
||||
mov r5, r0
|
||||
mov r4, r1
|
||||
orr r1, r5, #0x40000
|
||||
bl SetPreprocessorArgsIdVal
|
||||
ldr r2, _02344B98 ; =ov29_023531A4
|
||||
mov r0, r5
|
||||
mov r1, r4
|
||||
bl SubstitutePlaceholderItemTags
|
||||
ldmia sp!, {r3, r4, r5, pc}
|
||||
.align 2, 0
|
||||
_02344B98: .word ov29_023531A4
|
||||
arm_func_end PrepareItemForPrinting__02345754
|
||||
|
||||
arm_func_start ov29_02344B9C
|
||||
ov29_02344B9C: ; 0x02344B9C
|
||||
ldr ip, _02344BA4 ; =SetPreprocessorArgsIdVal
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02344BA4: .word SetPreprocessorArgsIdVal
|
||||
arm_func_end ov29_02344B9C
|
||||
|
||||
arm_func_start PrepareItemForPrinting2
|
||||
PrepareItemForPrinting2: ; 0x02344BA8
|
||||
stmdb sp!, {r3, lr}
|
||||
add r3, r0, r1, lsl #2
|
||||
orr ip, r1, #0x40000
|
||||
mov r0, r1
|
||||
mov r1, r2
|
||||
ldr r2, _02344BCC ; =ov29_023531BC
|
||||
str ip, [r3, #0x10]
|
||||
bl SubstitutePlaceholderItemTags
|
||||
ldmia sp!, {r3, pc}
|
||||
.align 2, 0
|
||||
_02344BCC: .word ov29_023531BC
|
||||
arm_func_end PrepareItemForPrinting2
|
||||
|
||||
arm_func_start GenerateStandardItem
|
||||
GenerateStandardItem: ; 0x02344BD0
|
||||
ldr ip, _02344BE0 ; =GenerateItem
|
||||
mov r3, r2
|
||||
mov r2, #0
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02344BE0: .word GenerateItem
|
||||
arm_func_end GenerateStandardItem
|
||||
36
asm/overlay_29_02344B44.s
Normal file
36
asm/overlay_29_02344B44.s
Normal file
@@ -0,0 +1,36 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "overlay_29_02344B44.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start PrepareItemForPrinting__02345728
|
||||
PrepareItemForPrinting__02345728: ; 0x02344B44
|
||||
stmdb sp!, {r3, r4, r5, lr}
|
||||
mov r5, r0
|
||||
mov r4, r1
|
||||
orr r1, r5, #0x40000
|
||||
bl SetPreprocessorArgsIdVal
|
||||
ldr r2, _02344B6C ; =ov29_023531BC
|
||||
mov r0, r5
|
||||
mov r1, r4
|
||||
bl SubstitutePlaceholderItemTags
|
||||
ldmia sp!, {r3, r4, r5, pc}
|
||||
.align 2, 0
|
||||
_02344B6C: .word ov29_023531BC
|
||||
arm_func_end PrepareItemForPrinting__02345728
|
||||
|
||||
arm_func_start PrepareItemForPrinting__02345754
|
||||
PrepareItemForPrinting__02345754: ; 0x02344B70
|
||||
stmdb sp!, {r3, r4, r5, lr}
|
||||
mov r5, r0
|
||||
mov r4, r1
|
||||
orr r1, r5, #0x40000
|
||||
bl SetPreprocessorArgsIdVal
|
||||
ldr r2, _02344B98 ; =ov29_023531A4
|
||||
mov r0, r5
|
||||
mov r1, r4
|
||||
bl SubstitutePlaceholderItemTags
|
||||
ldmia sp!, {r3, r4, r5, pc}
|
||||
.align 2, 0
|
||||
_02344B98: .word ov29_023531A4
|
||||
arm_func_end PrepareItemForPrinting__02345754
|
||||
19
asm/overlay_29_02344BA8.s
Normal file
19
asm/overlay_29_02344BA8.s
Normal file
@@ -0,0 +1,19 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "overlay_29_02344BA8.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start PrepareItemForPrinting2
|
||||
PrepareItemForPrinting2: ; 0x02344BA8
|
||||
stmdb sp!, {r3, lr}
|
||||
add r3, r0, r1, lsl #2
|
||||
orr ip, r1, #0x40000
|
||||
mov r0, r1
|
||||
mov r1, r2
|
||||
ldr r2, _02344BCC ; =ov29_023531BC
|
||||
str ip, [r3, #0x10]
|
||||
bl SubstitutePlaceholderItemTags
|
||||
ldmia sp!, {r3, pc}
|
||||
.align 2, 0
|
||||
_02344BCC: .word ov29_023531BC
|
||||
arm_func_end PrepareItemForPrinting2
|
||||
17
include/main_02009BE8.h
Normal file
17
include/main_02009BE8.h
Normal file
@@ -0,0 +1,17 @@
|
||||
#ifndef PMDSKY_MAIN_02009BE8_H
|
||||
#define PMDSKY_MAIN_02009BE8_H
|
||||
|
||||
#include "util.h"
|
||||
|
||||
void sub_02009BE8(u32 value, s32 flag);
|
||||
void sub_02009C10(u32 value, s32 flag);
|
||||
void sub_02009C38(u32 value);
|
||||
void sub_02009C54(u32 value);
|
||||
void sub_02009C70(u32 value);
|
||||
void sub_02009C8C(u32 value);
|
||||
void sub_02009CA8(u32 value, s32 flag);
|
||||
void sub_02009CD0(u32 value, s32 flag);
|
||||
void sub_02009CF8(u32 value, s32 flag);
|
||||
void sub_02009D20(u32 value, s32 flag);
|
||||
|
||||
#endif
|
||||
@@ -1,6 +1,15 @@
|
||||
#ifndef PMDSKY_MAIN_02017C80_H
|
||||
#define PMDSKY_MAIN_02017C80_H
|
||||
|
||||
#include "util.h"
|
||||
|
||||
void PlaySeByIdVolumeWrapper(s32 se_id);
|
||||
void sub_02017C90(s32 a, s32 b, s32 c, s32 d);
|
||||
void sub_02017C9C(s32 a, s32 b, s32 c);
|
||||
void sub_02017CA8(s32 a, s32 b, s32 c);
|
||||
void sub_02017CB4(s32 a);
|
||||
void sub_02017CC0(s32 a, s32 b, s32 c, s32 d);
|
||||
void PlaySeVolumeWrapper(s32 idx);
|
||||
void sub_02017CEC(void);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,6 +1,16 @@
|
||||
#ifndef PMDSKY_MAIN_02030A40_H
|
||||
#define PMDSKY_MAIN_02030A40_H
|
||||
|
||||
struct unk_02030A50 {
|
||||
u8 field_0x0[0xC0];
|
||||
s32 field_0xC0;
|
||||
};
|
||||
|
||||
#include "util.h"
|
||||
|
||||
s32 GetAdvancedTextBoxFlags2(s32 window_id);
|
||||
void sub_02030A50(s32 window_id, s32 value);
|
||||
s32 sub_02030A64(s32 window_id);
|
||||
void sub_02030A74(s32 window_id, u32 flags);
|
||||
|
||||
#endif
|
||||
|
||||
21
include/main_020483B8.h
Normal file
21
include/main_020483B8.h
Normal file
@@ -0,0 +1,21 @@
|
||||
#ifndef PMDSKY_MAIN_020483B8_H
|
||||
#define PMDSKY_MAIN_020483B8_H
|
||||
|
||||
struct unk_020AFEF4 {
|
||||
u8 field_0x0[0x31B2];
|
||||
u8 field_0x31B2;
|
||||
u8 field_0x31B3[5];
|
||||
s16 field_0x31B8;
|
||||
};
|
||||
|
||||
#include "util.h"
|
||||
|
||||
void sub_020483B8(void);
|
||||
bool8 sub_020483D8(void);
|
||||
bool8 sub_02048400(void);
|
||||
void sub_02048420(void);
|
||||
void sub_02048430(void);
|
||||
void sub_02048454(void);
|
||||
bool8 sub_02048480(void);
|
||||
|
||||
#endif
|
||||
10
include/main_0204F9B8.h
Normal file
10
include/main_0204F9B8.h
Normal file
@@ -0,0 +1,10 @@
|
||||
#ifndef PMDSKY_MAIN_0204F9B8_H
|
||||
#define PMDSKY_MAIN_0204F9B8_H
|
||||
|
||||
#include "util.h"
|
||||
|
||||
void sub_0204F9B8(void);
|
||||
void sub_0204F9CC(void);
|
||||
s32 sub_0204F9E0(void);
|
||||
|
||||
#endif
|
||||
22
include/overlay_04_0233CA80.h
Normal file
22
include/overlay_04_0233CA80.h
Normal file
@@ -0,0 +1,22 @@
|
||||
#ifndef PMDSKY_OVERLAY_04_0233CA80_H
|
||||
#define PMDSKY_OVERLAY_04_0233CA80_H
|
||||
|
||||
struct unk_0233F660 {
|
||||
s32 field_0x0;
|
||||
s32 field_0x4;
|
||||
u8 field_0x8[4];
|
||||
u8 field_0xC;
|
||||
u8 field_0xD[3];
|
||||
};
|
||||
|
||||
#include "util.h"
|
||||
|
||||
void ov04_0233CA80(void);
|
||||
void ov04_0233CA98(s32 a);
|
||||
s32 ov04_0233CAA8(void);
|
||||
void ov04_0233CAB8(s32 a);
|
||||
s32 ov04_0233CAC8(void);
|
||||
void ov04_0233CAD8(u8 a);
|
||||
u8 ov04_0233CAE8(void);
|
||||
|
||||
#endif
|
||||
15
include/overlay_06_0233CA80.h
Normal file
15
include/overlay_06_0233CA80.h
Normal file
@@ -0,0 +1,15 @@
|
||||
#ifndef PMDSKY_OVERLAY_06_0233CA80_H
|
||||
#define PMDSKY_OVERLAY_06_0233CA80_H
|
||||
|
||||
struct unk_0233EEE0 {
|
||||
s32 field_0x0;
|
||||
u8 field_0x4[8];
|
||||
};
|
||||
|
||||
#include "util.h"
|
||||
|
||||
void ov06_0233CA80(void);
|
||||
void ov06_0233CA98(s32 a);
|
||||
s32 ov06_0233CAA8(void);
|
||||
|
||||
#endif
|
||||
13
include/overlay_29_02344088.h
Normal file
13
include/overlay_29_02344088.h
Normal file
@@ -0,0 +1,13 @@
|
||||
#ifndef PMDSKY_OVERLAY_29_02344088_H
|
||||
#define PMDSKY_OVERLAY_29_02344088_H
|
||||
|
||||
#include "util.h"
|
||||
|
||||
void CloseFixedBin(void);
|
||||
bool8 AreOrbsAllowed(u32 dungeon_id);
|
||||
bool8 AreTileJumpsAllowed(u32 dungeon_id);
|
||||
bool8 AreTrawlOrbsAllowed(u32 dungeon_id);
|
||||
bool8 AreOrbsAllowedVeneer(u32 dungeon_id);
|
||||
bool8 AreLateGameTrapsEnabled(u32 dungeon_id);
|
||||
|
||||
#endif
|
||||
@@ -1,9 +1,13 @@
|
||||
#ifndef PMDSKY_OVERLAY_29_02344AF8_H
|
||||
#define PMDSKY_OVERLAY_29_02344AF8_H
|
||||
|
||||
#include "util.h"
|
||||
|
||||
#include "dungeon_mode.h"
|
||||
|
||||
// Checks if an entity pointer points to a valid entity (not entity type 0, which represents no entity).
|
||||
bool8 EntityIsValid__02344AF8(struct entity *entity);
|
||||
void ov29_02344B1C(void);
|
||||
void ov29_02344B30(void);
|
||||
|
||||
#endif //PMDSKY_OVERLAY_29_02344AF8_H
|
||||
|
||||
8
include/overlay_29_02344B9C.h
Normal file
8
include/overlay_29_02344B9C.h
Normal file
@@ -0,0 +1,8 @@
|
||||
#ifndef PMDSKY_OVERLAY_29_02344B9C_H
|
||||
#define PMDSKY_OVERLAY_29_02344B9C_H
|
||||
|
||||
#include "util.h"
|
||||
|
||||
void ov29_02344B9C(s32 idx, u32 val);
|
||||
|
||||
#endif
|
||||
@@ -1,10 +1,13 @@
|
||||
#ifndef PMDSKY_OVERLAY_29_02344BE4_H
|
||||
#define PMDSKY_OVERLAY_29_02344BE4_H
|
||||
|
||||
#include "util.h"
|
||||
|
||||
#include "dungeon_mode.h"
|
||||
#include "item.h"
|
||||
#include "move.h"
|
||||
|
||||
void GenerateStandardItem(struct item* item, enum item_id item_id, s32 sticky);
|
||||
void GenerateCleanItem(struct item *item, enum item_id item_id);
|
||||
|
||||
#endif
|
||||
|
||||
19
main.lsf
19
main.lsf
@@ -44,6 +44,7 @@ Static main
|
||||
Object asm/main_02008BF4.o
|
||||
Object src/main_0200961C.o
|
||||
Object asm/main_02009648.o
|
||||
Object src/main_02009BE8.o
|
||||
Object src/main_02009D48.o
|
||||
Object src/main_02009F9C.o
|
||||
Object asm/main_0200A124.o
|
||||
@@ -118,7 +119,7 @@ Static main
|
||||
Object src/main_02017B58.o
|
||||
Object asm/main_02017B70.o
|
||||
Object src/main_02017C80.o
|
||||
Object asm/main_02017C90.o
|
||||
Object asm/main_02017D20.o
|
||||
Object src/main_0201BA9C.o
|
||||
Object asm/main_0201BAC8.o
|
||||
Object src/main_0201BFF0.o
|
||||
@@ -189,7 +190,7 @@ Static main
|
||||
Object asm/main_020308A0.o
|
||||
Object src/main_02030A18.o
|
||||
Object src/main_02030A40.o
|
||||
Object asm/main_02030A50.o
|
||||
Object asm/main_02030A90.o
|
||||
Object src/main_02032558.o
|
||||
Object src/main_0203258C.o
|
||||
Object asm/main_020325AC.o
|
||||
@@ -209,6 +210,7 @@ Static main
|
||||
Object src/main_02043380.o
|
||||
Object src/main_02043568.o
|
||||
Object asm/main_0204357C.o
|
||||
Object src/main_020483B8.o
|
||||
Object src/main_020484A0.o
|
||||
Object asm/main_020484C0.o
|
||||
Object src/main_02048758.o
|
||||
@@ -236,6 +238,8 @@ Static main
|
||||
Object src/dungeon_init.o
|
||||
Object src/main_0204F050.o
|
||||
Object asm/main_0204F0A0.o
|
||||
Object src/main_0204F9B8.o
|
||||
Object asm/main_0204F9F4.o
|
||||
Object src/main_0204FA24.o
|
||||
Object asm/main_0204FA70.o
|
||||
Object src/main_0204FB9C.o
|
||||
@@ -557,7 +561,8 @@ Overlay OVY_3
|
||||
Overlay OVY_4
|
||||
{
|
||||
After OVY_1
|
||||
Object asm/overlay_04.o
|
||||
Object src/overlay_04_0233CA80.o
|
||||
Object asm/overlay_04_0233CAF8.o
|
||||
}
|
||||
Overlay OVY_5
|
||||
{
|
||||
@@ -567,7 +572,8 @@ Overlay OVY_5
|
||||
Overlay OVY_6
|
||||
{
|
||||
After OVY_1
|
||||
Object asm/overlay_06.o
|
||||
Object src/overlay_06_0233CA80.o
|
||||
Object asm/overlay_06_0233CAB8.o
|
||||
}
|
||||
Overlay OVY_7
|
||||
{
|
||||
@@ -1182,10 +1188,13 @@ Overlay OVY_29
|
||||
Object asm/overlay_29_02341E6C.o
|
||||
Object src/overlay_29_0234396C.o
|
||||
Object asm/overlay_29_02343980.o
|
||||
Object src/overlay_29_02344088.o
|
||||
Object src/fixed_room_data.o
|
||||
Object asm/overlay_29_02344178.o
|
||||
Object src/overlay_29_02344AF8.o
|
||||
Object asm/overlay_29_02344B1C.o
|
||||
Object asm/overlay_29_02344B44.o
|
||||
Object src/overlay_29_02344B9C.o
|
||||
Object asm/overlay_29_02344BA8.o
|
||||
Object src/overlay_29_02344BE4.o
|
||||
Object asm/overlay_29_02344BF8.o
|
||||
Object src/overlay_29_02345698.o
|
||||
|
||||
87
src/main_02009BE8.c
Normal file
87
src/main_02009BE8.c
Normal file
@@ -0,0 +1,87 @@
|
||||
#include "main_02009BE8.h"
|
||||
|
||||
void sub_02009BE8(u32 value, s32 flag)
|
||||
{
|
||||
u32 v = (*(vu16 *) 0x0400004A & ~0x3F00) | (value << 8);
|
||||
|
||||
if (flag != 0) {
|
||||
v |= 0x2000;
|
||||
}
|
||||
|
||||
*(vu16 *) 0x0400004A = v;
|
||||
}
|
||||
|
||||
void sub_02009C10(u32 value, s32 flag)
|
||||
{
|
||||
u32 v = (*(vu16 *) 0x0400004A & ~0x3F) | (value);
|
||||
|
||||
if (flag != 0) {
|
||||
v |= 0x20;
|
||||
}
|
||||
|
||||
*(vu16 *) 0x0400004A = v;
|
||||
}
|
||||
|
||||
void sub_02009C38(u32 value)
|
||||
{
|
||||
*(vu16 *) 0x0400000A = (*(vu16 *) 0x0400000A & ~3) | value;
|
||||
}
|
||||
|
||||
void sub_02009C54(u32 value)
|
||||
{
|
||||
*(vu16 *) 0x04000008 = (*(vu16 *) 0x04000008 & ~3) | value;
|
||||
}
|
||||
|
||||
void sub_02009C70(u32 value)
|
||||
{
|
||||
*(vu16 *) 0x0400000C = (*(vu16 *) 0x0400000C & ~3) | value;
|
||||
}
|
||||
|
||||
void sub_02009C8C(u32 value)
|
||||
{
|
||||
*(vu16 *) 0x0400000E = (*(vu16 *) 0x0400000E & ~3) | value;
|
||||
}
|
||||
|
||||
void sub_02009CA8(u32 value, s32 flag)
|
||||
{
|
||||
u32 v = (*(vu16 *) 0x04001048 & ~0x3F) | (value);
|
||||
|
||||
if (flag != 0) {
|
||||
v |= 0x20;
|
||||
}
|
||||
|
||||
*(vu16 *) 0x04001048 = v;
|
||||
}
|
||||
|
||||
void sub_02009CD0(u32 value, s32 flag)
|
||||
{
|
||||
u32 v = (*(vu16 *) 0x04001048 & ~0x3F00) | (value << 8);
|
||||
|
||||
if (flag != 0) {
|
||||
v |= 0x2000;
|
||||
}
|
||||
|
||||
*(vu16 *) 0x04001048 = v;
|
||||
}
|
||||
|
||||
void sub_02009CF8(u32 value, s32 flag)
|
||||
{
|
||||
u32 v = (*(vu16 *) 0x0400104A & ~0x3F00) | (value << 8);
|
||||
|
||||
if (flag != 0) {
|
||||
v |= 0x2000;
|
||||
}
|
||||
|
||||
*(vu16 *) 0x0400104A = v;
|
||||
}
|
||||
|
||||
void sub_02009D20(u32 value, s32 flag)
|
||||
{
|
||||
u32 v = (*(vu16 *) 0x0400104A & ~0x3F) | (value);
|
||||
|
||||
if (flag != 0) {
|
||||
v |= 0x20;
|
||||
}
|
||||
|
||||
*(vu16 *) 0x0400104A = v;
|
||||
}
|
||||
@@ -1,4 +1,19 @@
|
||||
#include "main_02017C80.h"
|
||||
#include "main_0202AAA8.h"
|
||||
|
||||
extern u16 _0209915C[];
|
||||
|
||||
extern s16 _022A4BE8;
|
||||
|
||||
extern void sub_0201831C(s32 a, s32 b, s32 c, s32 d);
|
||||
|
||||
extern void sub_020183A0(s32 a, s32 b, s32 c);
|
||||
|
||||
extern void sub_020183E4(s32 a, s32 b, s32 c);
|
||||
|
||||
extern void sub_02018428(s32 a);
|
||||
|
||||
extern void sub_02018460(s32 a, s32 b, s32 c, s32 d);
|
||||
|
||||
void PlaySeByIdVolume(s32 se_id, s32 volume);
|
||||
|
||||
@@ -6,3 +21,43 @@ void PlaySeByIdVolumeWrapper(s32 se_id)
|
||||
{
|
||||
PlaySeByIdVolume(se_id, 0x100);
|
||||
}
|
||||
|
||||
void sub_02017C90(s32 a, s32 b, s32 c, s32 d)
|
||||
{
|
||||
sub_0201831C(a, b, c, d);
|
||||
}
|
||||
|
||||
void sub_02017C9C(s32 a, s32 b, s32 c)
|
||||
{
|
||||
sub_020183A0(a, b, c);
|
||||
}
|
||||
|
||||
void sub_02017CA8(s32 a, s32 b, s32 c)
|
||||
{
|
||||
sub_020183E4(a, b, c);
|
||||
}
|
||||
|
||||
void sub_02017CB4(s32 a)
|
||||
{
|
||||
sub_02018428(a);
|
||||
}
|
||||
|
||||
void sub_02017CC0(s32 a, s32 b, s32 c, s32 d)
|
||||
{
|
||||
sub_02018460(a, b, c, d);
|
||||
}
|
||||
|
||||
void PlaySeVolumeWrapper(s32 idx)
|
||||
{
|
||||
PlaySeByIdVolume(_0209915C[idx], 0x100);
|
||||
}
|
||||
|
||||
void sub_02017CEC(void)
|
||||
{
|
||||
if (_022A4BE8 > 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
_022A4BE8 = 3;
|
||||
PlaySeByIdVolume(0x3F05, 0x100);
|
||||
}
|
||||
|
||||
@@ -1,9 +1,34 @@
|
||||
#include "main_02030A40.h"
|
||||
#include "main_0202AAA8.h"
|
||||
|
||||
extern void sub_02031C74(void *p, u32 flags);
|
||||
|
||||
#include "main_0202AAA8.h"
|
||||
|
||||
s32 GetAdvancedTextBoxFlags2(s32 window_id)
|
||||
{
|
||||
struct unk_0202AAA8 *w = GetWindowContents(window_id);
|
||||
|
||||
return w->field_0x1B0;
|
||||
}
|
||||
|
||||
void sub_02030A50(s32 window_id, s32 value)
|
||||
{
|
||||
struct unk_02030A50 *w = GetWindowContents(window_id);
|
||||
|
||||
w->field_0xC0 = value;
|
||||
}
|
||||
|
||||
s32 sub_02030A64(s32 window_id)
|
||||
{
|
||||
struct unk_02030A50 *w = GetWindowContents(window_id);
|
||||
|
||||
return w->field_0xC0;
|
||||
}
|
||||
|
||||
void sub_02030A74(s32 window_id, u32 flags)
|
||||
{
|
||||
struct unk_02030A50 *w = GetWindowContents(window_id);
|
||||
|
||||
sub_02031C74((void *) w + 4, flags);
|
||||
}
|
||||
|
||||
78
src/main_020483B8.c
Normal file
78
src/main_020483B8.c
Normal file
@@ -0,0 +1,78 @@
|
||||
#include "main_020483B8.h"
|
||||
#include "script_variable.h"
|
||||
|
||||
extern struct unk_020AFEF4 *_020AFEF4;
|
||||
|
||||
extern void sub_020476EC(s16 a);
|
||||
|
||||
extern bool8 sub_0204771C(void);
|
||||
|
||||
extern void sub_02048B74(void);
|
||||
|
||||
extern void sub_02048B48(void);
|
||||
|
||||
extern void sub_0206637C(void);
|
||||
|
||||
extern void sub_02048C0C(s32 a);
|
||||
|
||||
extern void sub_02048C4C(s32 a);
|
||||
|
||||
extern void sub_02048C5C(void);
|
||||
|
||||
extern s32 sub_02048C3C(void);
|
||||
|
||||
extern void ClearAdventureLogStruct(void);
|
||||
|
||||
extern void sub_0204F9B8(void);
|
||||
|
||||
void sub_020483B8(void)
|
||||
{
|
||||
sub_020476EC(_020AFEF4->field_0x31B8);
|
||||
}
|
||||
|
||||
bool8 sub_020483D8(void)
|
||||
{
|
||||
bool8 ok = sub_0204771C();
|
||||
|
||||
if (ok) {
|
||||
_020AFEF4->field_0x31B2 = 0;
|
||||
}
|
||||
|
||||
return ok;
|
||||
}
|
||||
|
||||
bool8 sub_02048400(void)
|
||||
{
|
||||
return _020AFEF4 != NULL;
|
||||
}
|
||||
|
||||
void sub_02048420(void)
|
||||
{
|
||||
DebugPrintEventFlagSize();
|
||||
sub_02048B74();
|
||||
}
|
||||
|
||||
void sub_02048430(void)
|
||||
{
|
||||
sub_0206637C();
|
||||
sub_02048C0C(0);
|
||||
sub_02048C4C(-1);
|
||||
sub_0204F9B8();
|
||||
sub_02048B48();
|
||||
}
|
||||
|
||||
void sub_02048454(void)
|
||||
{
|
||||
ClearAdventureLogStruct();
|
||||
sub_0206637C();
|
||||
sub_02048C0C(0);
|
||||
sub_02048C4C(-1);
|
||||
sub_0204F9B8();
|
||||
sub_02048B48();
|
||||
sub_02048C5C();
|
||||
}
|
||||
|
||||
bool8 sub_02048480(void)
|
||||
{
|
||||
return sub_02048C3C() != -1;
|
||||
}
|
||||
27
src/main_0204F9B8.c
Normal file
27
src/main_0204F9B8.c
Normal file
@@ -0,0 +1,27 @@
|
||||
#include "main_0204F9B8.h"
|
||||
#include "script_variable.h"
|
||||
|
||||
extern u8 PLAY_TIME_SECONDS[];
|
||||
|
||||
extern void sub_0204F9B8(void);
|
||||
|
||||
extern void ResetPlayTimer(u8 *timer);
|
||||
|
||||
extern void PlayTimerTick(u8 *timer);
|
||||
|
||||
extern s32 GetPlayTimeSeconds(u8 *timer);
|
||||
|
||||
void sub_0204F9B8(void)
|
||||
{
|
||||
ResetPlayTimer(PLAY_TIME_SECONDS);
|
||||
}
|
||||
|
||||
void sub_0204F9CC(void)
|
||||
{
|
||||
PlayTimerTick(PLAY_TIME_SECONDS);
|
||||
}
|
||||
|
||||
s32 sub_0204F9E0(void)
|
||||
{
|
||||
return GetPlayTimeSeconds(PLAY_TIME_SECONDS);
|
||||
}
|
||||
39
src/overlay_04_0233CA80.c
Normal file
39
src/overlay_04_0233CA80.c
Normal file
@@ -0,0 +1,39 @@
|
||||
#include "overlay_04_0233CA80.h"
|
||||
#include "main_0200330C.h"
|
||||
|
||||
extern struct unk_0233F660 ov04_0233F660;
|
||||
|
||||
void ov04_0233CA80(void)
|
||||
{
|
||||
MemZero((u8 *) &ov04_0233F660, 0x10);
|
||||
}
|
||||
|
||||
void ov04_0233CA98(s32 a)
|
||||
{
|
||||
ov04_0233F660.field_0x0 = a;
|
||||
}
|
||||
|
||||
s32 ov04_0233CAA8(void)
|
||||
{
|
||||
return ov04_0233F660.field_0x0;
|
||||
}
|
||||
|
||||
void ov04_0233CAB8(s32 a)
|
||||
{
|
||||
ov04_0233F660.field_0x4 = a;
|
||||
}
|
||||
|
||||
s32 ov04_0233CAC8(void)
|
||||
{
|
||||
return ov04_0233F660.field_0x4;
|
||||
}
|
||||
|
||||
void ov04_0233CAD8(u8 a)
|
||||
{
|
||||
ov04_0233F660.field_0xC = a;
|
||||
}
|
||||
|
||||
u8 ov04_0233CAE8(void)
|
||||
{
|
||||
return ov04_0233F660.field_0xC;
|
||||
}
|
||||
19
src/overlay_06_0233CA80.c
Normal file
19
src/overlay_06_0233CA80.c
Normal file
@@ -0,0 +1,19 @@
|
||||
#include "overlay_06_0233CA80.h"
|
||||
#include "main_0200330C.h"
|
||||
|
||||
extern struct unk_0233EEE0 ov06_0233EEE0;
|
||||
|
||||
void ov06_0233CA80(void)
|
||||
{
|
||||
MemZero((u8 *) &ov06_0233EEE0, 0xC);
|
||||
}
|
||||
|
||||
void ov06_0233CA98(s32 a)
|
||||
{
|
||||
ov06_0233EEE0.field_0x0 = a;
|
||||
}
|
||||
|
||||
s32 ov06_0233CAA8(void)
|
||||
{
|
||||
return ov06_0233EEE0.field_0x0;
|
||||
}
|
||||
56
src/overlay_29_02344088.c
Normal file
56
src/overlay_29_02344088.c
Normal file
@@ -0,0 +1,56 @@
|
||||
#include "overlay_29_02344088.h"
|
||||
#include "main_02001188.h"
|
||||
#include "overlay_29_0234B024.h"
|
||||
|
||||
extern u8 ov10_022C6C75[];
|
||||
|
||||
extern u8 ov10_022C6C77[];
|
||||
|
||||
extern u8 ov10_022C6C78[];
|
||||
|
||||
extern u8 ov10_022C6C79[];
|
||||
|
||||
extern void *FIXED_ROOM_DATA_PTR;
|
||||
|
||||
void CloseFixedBin(void)
|
||||
{
|
||||
MemFree(FIXED_ROOM_DATA_PTR);
|
||||
FIXED_ROOM_DATA_PTR = NULL;
|
||||
}
|
||||
|
||||
bool8 AreOrbsAllowed(u32 dungeon_id)
|
||||
{
|
||||
if (dungeon_id == 0 || dungeon_id >= 0xA5) {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
return ov10_022C6C77[dungeon_id * 12];
|
||||
}
|
||||
|
||||
bool8 AreTileJumpsAllowed(u32 dungeon_id)
|
||||
{
|
||||
if (dungeon_id == 0 || dungeon_id >= 0xA5) {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
return ov10_022C6C78[dungeon_id * 12];
|
||||
}
|
||||
|
||||
bool8 AreTrawlOrbsAllowed(u32 dungeon_id)
|
||||
{
|
||||
if (dungeon_id == 0 || dungeon_id >= 0xA5) {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
return ov10_022C6C79[dungeon_id * 12];
|
||||
}
|
||||
|
||||
bool8 AreOrbsAllowedVeneer(u32 dungeon_id)
|
||||
{
|
||||
return AreOrbsAllowed(dungeon_id);
|
||||
}
|
||||
|
||||
bool8 AreLateGameTrapsEnabled(u32 dungeon_id)
|
||||
{
|
||||
return ov10_022C6C75[dungeon_id * 12];
|
||||
}
|
||||
@@ -1,4 +1,9 @@
|
||||
#include "overlay_29_02344AF8.h"
|
||||
#include "main_02001188.h"
|
||||
#include "overlay_29_0234B024.h"
|
||||
|
||||
extern bool8 ov29_023537B0;
|
||||
|
||||
#include "dungeon_util_static.h"
|
||||
|
||||
bool8 EntityIsValid__02344AF8(struct entity *entity)
|
||||
@@ -8,3 +13,13 @@ bool8 EntityIsValid__02344AF8(struct entity *entity)
|
||||
|
||||
return GetEntityType(entity) != ENTITY_NOTHING;
|
||||
}
|
||||
|
||||
void ov29_02344B1C(void)
|
||||
{
|
||||
ov29_023537B0 = TRUE;
|
||||
}
|
||||
|
||||
void ov29_02344B30(void)
|
||||
{
|
||||
ov29_023537B0 = FALSE;
|
||||
}
|
||||
|
||||
8
src/overlay_29_02344B9C.c
Normal file
8
src/overlay_29_02344B9C.c
Normal file
@@ -0,0 +1,8 @@
|
||||
#include "overlay_29_02344B9C.h"
|
||||
#include "main_02001188.h"
|
||||
#include "overlay_29_0234B024.h"
|
||||
|
||||
void ov29_02344B9C(s32 idx, u32 val)
|
||||
{
|
||||
SetPreprocessorArgsIdVal(idx, val);
|
||||
}
|
||||
@@ -1,7 +1,14 @@
|
||||
#include "overlay_29_02344BE4.h"
|
||||
#include "main_02001188.h"
|
||||
#include "overlay_29_0234B024.h"
|
||||
|
||||
extern void GenerateItem(struct item *item, enum item_id item_id, s32 quantity, s32 sticky);
|
||||
|
||||
void GenerateStandardItem(struct item* item, enum item_id item_id, s32 sticky)
|
||||
{
|
||||
GenerateItem(item, item_id, 0, sticky);
|
||||
}
|
||||
|
||||
void GenerateCleanItem(struct item *item, enum item_id item_id)
|
||||
{
|
||||
GenerateItem(item, item_id, 0, 2);
|
||||
|
||||
Reference in New Issue
Block a user