From d55269c1e2823591d956291e349a2ba2cd0e4e0f Mon Sep 17 00:00:00 2001 From: AirwavesMan Date: Mon, 1 Mar 2021 14:14:15 +0100 Subject: [PATCH 1/4] Switch back to foreach for server monitor --- SQF/dayz_server/system/server_monitor.sqf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SQF/dayz_server/system/server_monitor.sqf b/SQF/dayz_server/system/server_monitor.sqf index 63e027cde..fcf651f0c 100644 --- a/SQF/dayz_server/system/server_monitor.sqf +++ b/SQF/dayz_server/system/server_monitor.sqf @@ -287,7 +287,7 @@ if ((playersNumber west + playersNumber civilian) == 0) exitWith { }; dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_object]; //Monitor the object }; -} count _myArray; +} foreach _myArray; //spawn vehicles { @@ -379,7 +379,7 @@ if ((playersNumber west + playersNumber civilian) == 0) exitWith { _object enableSimulation true; _object setVelocity [0,0,1]; dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_object]; //Monitor the object -} count _VehicleQueue; +} foreach _VehicleQueue; diag_log ("HIVE: Streamed " + str((count _myArray) -_vQty) + " Objects and " + str(_vQty) + " Vehicles."); From fd6bfbbff51952b74c111de1f856ce6e3f925a76 Mon Sep 17 00:00:00 2001 From: AirwavesMan Date: Mon, 1 Mar 2021 15:23:57 +0100 Subject: [PATCH 2/4] Fix rpt errors if zombies hit players inside gyros Also zombies can punch players out of gyros now. The same way like bikes and ATVs. --- SQF/dayz_code/actions/repair_vehicle.sqf | 14 +++++++------- SQF/dayz_code/actions/salvage_vehicle.sqf | 6 ++++-- SQF/dayz_code/compile/player_zombieAttack.sqf | 14 ++++++++------ 3 files changed, 19 insertions(+), 15 deletions(-) diff --git a/SQF/dayz_code/actions/repair_vehicle.sqf b/SQF/dayz_code/actions/repair_vehicle.sqf index 30f4b65c9..bd6a3a6c6 100644 --- a/SQF/dayz_code/actions/repair_vehicle.sqf +++ b/SQF/dayz_code/actions/repair_vehicle.sqf @@ -1,11 +1,13 @@ private ["_part","_cancel","_color","_string","_handle","_damage","_cmpt","_vehicle","_hitpoints","_damagePercent","_configVeh","_hitpoint","_hits"]; _vehicle = _this select 3; -{dayz_myCursorTarget removeAction _x} count s_player_repairActions;s_player_repairActions = []; dayz_myCursorTarget = _vehicle; _hitpoints = _vehicle call vehicle_getHitpoints; +if (count _hitpoints < 1) exitwith {}; +{dayz_myCursorTarget removeAction _x} count s_player_repairActions;s_player_repairActions = []; + { _hitpoint = _x; _hits = [_vehicle,_hitpoint] call object_getHit; @@ -49,9 +51,7 @@ _hitpoints = _vehicle call vehicle_getHitpoints; } count _hitpoints; -if (count _hitpoints > 0) then { - // Localized in A2OA\Expansion\dta\languagecore - _cancel = dayz_myCursorTarget addAction [localize "str_action_cancel_action", "\z\addons\dayz_code\actions\repair_cancel.sqf","repair", 0, true, false]; - s_player_repairActions set [count s_player_repairActions,_cancel]; - s_player_repair_crtl = 1; -}; +// Localized in A2OA\Expansion\dta\languagecore +_cancel = dayz_myCursorTarget addAction [localize "str_action_cancel_action", "\z\addons\dayz_code\actions\repair_cancel.sqf","repair", 0, true, false]; +s_player_repairActions set [count s_player_repairActions,_cancel]; +s_player_repair_crtl = 1; \ No newline at end of file diff --git a/SQF/dayz_code/actions/salvage_vehicle.sqf b/SQF/dayz_code/actions/salvage_vehicle.sqf index 4432c55f5..9c95ad8da 100644 --- a/SQF/dayz_code/actions/salvage_vehicle.sqf +++ b/SQF/dayz_code/actions/salvage_vehicle.sqf @@ -2,7 +2,6 @@ private ["_isMotorcycle","_hits","_part","_color","_vehicle","_PlayerNear","_hit "_6WheelTypeArray","_NoGlassArray","_RemovedPartsArray","_damage","_cmpt","_configVeh","_damagePercent","_string","_handle","_cancel","_type"]; _vehicle = _this select 3; -{dayz_myCursorTarget removeAction _x} count s_player_repairActions;s_player_repairActions = []; _PlayerNear = {isPlayer _x} count ((getPosATL _vehicle) nearEntities ["CAManBase", 12]) > 1; if (_PlayerNear) exitWith {dayz_myCursorTarget = objNull; localize "str_pickup_limit_5" call dayz_rollingMessages;}; @@ -10,6 +9,9 @@ if (_PlayerNear) exitWith {dayz_myCursorTarget = objNull; localize "str_pickup_l dayz_myCursorTarget = _vehicle; _hitpoints = _vehicle call vehicle_getHitpoints; +if (count _hitpoints < 1) exitwith {}; +{dayz_myCursorTarget removeAction _x} count s_player_repairActions;s_player_repairActions = []; + _type = typeOf _vehicle; _isMotorcycle = _vehicle isKindOf "Motorcycle"; _is6WheelType = false; @@ -25,7 +27,7 @@ _NoGlassArray = ["HitGlass1","HitGlass2","HitGlass3","HitGlass4","HitGlass5","Hi _RemovedPartsArray = ["motor","HitLF2Wheel","HitRF2Wheel","HitBody","HitMissiles","HitHull","HitVRotor","HitFuel","HitEngine"]; if (!_is6WheelType) then { - if ((_vehicle isKindOf "ATV_Base_EP1") || {_isMotorcycle}) then { + if ((_vehicle isKindOf "ATV_Base_EP1") || _isMotorcycle) then { _hitpoints = _hitpoints - _NoGlassArray; if (_isMotorcycle) then { diff --git a/SQF/dayz_code/compile/player_zombieAttack.sqf b/SQF/dayz_code/compile/player_zombieAttack.sqf index 2992d7fc3..feefad3d5 100644 --- a/SQF/dayz_code/compile/player_zombieAttack.sqf +++ b/SQF/dayz_code/compile/player_zombieAttack.sqf @@ -117,14 +117,10 @@ _zPos = getPosASL _unit; // compute damage for vehicle and/or the player if (_isVehicle) then { if ((_unit distance player) < (3.3 * 2)) then { - _hpList = _vehicle call vehicle_getHitpoints; - _hp = _hpList call BIS_fnc_selectRandom; - _wound = getText(configFile >> "cfgVehicles" >> (typeOf _vehicle) >> "HitPoints" >> _hp >> "name"); - _damage = random 0.08; - _chance = round(random 12); + _chance = round(random 12); if ((_chance % 4) == 0) then { - _openVehicles = ["ATV_Base_EP1", "Motorcycle", "Bicycle"]; + _openVehicles = ["ATV_Base_EP1", "Motorcycle", "Bicycle", "CSJ_GyroP", "CSJ_GyroC"]; { if (_vehicle isKindOf _x) exitWith { player action ["eject", _vehicle]; @@ -132,6 +128,12 @@ if (_isVehicle) then { } count _openVehicles; }; + _hpList = _vehicle call vehicle_getHitpoints; + if (count _hpList < 1) exitwith {}; + _hp = _hpList call BIS_fnc_selectRandom; + _wound = getText(configFile >> "cfgVehicles" >> (typeOf _vehicle) >> "HitPoints" >> _hp >> "name"); + _damage = random 0.08; + if (_wound in [ "glass1", "glass2", "glass3", "glass4", "glass5", "glass6" ]) then { _dam = _vehicle getHit _wound; _total = (_dam + _damage); From 8838820ca10f1f5280dd804f73df31c46db81b97 Mon Sep 17 00:00:00 2001 From: AirwavesMan Date: Mon, 1 Mar 2021 15:24:36 +0100 Subject: [PATCH 3/4] Add high res skin for normal survivor class Thx @Helion4 --- SQF/dayz_code/Configs/CfgVehicles/Skins/Male.hpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/SQF/dayz_code/Configs/CfgVehicles/Skins/Male.hpp b/SQF/dayz_code/Configs/CfgVehicles/Skins/Male.hpp index a74ff95df..5662dc7bd 100644 --- a/SQF/dayz_code/Configs/CfgVehicles/Skins/Male.hpp +++ b/SQF/dayz_code/Configs/CfgVehicles/Skins/Male.hpp @@ -132,6 +132,8 @@ class Survivor2_DZ : Survivor_DZ { scope = 2; displayName = $STR_CHAR_1; model = "\dayz\characters\man_survivor"; + hiddenSelections[] = {"camo"}; + hiddenSelectionsTextures[] = {"\z\addons\dayz_epoch_u\clothes\male\Data\frost_1_co.paa"}; }; class Rocket_DZ: SoldierLight_Base_DZ { //BAF_Soldier_Officer_W From 31d4f156505771ad09a4d58180361eea544b971e Mon Sep 17 00:00:00 2001 From: AirwavesMan Date: Mon, 1 Mar 2021 16:32:19 +0100 Subject: [PATCH 4/4] Fix missing door model Thx @dreamforceinc --- SQF/dayz_code/Configs/CfgVehicles/Buildables/Doors.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SQF/dayz_code/Configs/CfgVehicles/Buildables/Doors.hpp b/SQF/dayz_code/Configs/CfgVehicles/Buildables/Doors.hpp index a78a18b76..030d26be7 100644 --- a/SQF/dayz_code/Configs/CfgVehicles/Buildables/Doors.hpp +++ b/SQF/dayz_code/Configs/CfgVehicles/Buildables/Doors.hpp @@ -1120,7 +1120,7 @@ class CinderGarageOpenTopLocked_DZ: CinderWallDoorLocked_DZ_Base { class CinderDoorHatch_DZ: CinderWallDoor_DZ_Base { scope = 2; - model = "\z\addons\dayz_epoch_v\base_building\cinder\cinder_door_window\cinder_door_hatch.p3d"; + model = "\z\addons\dayz_epoch_v\base_building\cinder\cinder_door_window\cinderdoor_hatch.p3d"; displayName = $STR_EPOCH_BLOCKDOOR_HATCH; GhostPreview = "CinderDoorHatch_Preview_DZ"; upgradeBuilding[] = {"CinderDoorHatchLocked_DZ",{},{{"ItemComboLock",1}}};