- fixed: player_t::Uncrouch should only reset the view height if the player is actually crouched.

This commit is contained in:
Christoph Oelckers 2016-01-31 22:36:37 +01:00
parent c3cc98b5f3
commit 8068fca601

View file

@ -487,12 +487,15 @@ public:
void Uncrouch() void Uncrouch()
{ {
crouchfactor = FRACUNIT; if (crouchfactor != FRACUNIT)
crouchoffset = 0; {
crouchdir = 0; crouchfactor = FRACUNIT;
crouching = 0; crouchoffset = 0;
crouchviewdelta = 0; crouchdir = 0;
viewheight = mo->ViewHeight; crouching = 0;
crouchviewdelta = 0;
viewheight = mo->ViewHeight;
}
} }
bool CanCrouch() const bool CanCrouch() const