diff options
author | ProjectRevoTPP <projectrevotpp@hotmail.com> | 2018-02-07 00:40:17 -0500 |
---|---|---|
committer | ProjectRevoTPP <projectrevotpp@hotmail.com> | 2018-02-07 00:40:17 -0500 |
commit | 0e448936b5f77561f8bb55f3e0d27e7ed5a64c99 (patch) | |
tree | 7c529306c92bcc3e482ef4e0ac89ec941bdc4097 /src/field/bike.c | |
parent | 51ade392bf16ae4c87a18f8965b8e650fe983d03 (diff) | |
parent | a395cd7e53ed33634eef4df22814da4ba96a3357 (diff) |
Merge branch 'master' of https://github.com/pret/pokeruby
Diffstat (limited to 'src/field/bike.c')
-rw-r--r-- | src/field/bike.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/field/bike.c b/src/field/bike.c index 2d763cb14..a81aa395b 100644 --- a/src/field/bike.c +++ b/src/field/bike.c @@ -14,6 +14,11 @@ extern bool8 gBikeCyclingChallenge; extern u8 gBikeCollisions; extern u8 gUnusedBikeCameraAheadPanback; +#if DEBUG +extern u8 gUnknown_020297ED; +u8 debug_sub_805F2B0(u8); +#endif + static void MovePlayerOnMachBike(u8, u16, u16); static u8 GetMachBikeTransition(u8 *); static void MachBikeTransition_FaceDirection(u8); @@ -134,6 +139,13 @@ void MovePlayerOnBike(u8 direction, u16 newKeys, u16 heldKeys) static void MovePlayerOnMachBike(u8 direction, u16 newKeys, u16 heldKeys) { +#if DEBUG + if (gUnknown_020297ED && debug_sub_805F2B0(direction)) + { + Bike_SetBikeStill(); + return; + } +#endif sMachBikeTransitions[GetMachBikeTransition(&direction)](direction); } @@ -271,6 +283,14 @@ static void MachBikeTransition_TrySlowDown(u8 var) // the acro bike requires the input handler to be executed before the transition can. static void MovePlayerOnAcroBike(u8 newDirection, u16 newKeys, u16 heldKeys) { +#if DEBUG + if (gUnknown_020297ED && debug_sub_805F2B0(newDirection)) + { + Bike_SetBikeStill(); + return; + } +#endif + sAcroBikeTransitions[CheckMovementInputAcroBike(&newDirection, newKeys, heldKeys)](newDirection); } |