mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-26 03:34:15 +01:00
Merge branch 'master' into dump_pointers
This commit is contained in:
commit
43f23b8a78
2199
asm/bike.s
2199
asm/bike.s
File diff suppressed because it is too large
Load Diff
@ -62,7 +62,7 @@ _0809BF3C:
|
||||
cmp r6, 0
|
||||
bne _0809BFA2
|
||||
_0809BF40:
|
||||
bl sub_811A138
|
||||
bl GetPlayerSpeed
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x4
|
||||
|
@ -2027,7 +2027,7 @@ _080B6A8A:
|
||||
thumb_func_start mapldr_08084390
|
||||
mapldr_08084390: @ 80B6AA4
|
||||
push {r4,lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_black
|
||||
ldr r0, =c3_080843F8
|
||||
movs r1, 0
|
||||
@ -2113,7 +2113,7 @@ _080B6B58:
|
||||
thumb_func_start sub_80B6B68
|
||||
sub_80B6B68: @ 80B6B68
|
||||
push {lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_for_maplights
|
||||
bl ScriptContext2_Enable
|
||||
bl FreezeMapObjects
|
||||
@ -2780,7 +2780,7 @@ _080B709C:
|
||||
thumb_func_start sub_80B70B4
|
||||
sub_80B70B4: @ 80B70B4
|
||||
push {lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_for_maplights
|
||||
bl ScriptContext2_Enable
|
||||
ldr r0, =sub_80B70DC
|
||||
@ -3747,7 +3747,7 @@ _080B784C:
|
||||
thumb_func_start mapldr_080851BC
|
||||
mapldr_080851BC: @ 80B7868
|
||||
push {lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_for_maplights
|
||||
bl ScriptContext2_Enable
|
||||
ldr r0, =gFieldCallback
|
||||
@ -4458,7 +4458,7 @@ _080B7E40:
|
||||
thumb_func_start mapldr_080859D4
|
||||
mapldr_080859D4: @ 80B7E48
|
||||
push {lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_for_maplights
|
||||
bl ScriptContext2_Enable
|
||||
bl FreezeMapObjects
|
||||
@ -4903,7 +4903,7 @@ _080B81E6:
|
||||
thumb_func_start mapldr_08085D88
|
||||
mapldr_08085D88: @ 80B8200
|
||||
push {lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_for_maplights
|
||||
bl ScriptContext2_Enable
|
||||
bl FreezeMapObjects
|
||||
|
@ -57,7 +57,7 @@ player_step: @ 808A9C0
|
||||
bne _0808AA26
|
||||
adds r0, r7, 0
|
||||
adds r1, r6, 0
|
||||
bl sub_8119C3C
|
||||
bl Bike_TryAcroBikeHistoryUpdate
|
||||
adds r0, r5, 0
|
||||
mov r1, r8
|
||||
bl TryInterruptFieldObjectSpecialAnim
|
||||
@ -405,7 +405,7 @@ DoForcedMovementInCurrentDirection: @ 808AC58
|
||||
thumb_func_start ForcedMovement_Slip
|
||||
ForcedMovement_Slip: @ 808AC8C
|
||||
push {lr}
|
||||
ldr r0, =PlayerGoSpeed1
|
||||
ldr r0, =PlayerGoSpeed2
|
||||
bl DoForcedMovementInCurrentDirection
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
@ -417,7 +417,7 @@ ForcedMovement_Slip: @ 808AC8C
|
||||
thumb_func_start ForcedMovement_WalkSouth
|
||||
ForcedMovement_WalkSouth: @ 808ACA0
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed0
|
||||
ldr r1, =PlayerGoSpeed1
|
||||
movs r0, 0x1
|
||||
bl DoForcedMovement
|
||||
lsls r0, 24
|
||||
@ -430,7 +430,7 @@ ForcedMovement_WalkSouth: @ 808ACA0
|
||||
thumb_func_start ForcedMovement_WalkNorth
|
||||
ForcedMovement_WalkNorth: @ 808ACB8
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed0
|
||||
ldr r1, =PlayerGoSpeed1
|
||||
movs r0, 0x2
|
||||
bl DoForcedMovement
|
||||
lsls r0, 24
|
||||
@ -443,7 +443,7 @@ ForcedMovement_WalkNorth: @ 808ACB8
|
||||
thumb_func_start ForcedMovement_WalkWest
|
||||
ForcedMovement_WalkWest: @ 808ACD0
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed0
|
||||
ldr r1, =PlayerGoSpeed1
|
||||
movs r0, 0x3
|
||||
bl DoForcedMovement
|
||||
lsls r0, 24
|
||||
@ -456,7 +456,7 @@ ForcedMovement_WalkWest: @ 808ACD0
|
||||
thumb_func_start ForcedMovement_WalkEast
|
||||
ForcedMovement_WalkEast: @ 808ACE8
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed0
|
||||
ldr r1, =PlayerGoSpeed1
|
||||
movs r0, 0x4
|
||||
bl DoForcedMovement
|
||||
lsls r0, 24
|
||||
@ -469,7 +469,7 @@ ForcedMovement_WalkEast: @ 808ACE8
|
||||
thumb_func_start ForcedMovement_PushedSouthByCurrent
|
||||
ForcedMovement_PushedSouthByCurrent: @ 808AD00
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed2
|
||||
ldr r1, =PlayerGoSpeed3
|
||||
movs r0, 0x1
|
||||
bl DoForcedMovement
|
||||
lsls r0, 24
|
||||
@ -482,7 +482,7 @@ ForcedMovement_PushedSouthByCurrent: @ 808AD00
|
||||
thumb_func_start ForcedMovement_PushedNorthByCurrent
|
||||
ForcedMovement_PushedNorthByCurrent: @ 808AD18
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed2
|
||||
ldr r1, =PlayerGoSpeed3
|
||||
movs r0, 0x2
|
||||
bl DoForcedMovement
|
||||
lsls r0, 24
|
||||
@ -495,7 +495,7 @@ ForcedMovement_PushedNorthByCurrent: @ 808AD18
|
||||
thumb_func_start ForcedMovement_PushedWestByCurrent
|
||||
ForcedMovement_PushedWestByCurrent: @ 808AD30
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed2
|
||||
ldr r1, =PlayerGoSpeed3
|
||||
movs r0, 0x3
|
||||
bl DoForcedMovement
|
||||
lsls r0, 24
|
||||
@ -508,7 +508,7 @@ ForcedMovement_PushedWestByCurrent: @ 808AD30
|
||||
thumb_func_start ForcedMovement_PushedEastByCurrent
|
||||
ForcedMovement_PushedEastByCurrent: @ 808AD48
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed2
|
||||
ldr r1, =PlayerGoSpeed3
|
||||
movs r0, 0x4
|
||||
bl DoForcedMovement
|
||||
lsls r0, 24
|
||||
@ -548,7 +548,7 @@ ForcedMovement_Slide: @ 808AD60
|
||||
thumb_func_start ForcedMovement_SlideSouth
|
||||
ForcedMovement_SlideSouth: @ 808AD98
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed1
|
||||
ldr r1, =PlayerGoSpeed2
|
||||
movs r0, 0x1
|
||||
bl ForcedMovement_Slide
|
||||
lsls r0, 24
|
||||
@ -561,7 +561,7 @@ ForcedMovement_SlideSouth: @ 808AD98
|
||||
thumb_func_start ForcedMovement_SlideNorth
|
||||
ForcedMovement_SlideNorth: @ 808ADB0
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed1
|
||||
ldr r1, =PlayerGoSpeed2
|
||||
movs r0, 0x2
|
||||
bl ForcedMovement_Slide
|
||||
lsls r0, 24
|
||||
@ -574,7 +574,7 @@ ForcedMovement_SlideNorth: @ 808ADB0
|
||||
thumb_func_start ForcedMovement_SlideWest
|
||||
ForcedMovement_SlideWest: @ 808ADC8
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed1
|
||||
ldr r1, =PlayerGoSpeed2
|
||||
movs r0, 0x3
|
||||
bl ForcedMovement_Slide
|
||||
lsls r0, 24
|
||||
@ -587,7 +587,7 @@ ForcedMovement_SlideWest: @ 808ADC8
|
||||
thumb_func_start ForcedMovement_SlideEast
|
||||
ForcedMovement_SlideEast: @ 808ADE0
|
||||
push {lr}
|
||||
ldr r1, =PlayerGoSpeed1
|
||||
ldr r1, =PlayerGoSpeed2
|
||||
movs r0, 0x4
|
||||
bl ForcedMovement_Slide
|
||||
lsls r0, 24
|
||||
@ -630,19 +630,19 @@ ForcedMovement_MuddySlope: @ 808AE10
|
||||
ands r0, r1
|
||||
cmp r0, 0x20
|
||||
bne _0808AE36
|
||||
bl sub_811A138
|
||||
bl GetPlayerSpeed
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x3
|
||||
bgt _0808AE60
|
||||
_0808AE36:
|
||||
movs r0, 0
|
||||
bl sub_811A114
|
||||
bl Bike_UpdateBikeCounterSpeed
|
||||
ldrb r0, [r4, 0x1]
|
||||
movs r1, 0x2
|
||||
orrs r0, r1
|
||||
strb r0, [r4, 0x1]
|
||||
ldr r1, =PlayerGoSpeed1
|
||||
ldr r1, =PlayerGoSpeed2
|
||||
movs r0, 0x1
|
||||
bl DoForcedMovement
|
||||
lsls r0, 24
|
||||
@ -791,7 +791,7 @@ _0808AF4E:
|
||||
cmp r0, 0
|
||||
beq _0808AF68
|
||||
adds r0, r5, 0
|
||||
bl PlayerGoSpeed1
|
||||
bl PlayerGoSpeed2
|
||||
b _0808AFB6
|
||||
.pool
|
||||
_0808AF68:
|
||||
@ -829,7 +829,7 @@ _0808AF68:
|
||||
.pool
|
||||
_0808AFB0:
|
||||
adds r0, r5, 0
|
||||
bl PlayerGoSpeed0
|
||||
bl PlayerGoSpeed1
|
||||
_0808AFB6:
|
||||
pop {r4-r6}
|
||||
pop {r0}
|
||||
@ -1471,7 +1471,7 @@ PlayerAvatarTransition_MachBike: @ 808B46C
|
||||
bl SetPlayerAvatarStateMask
|
||||
movs r0, 0
|
||||
movs r1, 0
|
||||
bl sub_811A0D0
|
||||
bl BikeClearState
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
@ -1497,8 +1497,8 @@ PlayerAvatarTransition_AcroBike: @ 808B4A0
|
||||
bl SetPlayerAvatarStateMask
|
||||
movs r0, 0
|
||||
movs r1, 0
|
||||
bl sub_811A0D0
|
||||
bl sub_811A188
|
||||
bl BikeClearState
|
||||
bl Bike_HandleBumpySlopeJump
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
@ -1774,9 +1774,9 @@ sub_808B6BC: @ 808B6BC
|
||||
.pool
|
||||
thumb_func_end sub_808B6BC
|
||||
|
||||
thumb_func_start player_npc_set_state_and_x22_etc
|
||||
@ void player_npc_set_state_and_x22_etc(u8 animState, u8 a2)
|
||||
player_npc_set_state_and_x22_etc: @ 808B6E4
|
||||
thumb_func_start PlayerSetAnimId
|
||||
@ void PlayerSetAnimId(u8 animState, u8 a2)
|
||||
PlayerSetAnimId: @ 808B6E4
|
||||
push {r4,r5,lr}
|
||||
lsls r0, 24
|
||||
lsrs r5, r0, 24
|
||||
@ -1802,11 +1802,11 @@ _0808B712:
|
||||
pop {r0}
|
||||
bx r0
|
||||
.pool
|
||||
thumb_func_end player_npc_set_state_and_x22_etc
|
||||
thumb_func_end PlayerSetAnimId
|
||||
|
||||
thumb_func_start PlayerGoSpeed0
|
||||
@ void PlayerGoSpeed0(u8 direction)
|
||||
PlayerGoSpeed0: @ 808B720
|
||||
thumb_func_start PlayerGoSpeed1
|
||||
@ void PlayerGoSpeed1(u8 direction)
|
||||
PlayerGoSpeed1: @ 808B720
|
||||
push {lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
@ -1814,14 +1814,14 @@ PlayerGoSpeed0: @ 808B720
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end PlayerGoSpeed0
|
||||
thumb_func_end PlayerGoSpeed1
|
||||
|
||||
thumb_func_start PlayerGoSpeed1
|
||||
@ void PlayerGoSpeed1(u8 direction)
|
||||
PlayerGoSpeed1: @ 808B738
|
||||
thumb_func_start PlayerGoSpeed2
|
||||
@ void PlayerGoSpeed2(u8 direction)
|
||||
PlayerGoSpeed2: @ 808B738
|
||||
push {lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
@ -1829,14 +1829,14 @@ PlayerGoSpeed1: @ 808B738
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end PlayerGoSpeed1
|
||||
thumb_func_end PlayerGoSpeed2
|
||||
|
||||
thumb_func_start PlayerGoSpeed2
|
||||
@ void PlayerGoSpeed2(u8 direction)
|
||||
PlayerGoSpeed2: @ 808B750
|
||||
thumb_func_start PlayerGoSpeed3
|
||||
@ void PlayerGoSpeed3(u8 direction)
|
||||
PlayerGoSpeed3: @ 808B750
|
||||
push {lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
@ -1844,14 +1844,14 @@ PlayerGoSpeed2: @ 808B750
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end PlayerGoSpeed2
|
||||
thumb_func_end PlayerGoSpeed3
|
||||
|
||||
thumb_func_start PlayerGoSpeed3
|
||||
@ void PlayerGoSpeed3(u8 direction)
|
||||
PlayerGoSpeed3: @ 808B768
|
||||
thumb_func_start PlayerGoSpeed4
|
||||
@ void PlayerGoSpeed4(u8 direction)
|
||||
PlayerGoSpeed4: @ 808B768
|
||||
push {lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
@ -1859,10 +1859,10 @@ PlayerGoSpeed3: @ 808B768
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end PlayerGoSpeed3
|
||||
thumb_func_end PlayerGoSpeed4
|
||||
|
||||
thumb_func_start PlayerRun
|
||||
@ void PlayerRun(u8 direction)
|
||||
@ -1874,7 +1874,7 @@ PlayerRun: @ 808B780
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end PlayerRun
|
||||
@ -1893,7 +1893,7 @@ PlayerOnBikeCollide: @ 808B798
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
@ -1909,7 +1909,7 @@ PlayerOnBikeCollideWithFarawayIslandMew: @ 808B7BC
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end PlayerOnBikeCollideWithFarawayIslandMew
|
||||
@ -1928,7 +1928,7 @@ PlayerNotOnBikeCollide: @ 808B7D4
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
@ -1944,7 +1944,7 @@ PlayerNotOnBikeCollideWithFarawayIslandMew: @ 808B7F8
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end PlayerNotOnBikeCollideWithFarawayIslandMew
|
||||
@ -1959,7 +1959,7 @@ PlayerFaceDirection: @ 808B810
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x1
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end PlayerFaceDirection
|
||||
@ -1974,7 +1974,7 @@ PlayerTurnInPlace: @ 808B828
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x1
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end PlayerTurnInPlace
|
||||
@ -1993,7 +1993,7 @@ PlayerJumpLedge: @ 808B840
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x8
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
@ -2033,8 +2033,8 @@ _0808B89A:
|
||||
.pool
|
||||
thumb_func_end sub_808B864
|
||||
|
||||
thumb_func_start sub_808B8A8
|
||||
sub_808B8A8: @ 808B8A8
|
||||
thumb_func_start PlayerIdleWheelie
|
||||
PlayerIdleWheelie: @ 808B8A8
|
||||
push {lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
@ -2042,13 +2042,13 @@ sub_808B8A8: @ 808B8A8
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x1
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_808B8A8
|
||||
thumb_func_end PlayerIdleWheelie
|
||||
|
||||
thumb_func_start sub_808B8C0
|
||||
sub_808B8C0: @ 808B8C0
|
||||
thumb_func_start PlayerStartWheelie
|
||||
PlayerStartWheelie: @ 808B8C0
|
||||
push {lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
@ -2056,13 +2056,13 @@ sub_808B8C0: @ 808B8C0
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x1
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_808B8C0
|
||||
thumb_func_end PlayerStartWheelie
|
||||
|
||||
thumb_func_start sub_808B8D8
|
||||
sub_808B8D8: @ 808B8D8
|
||||
thumb_func_start PlayerEndWheelie
|
||||
PlayerEndWheelie: @ 808B8D8
|
||||
push {lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
@ -2070,13 +2070,13 @@ sub_808B8D8: @ 808B8D8
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x1
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_808B8D8
|
||||
thumb_func_end PlayerEndWheelie
|
||||
|
||||
thumb_func_start sub_808B8F0
|
||||
sub_808B8F0: @ 808B8F0
|
||||
thumb_func_start PlayerStandingHoppingWheelie
|
||||
PlayerStandingHoppingWheelie: @ 808B8F0
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
lsls r4, 24
|
||||
@ -2088,14 +2088,14 @@ sub_808B8F0: @ 808B8F0
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x1
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_808B8F0
|
||||
thumb_func_end PlayerStandingHoppingWheelie
|
||||
|
||||
thumb_func_start sub_808B914
|
||||
sub_808B914: @ 808B914
|
||||
thumb_func_start PlayerMovingHoppingWheelie
|
||||
PlayerMovingHoppingWheelie: @ 808B914
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
lsls r4, 24
|
||||
@ -2107,14 +2107,14 @@ sub_808B914: @ 808B914
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_808B914
|
||||
thumb_func_end PlayerMovingHoppingWheelie
|
||||
|
||||
thumb_func_start sub_808B938
|
||||
sub_808B938: @ 808B938
|
||||
thumb_func_start PlayerLedgeHoppingWheelie
|
||||
PlayerLedgeHoppingWheelie: @ 808B938
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
lsls r4, 24
|
||||
@ -2126,14 +2126,14 @@ sub_808B938: @ 808B938
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x8
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_808B938
|
||||
thumb_func_end PlayerLedgeHoppingWheelie
|
||||
|
||||
thumb_func_start sub_808B95C
|
||||
sub_808B95C: @ 808B95C
|
||||
thumb_func_start PlayerAcroTurnJump
|
||||
PlayerAcroTurnJump: @ 808B95C
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
lsls r4, 24
|
||||
@ -2145,11 +2145,11 @@ sub_808B95C: @ 808B95C
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x1
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_808B95C
|
||||
thumb_func_end PlayerAcroTurnJump
|
||||
|
||||
thumb_func_start sub_808B980
|
||||
sub_808B980: @ 808B980
|
||||
@ -2164,7 +2164,7 @@ sub_808B980: @ 808B980
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
@ -2179,7 +2179,7 @@ sub_808B9A4: @ 808B9A4
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_808B9A4
|
||||
@ -2193,7 +2193,7 @@ sub_808B9BC: @ 808B9BC
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_808B9BC
|
||||
@ -2207,7 +2207,7 @@ npc_use_some_d2s: @ 808B9D4
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x2
|
||||
bl player_npc_set_state_and_x22_etc
|
||||
bl PlayerSetAnimId
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end npc_use_some_d2s
|
||||
@ -2592,9 +2592,9 @@ sub_808BCF4: @ 808BCF4
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0808BD2C
|
||||
bl sub_811A188
|
||||
bl Bike_HandleBumpySlopeJump
|
||||
movs r0, 0
|
||||
bl sub_811A114
|
||||
bl Bike_UpdateBikeCounterSpeed
|
||||
_0808BD2C:
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
|
@ -7975,7 +7975,7 @@ _080AF120:
|
||||
sub_80AF128: @ 80AF128
|
||||
push {lr}
|
||||
bl ScriptContext2_Enable
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_black
|
||||
ldr r0, =task0A_nop_for_a_while
|
||||
movs r1, 0xA
|
||||
@ -8006,7 +8006,7 @@ _080AF160:
|
||||
sub_80AF168: @ 80AF168
|
||||
push {lr}
|
||||
bl ScriptContext2_Enable
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_black
|
||||
ldr r0, =task0A_asap_script_env_2_enable_and_set_ctx_running
|
||||
movs r1, 0xA
|
||||
@ -8092,7 +8092,7 @@ _080AF20E:
|
||||
sub_80AF214: @ 80AF214
|
||||
push {lr}
|
||||
bl ScriptContext2_Enable
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl palette_bg_faded_fill_black
|
||||
ldr r0, =task_mpl_807DD60
|
||||
movs r1, 0xA
|
||||
@ -8220,7 +8220,7 @@ _080AF30C:
|
||||
sub_80AF314: @ 80AF314
|
||||
push {lr}
|
||||
bl ScriptContext2_Enable
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl palette_bg_faded_fill_black
|
||||
ldr r0, =sub_80AF234
|
||||
movs r1, 0xA
|
||||
@ -8279,7 +8279,7 @@ _080AF37E:
|
||||
thumb_func_start mapldr_default
|
||||
mapldr_default: @ 80AF398
|
||||
push {lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_for_maplights
|
||||
bl sub_80AF334
|
||||
bl ScriptContext2_Enable
|
||||
@ -8290,7 +8290,7 @@ mapldr_default: @ 80AF398
|
||||
thumb_func_start sub_80AF3B0
|
||||
sub_80AF3B0: @ 80AF3B0
|
||||
push {lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl sub_80AF08C
|
||||
bl sub_80AF334
|
||||
bl ScriptContext2_Enable
|
||||
@ -8304,7 +8304,7 @@ sub_80AF3C8: @ 80AF3C8
|
||||
bl sub_81D6534
|
||||
cmp r0, 0
|
||||
bne _080AF3D6
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
_080AF3D6:
|
||||
bl pal_fill_black
|
||||
bl sub_80AF334
|
||||
@ -8316,7 +8316,7 @@ _080AF3D6:
|
||||
thumb_func_start sub_80AF3E8
|
||||
sub_80AF3E8: @ 80AF3E8
|
||||
push {lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_for_maplights
|
||||
movs r0, 0x2E
|
||||
bl PlaySE
|
||||
@ -8332,7 +8332,7 @@ sub_80AF3E8: @ 80AF3E8
|
||||
thumb_func_start sub_80AF40C
|
||||
sub_80AF40C: @ 80AF40C
|
||||
push {lr}
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_for_maplights
|
||||
movs r0, 0x2E
|
||||
bl PlaySE
|
||||
@ -8680,7 +8680,7 @@ sub_80AF6D4: @ 80AF6D4
|
||||
sub_80AF6F0: @ 80AF6F0
|
||||
push {lr}
|
||||
bl ScriptContext2_Enable
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl pal_fill_black
|
||||
ldr r0, =task_mpl_807E3C8
|
||||
movs r1, 0xA
|
||||
|
@ -1662,7 +1662,7 @@ _0809E572:
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0809E5D2
|
||||
bl sub_811A138
|
||||
bl GetPlayerSpeed
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x4
|
||||
|
@ -354,7 +354,7 @@ _080FD320:
|
||||
bl sav1_map_is_biking_allowed
|
||||
cmp r0, 0x1
|
||||
bne _080FD348
|
||||
bl sub_8119FF8
|
||||
bl IsBikingDisallowedByPlayer
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _080FD348
|
||||
|
@ -2212,8 +2212,8 @@ call_ResetMapMusic: @ 8085778
|
||||
bx r0
|
||||
thumb_func_end call_ResetMapMusic
|
||||
|
||||
thumb_func_start sub_8085784
|
||||
sub_8085784: @ 8085784
|
||||
thumb_func_start Overworld_PlaySpecialMapMusic
|
||||
Overworld_PlaySpecialMapMusic: @ 8085784
|
||||
push {r4,lr}
|
||||
bl sav1_map_get_music
|
||||
lsls r0, 16
|
||||
@ -2261,7 +2261,7 @@ _080857E8:
|
||||
pop {r0}
|
||||
bx r0
|
||||
.pool
|
||||
thumb_func_end sub_8085784
|
||||
thumb_func_end Overworld_PlaySpecialMapMusic
|
||||
|
||||
thumb_func_start Overworld_SetSavedMusic
|
||||
Overworld_SetSavedMusic: @ 80857F4
|
||||
|
@ -447,5 +447,5 @@ _081357EE:
|
||||
bx r0
|
||||
.pool
|
||||
thumb_func_end sub_81357BC
|
||||
|
||||
|
||||
.align 2, 0 @ Don't pad with nop.
|
||||
|
@ -1347,7 +1347,7 @@ mapldr_080CA5C0: @ 8137C5C
|
||||
push {lr}
|
||||
sub sp, 0x4
|
||||
bl ScriptContext2_Enable
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
bl sp109_CreatePCMenu
|
||||
bl sub_80E2514
|
||||
movs r0, 0x1
|
||||
@ -1412,10 +1412,10 @@ Special_ViewWallClock: @ 8137CC8
|
||||
|
||||
thumb_func_start wild_pokemon_reroll
|
||||
wild_pokemon_reroll: @ 8137CEC
|
||||
ldr r0, =gUnknown_0203AB54
|
||||
ldr r0, =gBikeCyclingChallenge
|
||||
movs r1, 0
|
||||
strb r1, [r0]
|
||||
ldr r0, =gUnknown_0203AB55
|
||||
ldr r0, =0x0203ab55
|
||||
strb r1, [r0]
|
||||
ldr r1, =gUnknown_0203AB58
|
||||
movs r0, 0
|
||||
@ -1426,10 +1426,10 @@ wild_pokemon_reroll: @ 8137CEC
|
||||
|
||||
thumb_func_start sub_8137D0C
|
||||
sub_8137D0C: @ 8137D0C
|
||||
ldr r1, =gUnknown_0203AB54
|
||||
ldr r1, =gBikeCyclingChallenge
|
||||
movs r0, 0x1
|
||||
strb r0, [r1]
|
||||
ldr r1, =gUnknown_0203AB55
|
||||
ldr r1, =0x0203ab55
|
||||
movs r0, 0
|
||||
strb r0, [r1]
|
||||
ldr r1, =gUnknown_0203AB58
|
||||
@ -1598,7 +1598,7 @@ sub_8137E6C: @ 8137E6C
|
||||
ldr r4, [r0, 0x20]
|
||||
ldr r0, [r1]
|
||||
subs r4, r0
|
||||
ldr r5, =gUnknown_0203AB55
|
||||
ldr r5, =0x0203ab55
|
||||
ldrb r1, [r5]
|
||||
adds r0, r4, 0
|
||||
bl sub_8137D5C
|
||||
|
@ -410,7 +410,7 @@ sub_80FBAE4: @ 80FBAE4
|
||||
adds r0, r4, 0x4
|
||||
lsls r0, 24
|
||||
lsrs r4, r0, 24
|
||||
bl sub_811A138
|
||||
bl GetPlayerSpeed
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x1
|
||||
@ -433,7 +433,7 @@ _080FBB2A:
|
||||
adds r0, 0x8
|
||||
lsls r0, 24
|
||||
lsrs r4, r0, 24
|
||||
bl sub_811A138
|
||||
bl GetPlayerSpeed
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x1
|
||||
|
@ -5766,7 +5766,7 @@ sub_80C58D4: @ 80C58D4
|
||||
beq _080C5914
|
||||
cmp r0, 0x2
|
||||
beq _080C591C
|
||||
bl sub_8085784
|
||||
bl Overworld_PlaySpecialMapMusic
|
||||
b _080C5924
|
||||
.pool
|
||||
_080C5914:
|
||||
|
58
data/bike.s
58
data/bike.s
@ -1,58 +0,0 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "constants/constants.inc"
|
||||
|
||||
.section .rodata
|
||||
.align 2, 0
|
||||
|
||||
gUnknown_0859744C:: @ 859744C
|
||||
.4byte sub_8119224
|
||||
.4byte sub_8119238
|
||||
.4byte sub_8119280
|
||||
.4byte sub_8119344
|
||||
|
||||
.align 2
|
||||
gUnknown_0859745C:: @ 859745C
|
||||
.4byte PlayerGoSpeed0
|
||||
.4byte PlayerGoSpeed1
|
||||
.4byte PlayerGoSpeed3
|
||||
|
||||
.align 2
|
||||
gUnknown_08597468:: @ 8597468
|
||||
.4byte sub_81197E4
|
||||
.4byte sub_81197F4
|
||||
.4byte sub_8119830
|
||||
.4byte sub_81198C0
|
||||
.4byte sub_81198FC
|
||||
.4byte sub_8119938
|
||||
.4byte sub_8119974
|
||||
.4byte sub_81199B0
|
||||
.4byte sub_8119A24
|
||||
.4byte sub_8119A94
|
||||
.4byte sub_8119AA4
|
||||
.4byte sub_8119B34
|
||||
.4byte sub_8119BC4
|
||||
|
||||
.align 2
|
||||
gUnknown_0859749C:: @ 859749C
|
||||
.4byte CheckMovementInputAcroBikeNormal
|
||||
.4byte CheckMovementInputAcroBikeChangingDirection
|
||||
.4byte CheckMovementInputAcroBikeStandingWheelie
|
||||
.4byte CheckMovementInputAcroBikeBunnyHop
|
||||
.4byte CheckMovementInputAcroBikeMovingWheelie
|
||||
.4byte CheckMovementInputAcroBikeUnknownMode5
|
||||
.4byte CheckMovementInputAcroBikeUnknownMode6
|
||||
|
||||
.align 2
|
||||
gUnknown_085974B8:: @ 85974B8
|
||||
.2byte 0x0001, 0x0002, 0x0004
|
||||
|
||||
.align 1
|
||||
gUnknown_085974BE:: @ 85974BE
|
||||
.2byte 0x0004
|
||||
|
||||
.align 2
|
||||
gUnknown_085974C0:: @ 85974C0
|
||||
.4byte 0x00000001, 0x00000002, 0x0000000f, 0x0000000f, gUnknown_085974BE, gUnknown_085974BE, 0x00000001
|
||||
.4byte 0x00000002, 0x00000002, 0x0000000f, 0x0000000f, gUnknown_085974BE, gUnknown_085974BE, 0x00000002
|
||||
.4byte 0x00000003, 0x00000002, 0x0000000f, 0x0000000f, gUnknown_085974BE, gUnknown_085974BE, 0x00000003
|
||||
.4byte 0x00000004, 0x00000002, 0x0000000f, 0x0000000f, gUnknown_085974BE, gUnknown_085974BE, 0x00000004
|
@ -163,7 +163,7 @@ gSpecials:: @ 81DBA64
|
||||
def_special sub_8138BC8
|
||||
def_special sub_8138B8C
|
||||
def_special sub_814FC9C
|
||||
def_special sub_8085784
|
||||
def_special Overworld_PlaySpecialMapMusic
|
||||
def_special StartWallClock
|
||||
def_special Special_ViewWallClock
|
||||
def_special ChooseStarter
|
||||
|
78
include/bike.h
Normal file
78
include/bike.h
Normal file
@ -0,0 +1,78 @@
|
||||
#ifndef GUARD_BIKE_H
|
||||
#define GUARD_BIKE_H
|
||||
|
||||
// the struct below is used for checking button combinations of the last input so that the acro can potentially perform a side/turn jump.
|
||||
// its possible that at some point Game Freak intended for the acro bike to have more complex tricks: but only the acro jump combinations can be seen in the final ROM.
|
||||
struct BikeHistoryInputInfo
|
||||
{
|
||||
u32 dirHistoryMatch; // the direction you need to press
|
||||
u32 abStartSelectHistoryMatch; // the button you need to press
|
||||
u32 dirHistoryMask; // mask applied so that way only the recent nybble (the recent input) is checked
|
||||
u32 abStartSelectHistoryMask; // mask applied so that way only the recent nybble (the recent input) is checked
|
||||
const u8 *dirTimerHistoryList; // list of timers to check for direction before the button+dir combination can be verified.
|
||||
const u8 *abStartSelectHistoryList; // list of timers to check for buttons before the button+dir combination can be verified.
|
||||
u32 direction; // direction to jump
|
||||
};
|
||||
|
||||
// Player speeds
|
||||
enum
|
||||
{
|
||||
SPEED_STANDING,
|
||||
SPEED_NORMAL,
|
||||
SPEED_FAST,
|
||||
SPEED_FASTER,
|
||||
SPEED_FASTEST,
|
||||
};
|
||||
|
||||
// mach bike transitions enum
|
||||
enum
|
||||
{
|
||||
MACH_TRANS_FACE_DIRECTION,
|
||||
MACH_TRANS_TURN_DIRECTION,
|
||||
MACH_TRANS_KEEP_MOVING,
|
||||
MACH_TRANS_START_MOVING
|
||||
};
|
||||
|
||||
// Acro bike states
|
||||
enum
|
||||
{
|
||||
ACRO_STATE_NORMAL,
|
||||
ACRO_STATE_TURNING,
|
||||
ACRO_STATE_WHEELIE_STANDING,
|
||||
ACRO_STATE_BUNNY_HOP,
|
||||
ACRO_STATE_WHEELIE_MOVING,
|
||||
ACRO_STATE_SIDE_JUMP,
|
||||
ACRO_STATE_TURN_JUMP,
|
||||
};
|
||||
|
||||
// Acro bike transitions
|
||||
enum
|
||||
{
|
||||
ACRO_TRANS_FACE_DIRECTION,
|
||||
ACRO_TRANS_TURN_DIRECTION,
|
||||
ACRO_TRANS_MOVING,
|
||||
ACRO_TRANS_NORMAL_TO_WHEELIE,
|
||||
ACRO_TRANS_WHEELIE_TO_NORMAL,
|
||||
ACRO_TRANS_WHEELIE_IDLE,
|
||||
ACRO_TRANS_WHEELIE_HOPPING_STANDING,
|
||||
ACRO_TRANS_WHEELIE_HOPPING_MOVING,
|
||||
ACRO_TRANS_SIDE_JUMP,
|
||||
ACRO_TRANS_TURN_JUMP,
|
||||
ACRO_TRANS_WHEELIE_MOVING,
|
||||
ACRO_TRANS_WHEELIE_RISING_MOVING,
|
||||
ACRO_TRANS_WHEELIE_LOWERING_MOVING,
|
||||
};
|
||||
|
||||
void MovePlayerOnBike(u8 direction, u16 newKeys, u16 heldKeys);
|
||||
void Bike_TryAcroBikeHistoryUpdate(u16 newKeys, u16 heldKeys);
|
||||
bool8 RS_IsRunningDisallowed(u8 tile);
|
||||
bool8 IsBikingDisallowedByPlayer(void);
|
||||
bool8 player_should_look_direction_be_enforced_upon_movement(void);
|
||||
void GetOnOffBike(u8 transitionFlags);
|
||||
void BikeClearState(int newDirHistory, int newAbStartHistory);
|
||||
void Bike_UpdateBikeCounterSpeed(u8 counter);
|
||||
s16 GetPlayerSpeed(void);
|
||||
void Bike_HandleBumpySlopeJump(void);
|
||||
bool32 IsRunningDisallowed(u8 metatile);
|
||||
|
||||
#endif // GUARD_BIKE_H
|
@ -9,6 +9,27 @@ void PlayerGetDestCoords(s16 *, s16 *);
|
||||
u8 player_get_direction_lower_nybble(void);
|
||||
u8 player_get_direction_upper_nybble(void);
|
||||
u8 player_get_x22(void);
|
||||
void PlayerGoSpeed1(u8);
|
||||
void PlayerGoSpeed2(u8);
|
||||
void PlayerGoSpeed3(u8);
|
||||
void PlayerGoSpeed4(u8);
|
||||
void PlayerOnBikeCollide(u8);
|
||||
void PlayerFaceDirection(u8 a);
|
||||
void PlayerTurnInPlace(u8 a);
|
||||
void PlayerJumpLedge(u8 a);
|
||||
void PlayerIdleWheelie(u8 a);
|
||||
void PlayerStartWheelie(u8 a);
|
||||
void PlayerEndWheelie(u8 a);
|
||||
void PlayerStandingHoppingWheelie(u8 a);
|
||||
void PlayerMovingHoppingWheelie(u8 a);
|
||||
void PlayerLedgeHoppingWheelie(u8 a);
|
||||
void PlayerAcroTurnJump(u8 a);
|
||||
void PlayerSetAnimId(u8 a, u8 b);
|
||||
bool8 IsPlayerCollidingWithFarawayIslandMew(u8 direction);
|
||||
void PlayerOnBikeCollideWithFarawayIslandMew(u8 direction);
|
||||
u8 CheckForFieldObjectCollision(struct MapObject *a, s16 b, s16 c, u8 d, u8 e);
|
||||
u8 PlayerGetZCoord(void);
|
||||
void SetPlayerAvatarTransitionFlags(u16 a);
|
||||
void sub_808BCE8(void);
|
||||
|
||||
void sub_808D074(u8);
|
||||
|
@ -299,25 +299,42 @@ enum
|
||||
COLLISION_LEDGE_JUMP = 6
|
||||
};
|
||||
|
||||
struct PlayerAvatar /* 0x202E858 */
|
||||
// player running states
|
||||
enum
|
||||
{
|
||||
NOT_MOVING,
|
||||
TURN_DIRECTION, // not the same as turning! turns your avatar without moving. also known as a turn frame in some circles
|
||||
MOVING,
|
||||
};
|
||||
|
||||
// player tile transition states
|
||||
enum
|
||||
{
|
||||
T_NOT_MOVING,
|
||||
T_TILE_TRANSITION,
|
||||
T_TILE_CENTER, // player is on a frame in which they are centered on a tile during which the player either stops or keeps their momentum and keeps going, changing direction if necessary.
|
||||
};
|
||||
|
||||
struct PlayerAvatar
|
||||
{
|
||||
/*0x00*/ u8 flags;
|
||||
/*0x01*/ u8 bike;
|
||||
/*0x02*/ u8 running2;
|
||||
/*0x03*/ u8 running1;
|
||||
/*0x01*/ u8 unk1; // used to be named bike, but its definitely not that. seems to be some transition flags
|
||||
/*0x02*/ u8 runningState; // this is a static running state. 00 is not moving, 01 is turn direction, 02 is moving.
|
||||
/*0x03*/ u8 tileTransitionState; // this is a transition running state: 00 is not moving, 01 is transition between tiles, 02 means you are on the frame in which you have centered on a tile but are about to keep moving, even if changing directions. 2 is also used for a ledge hop, since you are transitioning.
|
||||
/*0x04*/ u8 spriteId;
|
||||
/*0x05*/ u8 mapObjectId;
|
||||
/*0x06*/ u8 unk6;
|
||||
/*0x06*/ bool8 preventStep;
|
||||
/*0x07*/ u8 gender;
|
||||
u8 acroBikeState;
|
||||
u8 unk9;
|
||||
u8 bikeFrameCounter;
|
||||
u8 unkB;
|
||||
u32 unkC;
|
||||
u32 unk10;
|
||||
u8 unk14[8];
|
||||
u8 unk1C[8];
|
||||
// TODO: rest of struct
|
||||
/*0x08*/ u8 acroBikeState; // 00 is normal, 01 is turning, 02 is standing wheelie, 03 is hopping wheelie
|
||||
/*0x09*/ u8 newDirBackup; // during bike movement, the new direction as opposed to player's direction is backed up here.
|
||||
/*0x0A*/ u8 bikeFrameCounter; // on the mach bike, when this value is 1, the bike is moving but not accelerating yet for 1 tile. on the acro bike, this acts as a timer for acro bike.
|
||||
/*0x0B*/ u8 bikeSpeed;
|
||||
// acro bike only
|
||||
/*0x0C*/ u32 directionHistory; // up/down/left/right history is stored in each nybble, but using the field directions and not the io inputs.
|
||||
/*0x10*/ u32 abStartSelectHistory; // same as above but for A + B + start + select only
|
||||
// these two are timer history arrays which [0] is the active timer for acro bike. every element is backed up to the next element upon update.
|
||||
/*0x14*/ u8 dirTimerHistory[8];
|
||||
/*0x1C*/ u8 abStartSelectTimerHistory[8];
|
||||
};
|
||||
|
||||
struct Camera
|
||||
|
@ -163,7 +163,7 @@ SECTIONS {
|
||||
asm/contest_link_80FC4F4.o(.text);
|
||||
asm/item_use.o(.text);
|
||||
asm/battle_anim_80FE840.o(.text);
|
||||
asm/bike.o(.text);
|
||||
src/bike.o(.text);
|
||||
asm/easy_chat.o(.text);
|
||||
asm/mon_markings.o(.text);
|
||||
asm/mauville_old_man.o(.text);
|
||||
@ -416,7 +416,7 @@ SECTIONS {
|
||||
data/rotating_gate.o(.rodata);
|
||||
data/item_use.o(.rodata);
|
||||
data/battle_anim_80FE840.o(.rodata);
|
||||
data/bike.o(.rodata);
|
||||
src/bike.o(.rodata);
|
||||
data/easy_chat.o(.rodata);
|
||||
data/mon_markings.o(.rodata);
|
||||
data/mauville_old_man.o(.rodata);
|
||||
|
1078
src/bike.c
Normal file
1078
src/bike.c
Normal file
File diff suppressed because it is too large
Load Diff
@ -86,7 +86,7 @@ extern void sub_806A068(u16, u8);
|
||||
extern void sub_807F19C(void);
|
||||
extern void sub_807B140(void);
|
||||
extern void EvolutionRenameMon(struct Pokemon *mon, u16 oldSpecies, u16 newSpecies);
|
||||
extern void sub_8085784(void);
|
||||
extern void Overworld_PlaySpecialMapMusic(void);
|
||||
extern void sub_81BFA38(struct Pokemon *party, u8 monId, u8 partyCount, void *CB2_ptr, u16 move);
|
||||
extern u8 sub_81C1B94(void);
|
||||
extern void sub_807F1A8(u8 arg0, const u8 *arg1, u8 arg2);
|
||||
@ -698,7 +698,7 @@ static void Task_EvolutionScene(u8 taskID)
|
||||
if (!(gTasks[taskID].tBits & TASK_BIT_LEARN_MOVE))
|
||||
{
|
||||
StopMapMusic();
|
||||
sub_8085784();
|
||||
Overworld_PlaySpecialMapMusic();
|
||||
}
|
||||
|
||||
gTasks[taskID].tBits |= TASK_BIT_LEARN_MOVE;
|
||||
@ -727,7 +727,7 @@ static void Task_EvolutionScene(u8 taskID)
|
||||
if (!(gTasks[taskID].tBits & TASK_BIT_LEARN_MOVE))
|
||||
{
|
||||
StopMapMusic();
|
||||
sub_8085784();
|
||||
Overworld_PlaySpecialMapMusic();
|
||||
}
|
||||
if (!gTasks[taskID].tEvoWasStopped)
|
||||
CreateShedinja(gTasks[taskID].tPreEvoSpecies, mon);
|
||||
|
@ -3231,7 +3231,7 @@ bool8 mss_npc_reset_oampriv3_1_unk2_unk3(struct MapObject *mapObject, struct Spr
|
||||
|
||||
bool8 sub_8091EC0(struct MapObject *mapObject, struct Sprite *sprite)
|
||||
{
|
||||
if (gMapObjects[gPlayerAvatar.mapObjectId].mapobj_unk_1C == 0xFF || gPlayerAvatar.running1 == 2)
|
||||
if (gMapObjects[gPlayerAvatar.mapObjectId].mapobj_unk_1C == 0xFF || gPlayerAvatar.tileTransitionState == 2)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
@ -3410,7 +3410,7 @@ field_object_step(CopyPlayer2, gUnknown_0850DA90)
|
||||
|
||||
bool8 mss_08062EA4(struct MapObject *mapObject, struct Sprite *sprite)
|
||||
{
|
||||
if (gMapObjects[gPlayerAvatar.mapObjectId].mapobj_unk_1C == 0xFF || gPlayerAvatar.running1 == 2)
|
||||
if (gMapObjects[gPlayerAvatar.mapObjectId].mapobj_unk_1C == 0xFF || gPlayerAvatar.tileTransitionState == 2)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
@ -1118,10 +1118,10 @@ gUnknown_0203AB40: @ 203AB40
|
||||
|
||||
.include "src/pokeblock.o"
|
||||
|
||||
gUnknown_0203AB54: @ 203AB54
|
||||
gBikeCyclingChallenge: @ 203AB54
|
||||
.space 0x1
|
||||
|
||||
gUnknown_0203AB55: @ 203AB55
|
||||
gBikeCollisions: @ 203AB55
|
||||
.space 0x3
|
||||
|
||||
gUnknown_0203AB58: @ 203AB58
|
||||
|
Loading…
Reference in New Issue
Block a user