Revert "editor camera bugfix"

This reverts commit eae77fec5c.
This commit is contained in:
Bukz
2023-06-17 13:39:17 -04:00
parent eae77fec5c
commit 13f0d8eea4
2 changed files with 2 additions and 3 deletions
Binary file not shown.
+2 -3
View File
@@ -475,12 +475,11 @@ void moveplayer(physent *pl, int moveres, bool local, int curtime)
if(editfly) // just apply velocity
{
pl->o.add(d);
Uint8 const* state = SDL_GetKeyboardState(0);
if(pl->jumpnext)
if(pl->jumpnext && !pl->trycrouch)
{
pl->vel.z = 0.5f; // fly directly upwards while holding jump keybinds
}
else if (state[SDL_SCANCODE_LSHIFT] != 0 || state[SDL_SCANCODE_RSHIFT] != 0)
else if (pl->trycrouch && !pl->jumpnext)
{
pl->vel.z = -0.5f; // fly directly down while holding crouch keybinds
}