mirror of
https://github.com/pret/pokeheartgold.git
synced 2025-01-18 19:13:12 +00:00
Name and mark bag, itemtool, bag_view
This commit is contained in:
parent
0014fa3246
commit
e42eb674d3
@ -7466,7 +7466,7 @@ _022579AE:
|
||||
add r1, #0x38
|
||||
ldrh r1, [r2, r1]
|
||||
mov r2, #0xb
|
||||
bl sub_02078550
|
||||
bl Bag_GetQuantity
|
||||
pop {r4, pc}
|
||||
_022579C0:
|
||||
cmp r4, #2
|
||||
@ -9237,7 +9237,7 @@ ov03_02258764: ; 0x02258764
|
||||
bl Sav2_Bag_get
|
||||
ldr r1, _022587C8 ; =0x022597F0
|
||||
mov r2, #0xb
|
||||
bl sub_02078644
|
||||
bl CreateBagView
|
||||
str r0, [r4, #4]
|
||||
mov r0, #0x43
|
||||
lsl r0, r0, #2
|
||||
|
@ -15508,7 +15508,7 @@ _02223C0A:
|
||||
lsl r2, r2, #0x10
|
||||
ldr r1, [sp, #8]
|
||||
lsr r2, r2, #0x10
|
||||
bl sub_02078724
|
||||
bl Bag_GetPocketSlotN
|
||||
add r5, r0, #0
|
||||
beq _02223C7C
|
||||
ldrh r0, [r5]
|
||||
|
@ -1416,7 +1416,7 @@ _022384D6:
|
||||
lsl r1, r1, #2
|
||||
ldr r0, [r4, #0x58]
|
||||
ldr r1, [r7, r1]
|
||||
bl sub_020781B4
|
||||
bl Sav2_Bag_copy
|
||||
ldr r0, [r4, #0x58]
|
||||
bl FreeToHeap
|
||||
mov r1, #0x11
|
||||
@ -2080,14 +2080,14 @@ _02238AB8:
|
||||
sub r1, #0x28
|
||||
str r0, [r4, r1]
|
||||
mov r0, #5
|
||||
bl sub_02078188
|
||||
bl Sav2_Bag_new
|
||||
str r0, [r4, #0x58]
|
||||
mov r1, #0x42
|
||||
ldr r0, [sp, #4]
|
||||
lsl r1, r1, #2
|
||||
ldr r0, [r0, r1]
|
||||
ldr r1, [r4, #0x58]
|
||||
bl sub_020781B4
|
||||
bl Sav2_Bag_copy
|
||||
mov r0, #5
|
||||
bl sub_020293E8
|
||||
str r0, [r4, #0x60]
|
||||
@ -7434,7 +7434,7 @@ _0223B474:
|
||||
ldr r0, [sp, #4]
|
||||
ldr r1, [sp, #0x18]
|
||||
bl ov12_0223AA88
|
||||
bl sub_020780BC
|
||||
bl BallToItemId
|
||||
cmp r0, #0xb
|
||||
bne _0223B492
|
||||
ldr r0, [sp, #8]
|
||||
@ -14811,7 +14811,7 @@ ov12_0223EB88: ; 0x0223EB88
|
||||
ldr r0, [r4, r1]
|
||||
lsl r0, r0, #0x10
|
||||
lsr r0, r0, #0x10
|
||||
bl sub_0207809C
|
||||
bl ItemToBallId
|
||||
mov r1, #0x5e
|
||||
lsl r1, r1, #2
|
||||
ldr r2, [r4, r1]
|
||||
@ -34479,7 +34479,7 @@ ov12_02248660: ; 0x02248660
|
||||
add r0, r4, r0
|
||||
bl LoadAllWazaTbl
|
||||
mov r0, #5
|
||||
bl sub_02078138
|
||||
bl LoadAllItemData
|
||||
ldr r1, _022486AC ; =0x00002120
|
||||
str r0, [r4, r1]
|
||||
add r0, r4, #0
|
||||
@ -62909,7 +62909,7 @@ _02255EE2:
|
||||
ldr r0, _02255F78 ; =0x00002DB8
|
||||
add r1, r4, r1
|
||||
ldrh r0, [r1, r0]
|
||||
bl sub_020780E4
|
||||
bl ItemIdIsBerry
|
||||
cmp r0, #1
|
||||
bne _02255EF8
|
||||
mov r6, #1
|
||||
@ -64113,7 +64113,7 @@ ov12_022567D4: ; 0x022567D4
|
||||
add r0, r5, #0
|
||||
add r1, r6, #0
|
||||
bl ov12_0223AA88
|
||||
bl sub_020780BC
|
||||
bl BallToItemId
|
||||
add r2, r0, #0
|
||||
b _02256818
|
||||
_02256814:
|
||||
@ -67005,7 +67005,7 @@ ov12_02257E74: ; 0x02257E74
|
||||
add r1, r0, #0
|
||||
ldr r0, _02257E94 ; =0x00002120
|
||||
ldr r0, [r5, r0]
|
||||
bl sub_02078160
|
||||
bl GetItemDataPtrFromArray
|
||||
add r1, r4, #0
|
||||
bl GetItemAttr_PreloadedItemData
|
||||
pop {r3, r4, r5, pc}
|
||||
|
@ -6648,7 +6648,7 @@ ov14_021E8ACC: ; 0x021E8ACC
|
||||
bl Sav2_Bag_get
|
||||
ldr r1, _021E8B10 ; =0x021F7D14
|
||||
mov r2, #9
|
||||
bl sub_02078644
|
||||
bl CreateBagView
|
||||
str r0, [r4, #0x18]
|
||||
ldr r1, [r4]
|
||||
mov r2, #1
|
||||
|
@ -3978,7 +3978,7 @@ _021FB280:
|
||||
ldr r0, [r4, r0]
|
||||
add r0, #0x66
|
||||
ldrh r0, [r0]
|
||||
bl sub_02078168
|
||||
bl ItemIdIsNotApricornBall
|
||||
cmp r0, #1
|
||||
bne _021FB2A4
|
||||
mov r1, #8
|
||||
@ -3999,7 +3999,7 @@ _021FB2AE:
|
||||
mov r0, #0x8e
|
||||
lsl r0, r0, #2
|
||||
ldr r0, [r4, r0]
|
||||
bl sub_020781C4
|
||||
bl Bag_GetRegisteredItemSlot1
|
||||
mov r1, #0x8d
|
||||
lsl r1, r1, #2
|
||||
ldr r2, [r4, r1]
|
||||
@ -4009,7 +4009,7 @@ _021FB2AE:
|
||||
beq _021FB2E8
|
||||
add r0, r1, #4
|
||||
ldr r0, [r4, r0]
|
||||
bl sub_020781D0
|
||||
bl Bag_GetRegisteredItemSlot2
|
||||
mov r1, #0x8d
|
||||
lsl r1, r1, #2
|
||||
ldr r1, [r4, r1]
|
||||
@ -4622,7 +4622,7 @@ _021FB7B0:
|
||||
ldrh r2, [r2]
|
||||
ldr r1, [r4, r1]
|
||||
mov r3, #6
|
||||
bl sub_02077980
|
||||
bl TryFormatRegisteredKeyItemUseMessage
|
||||
cmp r0, #1
|
||||
bne _021FB7D6
|
||||
add r0, r4, #0
|
||||
@ -5061,7 +5061,7 @@ ov15_021FBB28: ; 0x021FBB28
|
||||
ldrb r1, [r1, #0xd]
|
||||
ldrh r2, [r2]
|
||||
ldrh r3, [r4, r3]
|
||||
bl sub_02078480
|
||||
bl Pocket_TakeItem
|
||||
add r0, r4, #0
|
||||
bl ov15_021F9F08
|
||||
mov r0, #0x8d
|
||||
@ -5250,7 +5250,7 @@ ov15_021FBCAC: ; 0x021FBCAC
|
||||
ldr r0, [r1, #4]
|
||||
ldrb r1, [r1, #0xd]
|
||||
ldrh r2, [r2]
|
||||
bl sub_02078568
|
||||
bl Pocket_GetQuantity
|
||||
cmp r0, #1
|
||||
bne _021FBCF2
|
||||
add r0, r4, #0
|
||||
@ -5869,7 +5869,7 @@ _021FC186:
|
||||
ldrb r1, [r1, #0xd]
|
||||
ldrh r2, [r2]
|
||||
ldrh r3, [r5, r3]
|
||||
bl sub_02078480
|
||||
bl Pocket_TakeItem
|
||||
add r0, r5, #0
|
||||
bl ov15_021F9F08
|
||||
mov r0, #0x8d
|
||||
@ -5920,7 +5920,7 @@ ov15_021FC224: ; 0x021FC224
|
||||
ldr r1, [r5, r1]
|
||||
add r1, #0x66
|
||||
ldrh r1, [r1]
|
||||
bl sub_020781DC
|
||||
bl Bag_TryRegisterItem
|
||||
cmp r0, #0
|
||||
bne _021FC28C
|
||||
mov r0, #0x2f
|
||||
@ -6070,7 +6070,7 @@ ov15_021FC37C: ; 0x021FC37C
|
||||
ldr r1, [r5, r1]
|
||||
add r1, #0x66
|
||||
ldrh r1, [r1]
|
||||
bl sub_02078208
|
||||
bl Bag_UnregisterItem
|
||||
add r0, r5, #0
|
||||
bl ov15_02200294
|
||||
add r0, r5, #0
|
||||
@ -6488,7 +6488,7 @@ _021FC6B4:
|
||||
ldr r0, [r5, r0]
|
||||
add r0, #0x66
|
||||
ldrh r0, [r0]
|
||||
bl sub_02078168
|
||||
bl ItemIdIsNotApricornBall
|
||||
cmp r0, #0
|
||||
bne _021FC75C
|
||||
_021FC6E4:
|
||||
@ -7203,7 +7203,7 @@ _021FCC7C:
|
||||
ldr r0, [r1, #4]
|
||||
ldrb r1, [r1, #0xd]
|
||||
ldrh r2, [r2]
|
||||
bl sub_02078568
|
||||
bl Pocket_GetQuantity
|
||||
cmp r0, #1
|
||||
bne _021FCD0C
|
||||
mov r0, #0x2f
|
||||
@ -7944,7 +7944,7 @@ _021FD2B4:
|
||||
ldrb r1, [r1, #0xd]
|
||||
ldrh r2, [r2]
|
||||
ldrh r3, [r4, r3]
|
||||
bl sub_02078480
|
||||
bl Pocket_TakeItem
|
||||
add r0, r4, #0
|
||||
bl ov15_021F9F08
|
||||
add r4, #0x34
|
||||
@ -12326,7 +12326,7 @@ _021FF5D8:
|
||||
mov r0, #0x8e
|
||||
lsl r0, r0, #2
|
||||
ldr r0, [r5, r0]
|
||||
bl sub_020781C4
|
||||
bl Bag_GetRegisteredItemSlot1
|
||||
ldr r1, [r4]
|
||||
ldrh r1, [r1, r7]
|
||||
cmp r1, r0
|
||||
@ -12340,7 +12340,7 @@ _021FF610:
|
||||
mov r0, #0x8e
|
||||
lsl r0, r0, #2
|
||||
ldr r0, [r5, r0]
|
||||
bl sub_020781D0
|
||||
bl Bag_GetRegisteredItemSlot2
|
||||
ldr r1, [r4]
|
||||
ldrh r1, [r1, r7]
|
||||
cmp r1, r0
|
||||
|
@ -720,7 +720,7 @@ _022018FA:
|
||||
add r0, r6, #0
|
||||
lsr r1, r1, #0x10
|
||||
add r2, r7, #0
|
||||
bl sub_02078550
|
||||
bl Bag_GetQuantity
|
||||
add r0, r5, r0
|
||||
lsl r0, r0, #0x10
|
||||
add r4, r4, #1
|
||||
@ -746,7 +746,7 @@ _02201926:
|
||||
add r0, r6, #0
|
||||
lsr r1, r1, #0x10
|
||||
add r2, r7, #0
|
||||
bl sub_02078550
|
||||
bl Bag_GetQuantity
|
||||
add r0, r5, r0
|
||||
lsl r0, r0, #0x10
|
||||
add r4, r4, #1
|
||||
@ -963,7 +963,7 @@ _02201ABA:
|
||||
ldr r2, _02201B18 ; =0x02201BA0
|
||||
str r1, [r2]
|
||||
ldr r2, [r4]
|
||||
bl sub_02078644
|
||||
bl CreateBagView
|
||||
str r0, [r4, #0x10]
|
||||
ldr r1, [r4, #4]
|
||||
mov r2, #6
|
||||
@ -979,7 +979,7 @@ _02201ADC:
|
||||
ldr r2, _02201B18 ; =0x02201BA0
|
||||
str r1, [r2]
|
||||
ldr r2, [r4]
|
||||
bl sub_02078644
|
||||
bl CreateBagView
|
||||
str r0, [r4, #0x10]
|
||||
ldr r1, [r4, #4]
|
||||
mov r2, #6
|
||||
|
@ -1074,7 +1074,7 @@ ov17_022023B0: ; 0x022023B0
|
||||
_022023F6:
|
||||
cmp r2, #2
|
||||
bne _0220242A
|
||||
bl sub_020780E4
|
||||
bl ItemIdIsBerry
|
||||
cmp r0, #0
|
||||
beq _02202438
|
||||
ldr r0, [r4, #4]
|
||||
|
@ -25,7 +25,7 @@ _022598E0:
|
||||
lsl r1, r4, #2
|
||||
ldrh r1, [r7, r1]
|
||||
mov r2, #4
|
||||
bl sub_02078550
|
||||
bl Bag_GetQuantity
|
||||
add r0, r5, r0
|
||||
lsl r0, r0, #0x10
|
||||
lsr r5, r0, #0x10
|
||||
@ -128,7 +128,7 @@ _022599B0:
|
||||
ldr r1, _022599EC ; =0x022599F0
|
||||
mov r2, #4
|
||||
ldrh r1, [r1, r7]
|
||||
bl sub_02078550
|
||||
bl Bag_GetQuantity
|
||||
add r0, r5, r0
|
||||
lsl r0, r0, #0x10
|
||||
lsr r5, r0, #0x10
|
||||
|
@ -1287,7 +1287,7 @@ _0225A9D0:
|
||||
ldr r0, [r0, #0xc]
|
||||
bl Sav2_Bag_get
|
||||
add r4, r0, #0
|
||||
bl sub_020781C4
|
||||
bl Bag_GetRegisteredItemSlot1
|
||||
cmp r0, #0
|
||||
beq _0225A9EA
|
||||
mov r6, #1
|
||||
@ -1296,7 +1296,7 @@ _0225A9EA:
|
||||
mov r6, #0
|
||||
_0225A9EC:
|
||||
add r0, r4, #0
|
||||
bl sub_020781D0
|
||||
bl Bag_GetRegisteredItemSlot2
|
||||
cmp r0, #0
|
||||
beq _0225A9FA
|
||||
mov r4, #1
|
||||
@ -1951,12 +1951,12 @@ _0225AF22:
|
||||
str r0, [sp, #0x1c]
|
||||
add r0, r7, #0
|
||||
mov r6, #0x12
|
||||
bl sub_020781C4
|
||||
bl Bag_GetRegisteredItemSlot1
|
||||
mov r1, #2
|
||||
bl GetItemIndexMapping
|
||||
str r0, [sp, #0x20]
|
||||
add r0, r7, #0
|
||||
bl sub_020781C4
|
||||
bl Bag_GetRegisteredItemSlot1
|
||||
mov r1, #1
|
||||
bl GetItemIndexMapping
|
||||
add r2, r0, #0
|
||||
@ -1968,12 +1968,12 @@ _0225AF4A:
|
||||
str r0, [sp, #0x1c]
|
||||
add r0, r7, #0
|
||||
mov r6, #0x12
|
||||
bl sub_020781D0
|
||||
bl Bag_GetRegisteredItemSlot2
|
||||
mov r1, #2
|
||||
bl GetItemIndexMapping
|
||||
str r0, [sp, #0x20]
|
||||
add r0, r7, #0
|
||||
bl sub_020781D0
|
||||
bl Bag_GetRegisteredItemSlot2
|
||||
mov r1, #1
|
||||
bl GetItemIndexMapping
|
||||
add r2, r0, #0
|
||||
@ -2750,7 +2750,7 @@ _0225B5AC:
|
||||
cmp r4, #8
|
||||
bne _0225B5BE
|
||||
add r0, r6, #0
|
||||
bl sub_020781C4
|
||||
bl Bag_GetRegisteredItemSlot1
|
||||
cmp r0, #0
|
||||
bne _0225B5D0
|
||||
mov r0, #1
|
||||
@ -2759,7 +2759,7 @@ _0225B5BE:
|
||||
cmp r4, #9
|
||||
bne _0225B5D0
|
||||
add r0, r6, #0
|
||||
bl sub_020781D0
|
||||
bl Bag_GetRegisteredItemSlot2
|
||||
cmp r0, #0
|
||||
bne _0225B5D0
|
||||
mov r0, #1
|
||||
|
@ -8102,7 +8102,7 @@ sub_020446AC: ; 0x020446AC
|
||||
ldr r0, [r0, #0xc]
|
||||
bl Sav2_Bag_get
|
||||
add r1, r6, #0
|
||||
bl sub_020784C4
|
||||
bl Bag_PocketNotEmpty
|
||||
strh r0, [r4]
|
||||
mov r0, #0
|
||||
pop {r4, r5, r6, pc}
|
||||
|
@ -188,7 +188,7 @@ sub_0204EB38: ; 0x0204EB38
|
||||
bl Sav2_Bag_get
|
||||
add r1, r6, #0
|
||||
mov r2, #0xb
|
||||
bl sub_02078550
|
||||
bl Bag_GetQuantity
|
||||
strh r0, [r4]
|
||||
mov r0, #0
|
||||
pop {r4, r5, r6, pc}
|
||||
|
@ -2237,7 +2237,7 @@ _0203CD68:
|
||||
ldr r1, _0203CEEC ; =_020FA0B8
|
||||
add r0, r7, #0
|
||||
mov r2, #0xb
|
||||
bl sub_02078644
|
||||
bl CreateBagView
|
||||
mov r1, #0xe
|
||||
lsl r1, r1, #6
|
||||
str r0, [r4, r1]
|
||||
@ -2514,9 +2514,9 @@ sub_0203CFC0: ; 0x0203CFC0
|
||||
bl sub_02050650
|
||||
add r4, r0, #0
|
||||
mov r0, #0xb
|
||||
bl sub_02077878
|
||||
bl BagView_New
|
||||
add r7, r0, #0
|
||||
bl sub_02077890
|
||||
bl BagView_sizeof
|
||||
mov r1, #0xe
|
||||
lsl r1, r1, #6
|
||||
add r2, r0, #0
|
||||
@ -3347,7 +3347,7 @@ sub_0203D664: ; 0x0203D664
|
||||
mov r7, #0xb
|
||||
_0203D688:
|
||||
add r0, r5, #0
|
||||
bl sub_020780F4
|
||||
bl BerryToItemId
|
||||
add r1, r0, #0
|
||||
add r0, r4, #0
|
||||
add r2, r6, #0
|
||||
|
@ -239,7 +239,7 @@ sub_0203E3FC: ; 0x0203E3FC
|
||||
bl Sav2_Bag_get
|
||||
ldr r1, _0203E45C ; =_020FA1B8
|
||||
mov r2, #0xb
|
||||
bl sub_02078644
|
||||
bl CreateBagView
|
||||
mov r1, #0x43
|
||||
lsl r1, r1, #2
|
||||
add r1, r5, r1
|
||||
@ -307,7 +307,7 @@ _0203E48E:
|
||||
add r0, r6, #0
|
||||
ldr r1, [r1]
|
||||
mov r2, #0x20
|
||||
bl sub_02078644
|
||||
bl CreateBagView
|
||||
mov r1, #0x43
|
||||
lsl r1, r1, #2
|
||||
add r1, r5, r1
|
||||
|
@ -112,7 +112,7 @@ _0205193C:
|
||||
cmp r7, #4
|
||||
blt _0205193C
|
||||
add r0, r6, #0
|
||||
bl sub_02078188
|
||||
bl Sav2_Bag_new
|
||||
mov r1, #0x42
|
||||
lsl r1, r1, #2
|
||||
str r0, [r4, r1]
|
||||
@ -677,7 +677,7 @@ _02051E14:
|
||||
lsl r1, r1, #2
|
||||
ldr r0, [sp, #0x14]
|
||||
ldr r1, [r5, r1]
|
||||
bl sub_020781B4
|
||||
bl Sav2_Bag_copy
|
||||
mov r1, #0x11
|
||||
lsl r1, r1, #4
|
||||
ldr r0, [sp, #0x10]
|
||||
@ -900,7 +900,7 @@ _02052004:
|
||||
lsl r1, r1, #2
|
||||
ldr r0, [sp, #0x10]
|
||||
ldr r1, [r5, r1]
|
||||
bl sub_020781B4
|
||||
bl Sav2_Bag_copy
|
||||
mov r1, #0x11
|
||||
lsl r1, r1, #4
|
||||
ldr r0, [sp, #0xc]
|
||||
@ -1128,7 +1128,7 @@ _020521F6:
|
||||
lsl r1, r1, #2
|
||||
ldr r0, [sp, #0x1c]
|
||||
ldr r1, [r5, r1]
|
||||
bl sub_020781B4
|
||||
bl Sav2_Bag_copy
|
||||
mov r1, #0x11
|
||||
lsl r1, r1, #4
|
||||
ldr r0, [sp, #0x18]
|
||||
@ -1357,7 +1357,7 @@ sub_0205239C: ; 0x0205239C
|
||||
lsl r0, r0, #2
|
||||
ldr r0, [r5, r0]
|
||||
ldr r1, [sp]
|
||||
bl sub_020781B4
|
||||
bl Sav2_Bag_copy
|
||||
mov r0, #0x11
|
||||
lsl r0, r0, #4
|
||||
ldr r0, [r5, r0]
|
||||
|
@ -20251,7 +20251,7 @@ sub_02065150: ; 0x02065150
|
||||
ldr r0, [r0, #0xc]
|
||||
ldr r1, [r4, #0x10]
|
||||
mov r3, #0xb
|
||||
bl sub_02077980
|
||||
bl TryFormatRegisteredKeyItemUseMessage
|
||||
ldr r0, [r5]
|
||||
ldr r1, _02065188 ; =sub_0206518C
|
||||
add r2, r4, #0
|
||||
@ -20966,11 +20966,11 @@ _020656E2:
|
||||
ldr r0, [r5, #0xc]
|
||||
bne _020656F2
|
||||
bl Sav2_Bag_get
|
||||
bl sub_020781C4
|
||||
bl Bag_GetRegisteredItemSlot1
|
||||
b _020656FA
|
||||
_020656F2:
|
||||
bl Sav2_Bag_get
|
||||
bl sub_020781D0
|
||||
bl Bag_GetRegisteredItemSlot2
|
||||
_020656FA:
|
||||
add r6, r0, #0
|
||||
ldr r0, _020657A0 ; =0x000001D7
|
||||
|
@ -4570,7 +4570,7 @@ _02076CC4:
|
||||
ldr r0, [r4, #0x4c]
|
||||
ldr r2, [r4, #0x5c]
|
||||
mov r1, #4
|
||||
bl sub_02078550
|
||||
bl Bag_GetQuantity
|
||||
cmp r0, #0
|
||||
beq _02076CE4
|
||||
ldr r0, [r4, #0x24]
|
||||
@ -6061,8 +6061,10 @@ sub_02077870: ; 0x02077870
|
||||
_02077874: .word sub_0200D9DC
|
||||
thumb_func_end sub_02077870
|
||||
|
||||
thumb_func_start sub_02077878
|
||||
sub_02077878: ; 0x02077878
|
||||
; bag_view.c
|
||||
|
||||
thumb_func_start BagView_New
|
||||
BagView_New: ; 0x02077878
|
||||
push {r4, lr}
|
||||
mov r1, #0x7c
|
||||
bl AllocFromHeap
|
||||
@ -6073,13 +6075,13 @@ sub_02077878: ; 0x02077878
|
||||
add r0, r4, #0
|
||||
pop {r4, pc}
|
||||
.balign 4, 0
|
||||
thumb_func_end sub_02077878
|
||||
thumb_func_end BagView_New
|
||||
|
||||
thumb_func_start sub_02077890
|
||||
sub_02077890: ; 0x02077890
|
||||
thumb_func_start BagView_sizeof
|
||||
BagView_sizeof: ; 0x02077890
|
||||
mov r0, #0x7c
|
||||
bx lr
|
||||
thumb_func_end sub_02077890
|
||||
thumb_func_end BagView_sizeof
|
||||
|
||||
thumb_func_start sub_02077894
|
||||
sub_02077894: ; 0x02077894
|
||||
@ -6108,15 +6110,15 @@ sub_0207789C: ; 0x0207789C
|
||||
.balign 4, 0
|
||||
thumb_func_end sub_0207789C
|
||||
|
||||
thumb_func_start sub_020778BC
|
||||
sub_020778BC: ; 0x020778BC
|
||||
thumb_func_start BagView_SetItem
|
||||
BagView_SetItem: ; 0x020778BC
|
||||
mov r3, #0xc
|
||||
mul r3, r2
|
||||
add r0, r0, r3
|
||||
str r1, [r0, #4]
|
||||
strb r2, [r0, #0xc]
|
||||
bx lr
|
||||
thumb_func_end sub_020778BC
|
||||
thumb_func_end BagView_SetItem
|
||||
|
||||
thumb_func_start sub_020778C8
|
||||
sub_020778C8: ; 0x020778C8
|
||||
@ -6250,8 +6252,8 @@ sub_02077970: ; 0x02077970
|
||||
pop {r3, pc}
|
||||
thumb_func_end sub_02077970
|
||||
|
||||
thumb_func_start sub_02077980
|
||||
sub_02077980: ; 0x02077980
|
||||
thumb_func_start TryFormatRegisteredKeyItemUseMessage
|
||||
TryFormatRegisteredKeyItemUseMessage: ; 0x02077980
|
||||
push {r4, r5, r6, r7, lr}
|
||||
sub sp, #0xc
|
||||
add r7, r0, #0
|
||||
@ -6381,7 +6383,7 @@ _02077A82:
|
||||
mov r0, #1
|
||||
add sp, #0xc
|
||||
pop {r4, r5, r6, r7, pc}
|
||||
thumb_func_end sub_02077980
|
||||
thumb_func_end TryFormatRegisteredKeyItemUseMessage
|
||||
|
||||
thumb_func_start GetItemUseErrorMessage
|
||||
GetItemUseErrorMessage: ; 0x02077AA4
|
||||
@ -6471,6 +6473,8 @@ _02077B14:
|
||||
pop {r3, r4, r5, r6, r7, pc}
|
||||
thumb_func_end GetItemUseErrorMessage
|
||||
|
||||
; itemtool.c
|
||||
|
||||
thumb_func_start MoveItemSlotInList
|
||||
MoveItemSlotInList: ; 0x02077B5C
|
||||
push {r3, r4, r5, r6, r7, lr}
|
||||
@ -7286,8 +7290,8 @@ _02078094:
|
||||
bx lr
|
||||
thumb_func_end MailToItemId
|
||||
|
||||
thumb_func_start sub_0207809C
|
||||
sub_0207809C: ; 0x0207809C
|
||||
thumb_func_start ItemToBallId
|
||||
ItemToBallId: ; 0x0207809C
|
||||
cmp r0, #1
|
||||
blo _020780A4
|
||||
cmp r0, #0x10
|
||||
@ -7307,10 +7311,10 @@ _020780B8:
|
||||
mov r0, #4
|
||||
_020780BA:
|
||||
bx lr
|
||||
thumb_func_end sub_0207809C
|
||||
thumb_func_end ItemToBallId
|
||||
|
||||
thumb_func_start sub_020780BC
|
||||
sub_020780BC: ; 0x020780BC
|
||||
thumb_func_start BallToItemId
|
||||
BallToItemId: ; 0x020780BC
|
||||
cmp r0, #1
|
||||
blt _020780CA
|
||||
cmp r0, #0x10
|
||||
@ -7333,10 +7337,10 @@ _020780DC:
|
||||
bx lr
|
||||
.balign 4, 0
|
||||
_020780E0: .word 0x000001DB
|
||||
thumb_func_end sub_020780BC
|
||||
thumb_func_end BallToItemId
|
||||
|
||||
thumb_func_start sub_020780E4
|
||||
sub_020780E4: ; 0x020780E4
|
||||
thumb_func_start ItemIdIsBerry
|
||||
ItemIdIsBerry: ; 0x020780E4
|
||||
cmp r0, #0x95
|
||||
blo _020780EC
|
||||
cmp r0, #0xd4
|
||||
@ -7347,10 +7351,10 @@ _020780EC:
|
||||
_020780F0:
|
||||
mov r0, #1
|
||||
bx lr
|
||||
thumb_func_end sub_020780E4
|
||||
thumb_func_end ItemIdIsBerry
|
||||
|
||||
thumb_func_start sub_020780F4
|
||||
sub_020780F4: ; 0x020780F4
|
||||
thumb_func_start BerryToItemId
|
||||
BerryToItemId: ; 0x020780F4
|
||||
cmp r0, #0x40
|
||||
blo _020780FC
|
||||
ldr r0, _02078104 ; =0x0000FFFF
|
||||
@ -7362,7 +7366,7 @@ _020780FC:
|
||||
bx lr
|
||||
.balign 4, 0
|
||||
_02078104: .word 0x0000FFFF
|
||||
thumb_func_end sub_020780F4
|
||||
thumb_func_end BerryToItemId
|
||||
|
||||
thumb_func_start GetNutName
|
||||
GetNutName: ; 0x02078108
|
||||
@ -7390,8 +7394,8 @@ _02078118:
|
||||
.balign 4, 0
|
||||
thumb_func_end GetNutName
|
||||
|
||||
thumb_func_start sub_02078138
|
||||
sub_02078138: ; 0x02078138
|
||||
thumb_func_start LoadAllItemData
|
||||
LoadAllItemData: ; 0x02078138
|
||||
push {r3, r4, lr}
|
||||
sub sp, #4
|
||||
add r4, r0, #0
|
||||
@ -7410,18 +7414,18 @@ sub_02078138: ; 0x02078138
|
||||
add sp, #4
|
||||
pop {r3, r4, pc}
|
||||
.balign 4, 0
|
||||
thumb_func_end sub_02078138
|
||||
thumb_func_end LoadAllItemData
|
||||
|
||||
thumb_func_start sub_02078160
|
||||
sub_02078160: ; 0x02078160
|
||||
thumb_func_start GetItemDataPtrFromArray
|
||||
GetItemDataPtrFromArray: ; 0x02078160
|
||||
mov r2, #0x24
|
||||
mul r2, r1
|
||||
add r0, r0, r2
|
||||
bx lr
|
||||
thumb_func_end sub_02078160
|
||||
thumb_func_end GetItemDataPtrFromArray
|
||||
|
||||
thumb_func_start sub_02078168
|
||||
sub_02078168: ; 0x02078168
|
||||
thumb_func_start ItemIdIsNotApricornBall
|
||||
ItemIdIsNotApricornBall: ; 0x02078168
|
||||
ldr r1, _0207817C ; =0x0000FE14
|
||||
add r0, r0, r1
|
||||
lsl r0, r0, #0x10
|
||||
@ -7435,7 +7439,9 @@ _02078178:
|
||||
bx lr
|
||||
.balign 4, 0
|
||||
_0207817C: .word 0x0000FE14
|
||||
thumb_func_end sub_02078168
|
||||
thumb_func_end ItemIdIsNotApricornBall
|
||||
|
||||
; bag.c
|
||||
|
||||
thumb_func_start Sav2_Bag_sizeof
|
||||
Sav2_Bag_sizeof: ; 0x02078180
|
||||
@ -7445,8 +7451,8 @@ Sav2_Bag_sizeof: ; 0x02078180
|
||||
_02078184: .word 0x0000079C
|
||||
thumb_func_end Sav2_Bag_sizeof
|
||||
|
||||
thumb_func_start sub_02078188
|
||||
sub_02078188: ; 0x02078188
|
||||
thumb_func_start Sav2_Bag_new
|
||||
Sav2_Bag_new: ; 0x02078188
|
||||
push {r4, lr}
|
||||
ldr r1, _0207819C ; =0x0000079C
|
||||
bl AllocFromHeap
|
||||
@ -7456,7 +7462,7 @@ sub_02078188: ; 0x02078188
|
||||
pop {r4, pc}
|
||||
nop
|
||||
_0207819C: .word 0x0000079C
|
||||
thumb_func_end sub_02078188
|
||||
thumb_func_end Sav2_Bag_new
|
||||
|
||||
thumb_func_start Sav2_Bag_init
|
||||
Sav2_Bag_init: ; 0x020781A0
|
||||
@ -7470,36 +7476,36 @@ _020781AC: .word MIi_CpuClear16
|
||||
_020781B0: .word 0x0000079C
|
||||
thumb_func_end Sav2_Bag_init
|
||||
|
||||
thumb_func_start sub_020781B4
|
||||
sub_020781B4: ; 0x020781B4
|
||||
thumb_func_start Sav2_Bag_copy
|
||||
Sav2_Bag_copy: ; 0x020781B4
|
||||
ldr r3, _020781BC ; =MI_CpuCopy8
|
||||
ldr r2, _020781C0 ; =0x0000079C
|
||||
bx r3
|
||||
nop
|
||||
_020781BC: .word MI_CpuCopy8
|
||||
_020781C0: .word 0x0000079C
|
||||
thumb_func_end sub_020781B4
|
||||
thumb_func_end Sav2_Bag_copy
|
||||
|
||||
thumb_func_start sub_020781C4
|
||||
sub_020781C4: ; 0x020781C4
|
||||
thumb_func_start Bag_GetRegisteredItemSlot1
|
||||
Bag_GetRegisteredItemSlot1: ; 0x020781C4
|
||||
ldr r1, _020781CC ; =0x00000798
|
||||
ldrh r0, [r0, r1]
|
||||
bx lr
|
||||
nop
|
||||
_020781CC: .word 0x00000798
|
||||
thumb_func_end sub_020781C4
|
||||
thumb_func_end Bag_GetRegisteredItemSlot1
|
||||
|
||||
thumb_func_start sub_020781D0
|
||||
sub_020781D0: ; 0x020781D0
|
||||
thumb_func_start Bag_GetRegisteredItemSlot2
|
||||
Bag_GetRegisteredItemSlot2: ; 0x020781D0
|
||||
ldr r1, _020781D8 ; =0x0000079A
|
||||
ldrh r0, [r0, r1]
|
||||
bx lr
|
||||
nop
|
||||
_020781D8: .word 0x0000079A
|
||||
thumb_func_end sub_020781D0
|
||||
thumb_func_end Bag_GetRegisteredItemSlot2
|
||||
|
||||
thumb_func_start sub_020781DC
|
||||
sub_020781DC: ; 0x020781DC
|
||||
thumb_func_start Bag_TryRegisterItem
|
||||
Bag_TryRegisterItem: ; 0x020781DC
|
||||
push {r3, r4}
|
||||
ldr r3, _02078204 ; =0x00000798
|
||||
mov r4, #0
|
||||
@ -7523,10 +7529,10 @@ _020781FC:
|
||||
bx lr
|
||||
nop
|
||||
_02078204: .word 0x00000798
|
||||
thumb_func_end sub_020781DC
|
||||
thumb_func_end Bag_TryRegisterItem
|
||||
|
||||
thumb_func_start sub_02078208
|
||||
sub_02078208: ; 0x02078208
|
||||
thumb_func_start Bag_UnregisterItem
|
||||
Bag_UnregisterItem: ; 0x02078208
|
||||
push {r3, r4}
|
||||
ldr r3, _0207823C ; =0x0000079A
|
||||
ldrh r4, [r0, r3]
|
||||
@ -7558,10 +7564,10 @@ _02078238:
|
||||
bx lr
|
||||
.balign 4, 0
|
||||
_0207823C: .word 0x0000079A
|
||||
thumb_func_end sub_02078208
|
||||
thumb_func_end Bag_UnregisterItem
|
||||
|
||||
thumb_func_start sub_02078240
|
||||
sub_02078240: ; 0x02078240
|
||||
thumb_func_start Bag_GetItemPocket
|
||||
Bag_GetItemPocket: ; 0x02078240
|
||||
push {r4, r5, r6, lr}
|
||||
add r5, r2, #0
|
||||
add r4, r0, #0
|
||||
@ -7649,10 +7655,10 @@ _020782CE:
|
||||
str r1, [r6]
|
||||
_020782DA:
|
||||
pop {r4, r5, r6, pc}
|
||||
thumb_func_end sub_02078240
|
||||
thumb_func_end Bag_GetItemPocket
|
||||
|
||||
thumb_func_start sub_020782DC
|
||||
sub_020782DC: ; 0x020782DC
|
||||
thumb_func_start Pocket_GetItemSlotForAdd
|
||||
Pocket_GetItemSlotForAdd: ; 0x020782DC
|
||||
push {r4, r5, r6, r7}
|
||||
add r5, r1, #0
|
||||
mov r1, #0
|
||||
@ -7709,10 +7715,10 @@ _02078338:
|
||||
_0207833C:
|
||||
pop {r4, r5, r6, r7}
|
||||
bx lr
|
||||
thumb_func_end sub_020782DC
|
||||
thumb_func_end Pocket_GetItemSlotForAdd
|
||||
|
||||
thumb_func_start sub_02078340
|
||||
sub_02078340: ; 0x02078340
|
||||
thumb_func_start Bag_GetItemSlotForAdd
|
||||
Bag_GetItemSlotForAdd: ; 0x02078340
|
||||
push {r4, r5, lr}
|
||||
sub sp, #0xc
|
||||
add r4, r2, #0
|
||||
@ -7720,7 +7726,7 @@ sub_02078340: ; 0x02078340
|
||||
add r2, sp, #8
|
||||
add r3, sp, #4
|
||||
add r5, r1, #0
|
||||
bl sub_02078240
|
||||
bl Bag_GetItemPocket
|
||||
cmp r0, #3
|
||||
bne _0207836A
|
||||
mov r0, #0x63
|
||||
@ -7729,7 +7735,7 @@ sub_02078340: ; 0x02078340
|
||||
ldr r1, [sp, #4]
|
||||
add r2, r5, #0
|
||||
add r3, r4, #0
|
||||
bl sub_020782DC
|
||||
bl Pocket_GetItemSlotForAdd
|
||||
add sp, #0xc
|
||||
pop {r4, r5, pc}
|
||||
_0207836A:
|
||||
@ -7739,17 +7745,17 @@ _0207836A:
|
||||
ldr r0, [sp, #8]
|
||||
ldr r1, [sp, #4]
|
||||
add r3, r4, #0
|
||||
bl sub_020782DC
|
||||
bl Pocket_GetItemSlotForAdd
|
||||
add sp, #0xc
|
||||
pop {r4, r5, pc}
|
||||
nop
|
||||
_02078380: .word 0x000003E7
|
||||
thumb_func_end sub_02078340
|
||||
thumb_func_end Bag_GetItemSlotForAdd
|
||||
|
||||
thumb_func_start Bag_HasSpaceForItem
|
||||
Bag_HasSpaceForItem: ; 0x02078384
|
||||
push {r3, lr}
|
||||
bl sub_02078340
|
||||
bl Bag_GetItemSlotForAdd
|
||||
cmp r0, #0
|
||||
beq _02078392
|
||||
mov r0, #1
|
||||
@ -7768,7 +7774,7 @@ Bag_AddItem: ; 0x02078398
|
||||
add r5, r1, #0
|
||||
add r4, r2, #0
|
||||
add r6, r3, #0
|
||||
bl sub_02078340
|
||||
bl Bag_GetItemSlotForAdd
|
||||
str r0, [sp, #8]
|
||||
cmp r0, #0
|
||||
bne _020783B4
|
||||
@ -7786,21 +7792,21 @@ _020783B4:
|
||||
add r0, r7, #0
|
||||
add r1, r5, #0
|
||||
str r6, [sp]
|
||||
bl sub_02078240
|
||||
bl Bag_GetItemPocket
|
||||
sub r0, r0, #3
|
||||
cmp r0, #1
|
||||
bhi _020783DA
|
||||
ldr r0, [sp, #8]
|
||||
ldr r1, [sp, #4]
|
||||
bl sub_020785EC
|
||||
bl SortPocket
|
||||
_020783DA:
|
||||
mov r0, #1
|
||||
add sp, #0xc
|
||||
pop {r4, r5, r6, r7, pc}
|
||||
thumb_func_end Bag_AddItem
|
||||
|
||||
thumb_func_start sub_020783E0
|
||||
sub_020783E0: ; 0x020783E0
|
||||
thumb_func_start Pocket_GetItemSlotForRemove
|
||||
Pocket_GetItemSlotForRemove: ; 0x020783E0
|
||||
push {r3, r4, r5, r6}
|
||||
mov r5, #0
|
||||
cmp r1, #0
|
||||
@ -7829,10 +7835,10 @@ _0207840A:
|
||||
pop {r3, r4, r5, r6}
|
||||
bx lr
|
||||
.balign 4, 0
|
||||
thumb_func_end sub_020783E0
|
||||
thumb_func_end Pocket_GetItemSlotForRemove
|
||||
|
||||
thumb_func_start sub_02078410
|
||||
sub_02078410: ; 0x02078410
|
||||
thumb_func_start Bag_GetItemSlotForRemove
|
||||
Bag_GetItemSlotForRemove: ; 0x02078410
|
||||
push {r4, r5, lr}
|
||||
sub sp, #0xc
|
||||
add r4, r2, #0
|
||||
@ -7840,16 +7846,16 @@ sub_02078410: ; 0x02078410
|
||||
add r2, sp, #8
|
||||
add r3, sp, #4
|
||||
add r5, r1, #0
|
||||
bl sub_02078240
|
||||
bl Bag_GetItemPocket
|
||||
ldr r0, [sp, #8]
|
||||
ldr r1, [sp, #4]
|
||||
add r2, r5, #0
|
||||
add r3, r4, #0
|
||||
bl sub_020783E0
|
||||
bl Pocket_GetItemSlotForRemove
|
||||
add sp, #0xc
|
||||
pop {r4, r5, pc}
|
||||
.balign 4, 0
|
||||
thumb_func_end sub_02078410
|
||||
thumb_func_end Bag_GetItemSlotForRemove
|
||||
|
||||
thumb_func_start Bag_TakeItem
|
||||
Bag_TakeItem: ; 0x02078434
|
||||
@ -7859,7 +7865,7 @@ Bag_TakeItem: ; 0x02078434
|
||||
add r7, r1, #0
|
||||
add r5, r2, #0
|
||||
add r4, r3, #0
|
||||
bl sub_02078410
|
||||
bl Bag_GetItemSlotForRemove
|
||||
str r0, [sp, #8]
|
||||
cmp r0, #0
|
||||
bne _02078450
|
||||
@ -7882,23 +7888,23 @@ _02078462:
|
||||
add r1, r7, #0
|
||||
add r2, sp, #8
|
||||
add r3, sp, #4
|
||||
bl sub_02078240
|
||||
bl Bag_GetItemPocket
|
||||
ldr r0, [sp, #8]
|
||||
ldr r1, [sp, #4]
|
||||
bl sub_020785A0
|
||||
bl PocketCompaction
|
||||
mov r0, #1
|
||||
add sp, #0xc
|
||||
pop {r4, r5, r6, r7, pc}
|
||||
.balign 4, 0
|
||||
thumb_func_end Bag_TakeItem
|
||||
|
||||
thumb_func_start sub_02078480
|
||||
sub_02078480: ; 0x02078480
|
||||
thumb_func_start Pocket_TakeItem
|
||||
Pocket_TakeItem: ; 0x02078480
|
||||
push {r4, r5, r6, lr}
|
||||
add r5, r0, #0
|
||||
add r6, r1, #0
|
||||
add r4, r3, #0
|
||||
bl sub_020783E0
|
||||
bl Pocket_GetItemSlotForRemove
|
||||
cmp r0, #0
|
||||
bne _02078494
|
||||
mov r0, #0
|
||||
@ -7915,15 +7921,15 @@ _02078494:
|
||||
_020784A4:
|
||||
add r0, r5, #0
|
||||
add r1, r6, #0
|
||||
bl sub_020785A0
|
||||
bl PocketCompaction
|
||||
mov r0, #1
|
||||
pop {r4, r5, r6, pc}
|
||||
thumb_func_end sub_02078480
|
||||
thumb_func_end Pocket_TakeItem
|
||||
|
||||
thumb_func_start Bag_HasItem
|
||||
Bag_HasItem: ; 0x020784B0
|
||||
push {r3, lr}
|
||||
bl sub_02078410
|
||||
bl Bag_GetItemSlotForRemove
|
||||
cmp r0, #0
|
||||
beq _020784BE
|
||||
mov r0, #1
|
||||
@ -7934,8 +7940,8 @@ _020784BE:
|
||||
.balign 4, 0
|
||||
thumb_func_end Bag_HasItem
|
||||
|
||||
thumb_func_start sub_020784C4
|
||||
sub_020784C4: ; 0x020784C4
|
||||
thumb_func_start Bag_PocketNotEmpty
|
||||
Bag_PocketNotEmpty: ; 0x020784C4
|
||||
cmp r1, #7
|
||||
bhi _0207852E
|
||||
add r1, r1, r1
|
||||
@ -8020,14 +8026,14 @@ _0207854A:
|
||||
mov r0, #0
|
||||
bx lr
|
||||
.balign 4, 0
|
||||
thumb_func_end sub_020784C4
|
||||
thumb_func_end Bag_PocketNotEmpty
|
||||
|
||||
thumb_func_start sub_02078550
|
||||
sub_02078550: ; 0x02078550
|
||||
thumb_func_start Bag_GetQuantity
|
||||
Bag_GetQuantity: ; 0x02078550
|
||||
push {r3, lr}
|
||||
add r3, r2, #0
|
||||
mov r2, #1
|
||||
bl sub_02078410
|
||||
bl Bag_GetItemSlotForRemove
|
||||
cmp r0, #0
|
||||
bne _02078562
|
||||
mov r0, #0
|
||||
@ -8036,13 +8042,13 @@ _02078562:
|
||||
ldrh r0, [r0, #2]
|
||||
pop {r3, pc}
|
||||
.balign 4, 0
|
||||
thumb_func_end sub_02078550
|
||||
thumb_func_end Bag_GetQuantity
|
||||
|
||||
thumb_func_start sub_02078568
|
||||
sub_02078568: ; 0x02078568
|
||||
thumb_func_start Pocket_GetQuantity
|
||||
Pocket_GetQuantity: ; 0x02078568
|
||||
push {r3, lr}
|
||||
mov r3, #1
|
||||
bl sub_020783E0
|
||||
bl Pocket_GetItemSlotForRemove
|
||||
cmp r0, #0
|
||||
bne _02078578
|
||||
mov r0, #0
|
||||
@ -8050,10 +8056,10 @@ sub_02078568: ; 0x02078568
|
||||
_02078578:
|
||||
ldrh r0, [r0, #2]
|
||||
pop {r3, pc}
|
||||
thumb_func_end sub_02078568
|
||||
thumb_func_end Pocket_GetQuantity
|
||||
|
||||
thumb_func_start sub_0207857C
|
||||
sub_0207857C: ; 0x0207857C
|
||||
thumb_func_start SwapItemSlots
|
||||
SwapItemSlots: ; 0x0207857C
|
||||
push {r3}
|
||||
sub sp, #4
|
||||
ldrh r3, [r0]
|
||||
@ -8072,10 +8078,10 @@ sub_0207857C: ; 0x0207857C
|
||||
add sp, #4
|
||||
pop {r3}
|
||||
bx lr
|
||||
thumb_func_end sub_0207857C
|
||||
thumb_func_end SwapItemSlots
|
||||
|
||||
thumb_func_start sub_020785A0
|
||||
sub_020785A0: ; 0x020785A0
|
||||
thumb_func_start PocketCompaction
|
||||
PocketCompaction: ; 0x020785A0
|
||||
push {r4, r5, r6, r7, lr}
|
||||
sub sp, #0xc
|
||||
str r0, [sp]
|
||||
@ -8100,7 +8106,7 @@ _020785C2:
|
||||
bne _020785D0
|
||||
add r0, r4, #0
|
||||
add r1, r5, #0
|
||||
bl sub_0207857C
|
||||
bl SwapItemSlots
|
||||
_020785D0:
|
||||
add r6, r6, #1
|
||||
add r5, r5, #4
|
||||
@ -8118,10 +8124,10 @@ _020785E6:
|
||||
add sp, #0xc
|
||||
pop {r4, r5, r6, r7, pc}
|
||||
.balign 4, 0
|
||||
thumb_func_end sub_020785A0
|
||||
thumb_func_end PocketCompaction
|
||||
|
||||
thumb_func_start sub_020785EC
|
||||
sub_020785EC: ; 0x020785EC
|
||||
thumb_func_start SortPocket
|
||||
SortPocket: ; 0x020785EC
|
||||
push {r4, r5, r6, r7, lr}
|
||||
sub sp, #0xc
|
||||
str r0, [sp]
|
||||
@ -8154,7 +8160,7 @@ _0207860E:
|
||||
_02078622:
|
||||
add r0, r4, #0
|
||||
add r1, r5, #0
|
||||
bl sub_0207857C
|
||||
bl SwapItemSlots
|
||||
_0207862A:
|
||||
add r6, r6, #1
|
||||
add r5, r5, #4
|
||||
@ -8171,16 +8177,16 @@ _02078632:
|
||||
_02078640:
|
||||
add sp, #0xc
|
||||
pop {r4, r5, r6, r7, pc}
|
||||
thumb_func_end sub_020785EC
|
||||
thumb_func_end SortPocket
|
||||
|
||||
thumb_func_start sub_02078644
|
||||
sub_02078644: ; 0x02078644
|
||||
thumb_func_start CreateBagView
|
||||
CreateBagView: ; 0x02078644
|
||||
push {r3, r4, r5, r6, r7, lr}
|
||||
add r5, r0, #0
|
||||
lsl r0, r2, #0x18
|
||||
add r7, r1, #0
|
||||
lsr r0, r0, #0x18
|
||||
bl sub_02077878
|
||||
bl BagView_New
|
||||
add r6, r0, #0
|
||||
ldrb r0, [r7]
|
||||
mov r4, #0
|
||||
@ -8213,7 +8219,7 @@ _0207867E:
|
||||
add r1, r5, r1
|
||||
mov r2, #7
|
||||
lsr r3, r3, #0x18
|
||||
bl sub_020778BC
|
||||
bl BagView_SetItem
|
||||
b _02078718
|
||||
_02078692:
|
||||
lsl r3, r4, #0x18
|
||||
@ -8221,7 +8227,7 @@ _02078692:
|
||||
add r1, r5, #0
|
||||
mov r2, #0
|
||||
lsr r3, r3, #0x18
|
||||
bl sub_020778BC
|
||||
bl BagView_SetItem
|
||||
b _02078718
|
||||
_020786A2:
|
||||
mov r1, #0x17
|
||||
@ -8231,7 +8237,7 @@ _020786A2:
|
||||
add r1, r5, r1
|
||||
mov r2, #4
|
||||
lsr r3, r3, #0x18
|
||||
bl sub_020778BC
|
||||
bl BagView_SetItem
|
||||
b _02078718
|
||||
_020786B6:
|
||||
mov r1, #0x52
|
||||
@ -8241,7 +8247,7 @@ _020786B6:
|
||||
add r1, r5, r1
|
||||
mov r2, #1
|
||||
lsr r3, r3, #0x18
|
||||
bl sub_020778BC
|
||||
bl BagView_SetItem
|
||||
b _02078718
|
||||
_020786CA:
|
||||
mov r1, #0x1b
|
||||
@ -8251,7 +8257,7 @@ _020786CA:
|
||||
add r1, r5, r1
|
||||
mov r2, #2
|
||||
lsr r3, r3, #0x18
|
||||
bl sub_020778BC
|
||||
bl BagView_SetItem
|
||||
b _02078718
|
||||
_020786DE:
|
||||
mov r1, #0x72
|
||||
@ -8261,7 +8267,7 @@ _020786DE:
|
||||
add r1, r5, r1
|
||||
mov r2, #6
|
||||
lsr r3, r3, #0x18
|
||||
bl sub_020778BC
|
||||
bl BagView_SetItem
|
||||
b _02078718
|
||||
_020786F2:
|
||||
mov r1, #0x4f
|
||||
@ -8271,7 +8277,7 @@ _020786F2:
|
||||
add r1, r5, r1
|
||||
mov r2, #5
|
||||
lsr r3, r3, #0x18
|
||||
bl sub_020778BC
|
||||
bl BagView_SetItem
|
||||
b _02078718
|
||||
_02078706:
|
||||
mov r1, #0xd7
|
||||
@ -8281,7 +8287,7 @@ _02078706:
|
||||
add r1, r5, r1
|
||||
mov r2, #3
|
||||
lsr r3, r3, #0x18
|
||||
bl sub_020778BC
|
||||
bl BagView_SetItem
|
||||
_02078718:
|
||||
add r4, r4, #1
|
||||
ldrb r0, [r7, r4]
|
||||
@ -8290,10 +8296,10 @@ _02078718:
|
||||
_02078720:
|
||||
add r0, r6, #0
|
||||
pop {r3, r4, r5, r6, r7, pc}
|
||||
thumb_func_end sub_02078644
|
||||
thumb_func_end CreateBagView
|
||||
|
||||
thumb_func_start sub_02078724
|
||||
sub_02078724: ; 0x02078724
|
||||
thumb_func_start Bag_GetPocketSlotN
|
||||
Bag_GetPocketSlotN: ; 0x02078724
|
||||
cmp r1, #7
|
||||
bhi _0207878C
|
||||
add r1, r1, r1
|
||||
@ -8365,7 +8371,7 @@ _02078794:
|
||||
add r0, r0, r1
|
||||
bx lr
|
||||
.balign 4, 0
|
||||
thumb_func_end sub_02078724
|
||||
thumb_func_end Bag_GetPocketSlotN
|
||||
|
||||
thumb_func_start Sav2_Bag_get
|
||||
Sav2_Bag_get: ; 0x0207879C
|
||||
@ -8495,6 +8501,8 @@ sub_02078830: ; 0x02078830
|
||||
bx lr
|
||||
thumb_func_end sub_02078830
|
||||
|
||||
; unk
|
||||
|
||||
thumb_func_start sub_02078834
|
||||
sub_02078834: ; 0x02078834
|
||||
push {r4, r5, r6, lr}
|
||||
|
44
global.inc
44
global.inc
@ -29075,8 +29075,8 @@
|
||||
.public sub_02077834
|
||||
.public sub_02077868
|
||||
.public sub_02077870
|
||||
.public sub_02077878
|
||||
.public sub_02077890
|
||||
.public BagView_New
|
||||
.public BagView_sizeof
|
||||
.public sub_0207789C
|
||||
.public sub_020778C8
|
||||
.public sub_020778DC
|
||||
@ -29085,7 +29085,7 @@
|
||||
.public sub_02077904
|
||||
.public sub_0207790C
|
||||
.public sub_02077914
|
||||
.public sub_02077980
|
||||
.public TryFormatRegisteredKeyItemUseMessage
|
||||
.public MoveItemSlotInList
|
||||
.public GetItemIndexMapping
|
||||
.public UpConvertItemId_Gen3to4
|
||||
@ -29100,28 +29100,28 @@
|
||||
.public ItemIdIsMail
|
||||
.public ItemToMailId
|
||||
.public MailToItemId
|
||||
.public sub_0207809C
|
||||
.public sub_020780BC
|
||||
.public sub_020780E4
|
||||
.public sub_020780F4
|
||||
.public ItemToBallId
|
||||
.public BallToItemId
|
||||
.public ItemIdIsBerry
|
||||
.public BerryToItemId
|
||||
.public GetNutName
|
||||
.public sub_02078138
|
||||
.public sub_02078160
|
||||
.public sub_02078168
|
||||
.public LoadAllItemData
|
||||
.public GetItemDataPtrFromArray
|
||||
.public ItemIdIsNotApricornBall
|
||||
.public Sav2_Bag_sizeof
|
||||
.public sub_02078188
|
||||
.public Sav2_Bag_new
|
||||
.public Sav2_Bag_init
|
||||
.public sub_020781B4
|
||||
.public sub_020781C4
|
||||
.public sub_020781D0
|
||||
.public sub_020781DC
|
||||
.public sub_02078208
|
||||
.public sub_02078480
|
||||
.public sub_020784C4
|
||||
.public sub_02078550
|
||||
.public sub_02078568
|
||||
.public sub_02078644
|
||||
.public sub_02078724
|
||||
.public Sav2_Bag_copy
|
||||
.public Bag_GetRegisteredItemSlot1
|
||||
.public Bag_GetRegisteredItemSlot2
|
||||
.public Bag_TryRegisterItem
|
||||
.public Bag_UnregisterItem
|
||||
.public Pocket_TakeItem
|
||||
.public Bag_PocketNotEmpty
|
||||
.public Bag_GetQuantity
|
||||
.public Pocket_GetQuantity
|
||||
.public CreateBagView
|
||||
.public Bag_GetPocketSlotN
|
||||
.public sub_020787A8
|
||||
.public sub_020787C0
|
||||
.public sub_020787D0
|
||||
|
35
include/constants/balls.h
Normal file
35
include/constants/balls.h
Normal file
@ -0,0 +1,35 @@
|
||||
#ifndef POKEHEARTGOLD_CONSTANTS_BALLS_H
|
||||
#define POKEHEARTGOLD_CONSTANTS_BALLS_H
|
||||
|
||||
// OG balls
|
||||
#define BALL_NONE 0
|
||||
#define BALL_MASTER 1
|
||||
#define BALL_ULTRA 2
|
||||
#define BALL_GREAT 3
|
||||
#define BALL_POKE 4
|
||||
#define BALL_SAFARI 5
|
||||
// Hoenn balls
|
||||
#define BALL_NET 6
|
||||
#define BALL_DIVE 7
|
||||
#define BALL_NEST 8
|
||||
#define BALL_REPEAT 9
|
||||
#define BALL_TIMER 10
|
||||
#define BALL_LUXURY 11
|
||||
#define BALL_PREMIER 12
|
||||
// Sinnoh balls
|
||||
#define BALL_DUSK 13
|
||||
#define BALL_HEAL 14
|
||||
#define BALL_QUICK 15
|
||||
#define BALL_CHERISH 16
|
||||
// Apricorn balls
|
||||
#define BALL_FAST 17
|
||||
#define BALL_LEVEL 18
|
||||
#define BALL_LURE 19
|
||||
#define BALL_HEAVY 20
|
||||
#define BALL_LOVE 21
|
||||
#define BALL_FRIEND 22
|
||||
#define BALL_MOON 23
|
||||
#define BALL_SPORT 24
|
||||
#define BALL_PARK 25
|
||||
|
||||
#endif //POKEHEARTGOLD_CONSTANTS_BALLS_H
|
@ -348,6 +348,7 @@
|
||||
|
||||
#define ITEM_ADAMANT_ORB 135
|
||||
#define ITEM_LUSTROUS_ORB 136
|
||||
|
||||
#define ITEM_GRASS_MAIL 137
|
||||
#define ITEM_FLAME_MAIL 138
|
||||
#define ITEM_BUBBLE_MAIL 139
|
||||
@ -361,6 +362,10 @@
|
||||
#define ITEM_MOSAIC_MAIL 147
|
||||
#define ITEM_BRICK_MAIL 148
|
||||
|
||||
#define FIRST_MAIL_IDX ITEM_GRASS_MAIL
|
||||
#define LAST_MAIL_IDX ITEM_BRICK_MAIL
|
||||
#define NUM_MAILS (LAST_MAIL_IDX - FIRST_MAIL_IDX + 1)
|
||||
|
||||
#define ITEM_CHERI_BERRY 149
|
||||
#define ITEM_CHESTO_BERRY 150
|
||||
#define ITEM_PECHA_BERRY 151
|
||||
@ -545,6 +550,7 @@
|
||||
#define ITEM_REAPER_CLOTH 325
|
||||
#define ITEM_RAZOR_CLAW 326
|
||||
#define ITEM_RAZOR_FANG 327
|
||||
|
||||
#define ITEM_TM01 328
|
||||
#define ITEM_TM02 329
|
||||
#define ITEM_TM03 330
|
||||
@ -645,6 +651,7 @@
|
||||
#define ITEM_HM06 425
|
||||
#define ITEM_HM07 426
|
||||
#define ITEM_HM08 427
|
||||
|
||||
#define ITEM_EXPLORER_KIT 428
|
||||
#define ITEM_LOOT_SACK 429
|
||||
#define ITEM_RULE_BOOK 430
|
||||
@ -682,6 +689,81 @@
|
||||
#define ITEM_COUPON_3 462
|
||||
#define ITEM_STORAGE_KEY 463
|
||||
#define ITEM_SECRETPOTION 464
|
||||
// New to Platinum
|
||||
#define ITEM_VS__RECORDER 465
|
||||
#define ITEM_GRACIDEA 466
|
||||
#define ITEM_SECRET_KEY 467
|
||||
// New to HGSS
|
||||
#define ITEM_APRICORN_BOX 468
|
||||
#define ITEM_UNOWN_REPORT 469
|
||||
#define ITEM_BERRY_POTS 470
|
||||
#define ITEM_DOWSING_MCHN 471
|
||||
#define ITEM_BLUE_CARD 472
|
||||
#define ITEM_SLOWPOKETAIL 473
|
||||
#define ITEM_CLEAR_BELL 474
|
||||
#define ITEM_CARD_KEY 475
|
||||
#define ITEM_BASEMENT_KEY 476
|
||||
#define ITEM_SQUIRTBOTTLE 477
|
||||
#define ITEM_RED_SCALE 478
|
||||
#define ITEM_LOST_ITEM 479
|
||||
#define ITEM_PASS 480
|
||||
#define ITEM_MACHINE_PART 481
|
||||
#define ITEM_SILVER_WING 482
|
||||
#define ITEM_RAINBOW_WING 483
|
||||
#define ITEM_MYSTERY_EGG 484
|
||||
#define ITEM_RED_APRICORN 485
|
||||
#define ITEM_YLW_APRICORN 486
|
||||
#define ITEM_BLU_APRICORN 487
|
||||
#define ITEM_GRN_APRICORN 488
|
||||
#define ITEM_PNK_APRICORN 489
|
||||
#define ITEM_WHT_APRICORN 490
|
||||
#define ITEM_BLK_APRICORN 491
|
||||
#define ITEM_FAST_BALL 492
|
||||
#define ITEM_LEVEL_BALL 493
|
||||
#define ITEM_LURE_BALL 494
|
||||
#define ITEM_HEAVY_BALL 495
|
||||
#define ITEM_LOVE_BALL 496
|
||||
#define ITEM_FRIEND_BALL 497
|
||||
#define ITEM_MOON_BALL 498
|
||||
#define ITEM_SPORT_BALL 499
|
||||
#define ITEM_PARK_BALL 500
|
||||
#define ITEM_PHOTO_ALBUM 501
|
||||
#define ITEM_GB_SOUNDS 502
|
||||
#define ITEM_TIDAL_BELL 503
|
||||
#define ITEM_RAGECANDYBAR 504
|
||||
#define ITEM_DATA_CARD_01 505
|
||||
#define ITEM_DATA_CARD_02 506
|
||||
#define ITEM_DATA_CARD_03 507
|
||||
#define ITEM_DATA_CARD_04 508
|
||||
#define ITEM_DATA_CARD_05 509
|
||||
#define ITEM_DATA_CARD_06 510
|
||||
#define ITEM_DATA_CARD_07 511
|
||||
#define ITEM_DATA_CARD_08 512
|
||||
#define ITEM_DATA_CARD_09 513
|
||||
#define ITEM_DATA_CARD_10 514
|
||||
#define ITEM_DATA_CARD_11 515
|
||||
#define ITEM_DATA_CARD_12 516
|
||||
#define ITEM_DATA_CARD_13 517
|
||||
#define ITEM_DATA_CARD_14 518
|
||||
#define ITEM_DATA_CARD_15 519
|
||||
#define ITEM_DATA_CARD_16 520
|
||||
#define ITEM_DATA_CARD_17 521
|
||||
#define ITEM_DATA_CARD_18 522
|
||||
#define ITEM_DATA_CARD_19 523
|
||||
#define ITEM_DATA_CARD_20 524
|
||||
#define ITEM_DATA_CARD_21 525
|
||||
#define ITEM_DATA_CARD_22 526
|
||||
#define ITEM_DATA_CARD_23 527
|
||||
#define ITEM_DATA_CARD_24 528
|
||||
#define ITEM_DATA_CARD_25 529
|
||||
#define ITEM_DATA_CARD_26 530
|
||||
#define ITEM_DATA_CARD_27 531
|
||||
#define ITEM_JADE_ORB 532
|
||||
#define ITEM_LOCK_CAPSULE 533
|
||||
#define ITEM_RED_ORB 534
|
||||
#define ITEM_BLUE_ORB 535
|
||||
#define ITEM_ENIGMA_STONE 536
|
||||
#define ITEMS_COUNT 537
|
||||
|
||||
#define TM_FOCUS_PUNCH ITEM_TM01
|
||||
#define TM_DRAGON_CLAW ITEM_TM02
|
||||
|
Loading…
x
Reference in New Issue
Block a user