From 888edf84e9dcca93ffd056846e492942c1a18e38 Mon Sep 17 00:00:00 2001 From: travi$ Date: Sat, 26 Mar 2022 21:04:47 +0300 Subject: [PATCH] Fix empty switching --- src/game/g_player.pas | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/game/g_player.pas b/src/game/g_player.pas index 8f43310..f80d721 100644 --- a/src/game/g_player.pas +++ b/src/game/g_player.pas @@ -2043,9 +2043,11 @@ function TPlayer.maySwitch(Weapon: Byte) : Boolean; begin result := true; if (Weapon = WEAPON_KASTET) and (FSkipFist <> 0) then + begin if (FSkipFist = 1) and (not (R_BERSERK in FRulez)) then - result := false - else if (FSwitchToEmpty = 0) and not hasAmmoForWeapon(Weapon) then + result := false; + end + else if (FSwitchToEmpty = 0) and (not hasAmmoForWeapon(Weapon)) then result := false end; -- 2.29.2