1
0
mirror of https://github.com/luanti-org/luanti.git synced 2026-01-13 04:35:28 +01:00

Allow sneak toggling when player does not have the fly priv (#16781)

This commit is contained in:
y5nw
2026-01-04 15:01:15 +01:00
committed by GitHub
parent f10203606a
commit ae9843cf3c

View File

@@ -2016,7 +2016,7 @@ void Game::updatePlayerControl(const CameraOrientation &cam)
// In free move (fly), the "toggle_sneak_key" setting would prevent precise
// up/down movements. Hence, enable the feature only during 'normal' movement.
const bool allow_sneak_toggle = m_cache_toggle_sneak_key &&
!player->getPlayerSettings().free_move;
!(player->getPlayerSettings().free_move && client->checkPrivilege("fly"));
//TimeTaker tt("update player control", NULL, PRECISION_NANO);