diff --git a/docs/progress.svg b/docs/progress.svg index ab1c1fc07..3ad7186d6 100644 --- a/docs/progress.svg +++ b/docs/progress.svg @@ -338,7 +338,7 @@ - + @@ -700,10 +700,10 @@ -Functions decompiled (count): 6.13% -Functions decompiled (bytesize): 3.42% -Functions not decompiled, but with known names (count): 74.61% -Functions not decompiled, but with known names (bytesize): 76.55% +Functions decompiled (count): 6.28% +Functions decompiled (bytesize): 3.43% +Functions not decompiled, but with known names (count): 74.47% +Functions not decompiled, but with known names (bytesize): 76.54% Functions not decompiled, with unknown names (count): 19.26% Functions not decompiled, with unknown names (bytesize): 20.03% diff --git a/docs/progress.txt b/docs/progress.txt index f3eb12f36..494b214a3 100644 --- a/docs/progress.txt +++ b/docs/progress.txt @@ -342,7 +342,7 @@ LaraAsFastTurn 0x00422F30 0x0000004B + LaraAsStepRight 0x00422F80 0x00000073 + LaraAsStepLeft 0x00423000 0x00000073 + LaraAsSlide 0x00423080 0x00000027 + -LaraAsBackJump 0x004230B0 0x0000001C - +LaraAsBackJump 0x004230B0 0x0000001C + LaraAsRightJump 0x004230D0 0x00000013 - LaraAsFallback 0x004230F0 0x0000002C - LaraAsHangLeft 0x00423120 0x00000035 - diff --git a/src/game/lara.c b/src/game/lara.c index e52e3617a..8fd525bb6 100644 --- a/src/game/lara.c +++ b/src/game/lara.c @@ -436,6 +436,14 @@ void __cdecl LaraAsSlide(ITEM_INFO* item, COLL_INFO* coll) } } +void __cdecl LaraAsBackJump(ITEM_INFO* item, COLL_INFO* coll) +{ + Camera.target_angle = ONE_DEGREE * 135; + if (item->fall_speed > LARA_FASTFALL_SPEED) { + item->goal_anim_state = AS_FASTFALL; + } +} + int16_t __cdecl LaraFloorFront(ITEM_INFO* item, PHD_ANGLE ang, int32_t dist) { int32_t x = item->pos.x + ((phd_sin(ang) * dist) >> W2V_SHIFT); @@ -467,4 +475,5 @@ void TR1MInjectLara() INJECT(0x00422F80, LaraAsStepRight); INJECT(0x00423000, LaraAsStepLeft); INJECT(0x00423080, LaraAsSlide); + INJECT(0x004230B0, LaraAsBackJump); } diff --git a/src/game/lara.h b/src/game/lara.h index 1b244e65c..83a62c347 100644 --- a/src/game/lara.h +++ b/src/game/lara.h @@ -30,6 +30,7 @@ void __cdecl LaraAsFastTurn(ITEM_INFO* item, COLL_INFO* coll); void __cdecl LaraAsStepRight(ITEM_INFO* item, COLL_INFO* coll); void __cdecl LaraAsStepLeft(ITEM_INFO* item, COLL_INFO* coll); void __cdecl LaraAsSlide(ITEM_INFO* item, COLL_INFO* coll); +void __cdecl LaraAsBackJump(ITEM_INFO* item, COLL_INFO* coll); int16_t __cdecl LaraFloorFront(ITEM_INFO* item, PHD_ANGLE ang, int32_t dist); void __cdecl UseItem(__int16 object_num);