diff --git a/SQF/dayz_code/init/variables.sqf b/SQF/dayz_code/init/variables.sqf index 9ad05e645..5fce57735 100644 --- a/SQF/dayz_code/init/variables.sqf +++ b/SQF/dayz_code/init/variables.sqf @@ -529,6 +529,9 @@ DZE_Lock_Door = ""; call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\loot_init.sqf"; if(isServer) then { + if (isNil "DZE_PlayerZed") then { + DZE_PlayerZed = true; + }; dayz_players = []; DZEMaintainCache = []; dead_bodyCleanup = []; diff --git a/SQF/dayz_server/compile/server_playerLogin.sqf b/SQF/dayz_server/compile/server_playerLogin.sqf index b0758b4a7..730fd4e1d 100644 --- a/SQF/dayz_server/compile/server_playerLogin.sqf +++ b/SQF/dayz_server/compile/server_playerLogin.sqf @@ -91,7 +91,11 @@ if (!_isNew) then { }; } else { - _isInfected = _primary select 3; + if (DZE_PlayerZed) then { + _isInfected = _primary select 3; + } else { + _isInfected = 0; + }; _model = _primary select 4; _hiveVer = _primary select 5; @@ -103,6 +107,7 @@ if (!_isNew) then { }; }; + //Record initial inventory only if not player zombie if(_isInfected != 1) then { _config = (configFile >> "CfgSurvival" >> "Inventory" >> "Default");