Skip to content

Commit

Permalink
tr2/lara/cheat: reset gun status if undrawing weapons
Browse files Browse the repository at this point in the history
This fixes guns potentially appearing in Lara's hand while entering the
fly cheat and the weapon undraw animation is still running.

Resolves LostArtefacts#2376.
  • Loading branch information
lahm86 committed Jan 25, 2025
1 parent 529d482 commit 6074f9a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions docs/tr2/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
- fixed Skidoo snow wake effects at slow speeds (#2324, regression from 0.6)
- fixed software renderer skybox occlusion issues (#2343, regression from 0.7)
- fixed gunflare from bandits in Tibetan levels spawning too far from their guns (#2365, regression from 0.8)
- fixed guns sometimes appearing in Lara's hands when entering the fly cheat while undrawing weapons (#2376, regression from 0.3)
- improved rendering to achieve a slight performance boost in big rooms (#2325)

## [0.8](https://github.com/LostArtefacts/TRX/compare/tr2-0.8...tr2-0.8) - 2025-01-01
Expand Down
3 changes: 2 additions & 1 deletion src/tr2/game/lara/cheat.c
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,8 @@ bool Lara_Cheat_EnterFlyMode(void)
M_ResetGunStatus();
}

if (g_Lara.gun_status == LGS_HANDS_BUSY) {
if (g_Lara.gun_status == LGS_HANDS_BUSY
|| (g_Lara.gun_status == LGS_UNDRAW && g_Lara.back_gun != O_LARA)) {
g_Lara.gun_status = LGS_ARMLESS;
}

Expand Down

0 comments on commit 6074f9a

Please sign in to comment.