Lower numpad minus keydown timer for block cheats

Fewer false positives
This commit is contained in:
ebaydayz
2016-12-04 11:37:03 -05:00
parent f03f116dfc
commit 7af0cb2910

View File

@@ -21,7 +21,7 @@ _channelChange = _micIcon && ((!isNull findDisplay 24 && _dik in [DIK_DOWN,DIK_U
_blockVoice = _channelChange or ((_dik in voice_keys or (_inputAction1 > 0)) && (_channel in DZE_DisabledChannels)); _blockVoice = _channelChange or ((_dik in voice_keys or (_inputAction1 > 0)) && (_channel in DZE_DisabledChannels));
if (_dik == DIK_NUMPADMINUS) then {dayz_minusDownTime = diag_tickTime;}; if (_dik == DIK_NUMPADMINUS) then {dayz_minusDownTime = diag_tickTime;};
_blockCheat = (_dik == DIK_NUMPADMINUS && _shift) or (_dik == DIK_LSHIFT && (diag_tickTime - dayz_minusDownTime < 2)); _blockCheat = (_dik == DIK_NUMPADMINUS && _shift) or (_dik == DIK_LSHIFT && (diag_tickTime - dayz_minusDownTime < 1));
if (_blockCheat or _blockVoice) then { if (_blockCheat or _blockVoice) then {
if (_blockCheat) then {call player_forceSave;}; //Perform before disableUserInput to prevent reenable if (_blockCheat) then {call player_forceSave;}; //Perform before disableUserInput to prevent reenable