diff --git a/CHANGE LOG 1.0.6.2.txt b/CHANGE LOG 1.0.6.2.txt index b72a74aba..749b99834 100644 --- a/CHANGE LOG 1.0.6.2.txt +++ b/CHANGE LOG 1.0.6.2.txt @@ -51,6 +51,7 @@ [FIXED] The dramatic recoil camera shake effect from a nearby bullet hit is now reset correctly instead of remaining permanent. [FIXED] Added temporary fix for missing AS50 ammo error with beta branch core patch. #1955 @AirwavesMan [FIXED] Melee and tranquilizer bolt knockouts were usually instant or far shorter than the intended time of 20s-80s. +[FIXED] Multiple dupe fixes [NOTE] Fixes below are included in the mission file and server pbo as part of server package 1.0.6.1A (March 10th 2017) [FIXED] Fixed food and drink going down 10x faster from melee and other "working" actions. diff --git a/SQF/dayz_code/compile/player_switchModel.sqf b/SQF/dayz_code/compile/player_switchModel.sqf index 8db173080..ea88692e3 100644 --- a/SQF/dayz_code/compile/player_switchModel.sqf +++ b/SQF/dayz_code/compile/player_switchModel.sqf @@ -1,5 +1,11 @@ -private ["_weapons","_backpackWpn","_backpackMag","_currentWpn","_isWeapon","_backpackWpnTypes","_backpackWpnQtys","_countr","_class","_position","_dir","_currentAnim","_playerUID","_countMags","_magazines","_primweapon","_secweapon","_newBackpackType","_muzzles","_oldUnit","_group","_newUnit","_oldGroup","_idc","_display","_switchUnit","_leader","_currentCamera"]; -_class = _this; +private ["_weapons","_CID","_backpackWpn","_backpackMag","_currentWpn","_isWeapon","_backpackWpnTypes","_backpackWpnQtys","_countr","_class","_position","_dir","_currentAnim","_playerUID","_countMags","_magazines","_primweapon","_secweapon","_newBackpackType","_muzzles","_oldUnit","_group","_newUnit","_oldGroup","_idc","_display","_switchUnit","_leader","_currentCamera"]; +if (typeName _this == "ARRAY") then { + _class = _this select 0; + _CID = _this select 1; +} else { + _class = _this; +}; + if (gear_done) then {disableUserInput true;disableUserInput true;}; disableSerialization; //Old location system causes issues with players getting damaged during movement. @@ -74,10 +80,13 @@ _leader = (player == leader _oldGroup); //[player] joinSilent grpNull; _group = createGroup west; _newUnit = _group createUnit [_class,respawn_west_original,[],0,"NONE"]; +_newUnit allowDamage false; _newUnit setDir _dir; {_newUnit removeMagazine _x;} count magazines _newUnit; removeAllWeapons _newUnit; +if (!isnil "_CID") then {_newUnit setVariable ["characterID",_CID,true];}; //set early to prevent dupe + //Equip New Character { if (typeName _x == "ARRAY") then {if (count _x > 0) then {_newUnit addMagazine [_x select 0,_x select 1]; }; } else { _newUnit addMagazine _x; }; diff --git a/SQF/dayz_code/init/publicEH.sqf b/SQF/dayz_code/init/publicEH.sqf index dfde85b80..c428c3a08 100644 --- a/SQF/dayz_code/init/publicEH.sqf +++ b/SQF/dayz_code/init/publicEH.sqf @@ -105,7 +105,8 @@ if (isServer) then { if (dayz_groupSystem) then { "PVDZ_Server_UpdateGroup" addPublicVariableEventHandler {(_this select 1) spawn server_updateGroup}; }; - + "PVDZE_PingSend" addPublicVariableEventHandler {PVDZE_PingReceived = 1; (owner (_this select 1)) publicVariableClient "PVDZE_PingReceived";}; + //Added as part of the maintenance system to allow the server to replace the damaged model with a normal model. /*"PVDZ_object_replace" addPublicVariableEventHandler { _object = _this select 1; @@ -322,4 +323,5 @@ if (!isDedicated) then { // flies and swarm sound sync call compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\client_flies.sqf"; }; + "PVDZE_PingReceived" addPublicVariableEventHandler {DZE_LastPingResp = diag_tickTime;}; }; diff --git a/SQF/dayz_code/init/variables.sqf b/SQF/dayz_code/init/variables.sqf index 7e275c898..bf4b10ad9 100644 --- a/SQF/dayz_code/init/variables.sqf +++ b/SQF/dayz_code/init/variables.sqf @@ -567,6 +567,7 @@ if (isServer) then { }; if (!isDedicated) then { + DZE_LastPingResp = diag_tickTime; dayz_buildingBubbleMonitor = []; DayZ_fuelCans = ["ItemJerrycan","ItemFuelcan","ItemFuelBarrel"]; DayZ_fuelCansEmpty = ["ItemJerrycanEmpty","ItemFuelcanEmpty","ItemFuelBarrelEmpty"];