From b92880b98387c6fa6e6ebaf6a956cecb00bba8e8 Mon Sep 17 00:00:00 2001 From: vbawol Date: Wed, 14 Oct 2015 16:39:30 -0500 Subject: [PATCH 1/3] changelog --- Changelogs/0.3.4.0.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Changelogs/0.3.4.0.txt b/Changelogs/0.3.4.0.txt index f3205705..e53939fb 100644 --- a/Changelogs/0.3.4.0.txt +++ b/Changelogs/0.3.4.0.txt @@ -13,6 +13,7 @@ Client: [Fixed] Being unable to remove a solar generator. [Fixed] Angry Pumpkin mask was incorrectly visible in first person. [Fixed] Issue with Headless clients being treated as players. @dayzai/Face +[Changed] Fixed boats spawning on land and added 3d waypoint to purchased vehicle location. [Changed] Removed debug hint text for 3d rotation of objects as it was not needed. [Changed] Re-enable Move button, this system will stay and be refined in the next few patches. **Improved Dog AI Dog Brain by Axeman** From d95edc9a2ea7edef5855772bbbd00c64771a8c6a Mon Sep 17 00:00:00 2001 From: vbawol Date: Thu, 15 Oct 2015 19:47:34 -0500 Subject: [PATCH 2/3] recoded to fix secure storage unlock not working on first placement --- .../@epochhive/addons/a3_epoch_server.pbo | Bin 361780 -> 361173 bytes .../epoch_bases/EPOCH_server_saveBuilding.sqf | 131 ++++++++---------- 2 files changed, 56 insertions(+), 75 deletions(-) diff --git a/Server_Install_Pack/@epochhive/addons/a3_epoch_server.pbo b/Server_Install_Pack/@epochhive/addons/a3_epoch_server.pbo index 20dee4069579a2759aadb96d30627cf7705bb795..34df80c2ea26167e4a47c413083d1758cd74c0f4 100644 GIT binary patch delta 1016 zcmah{OK1~O6lEqcW)j<^X>TsS9d<69 zD&1uju7$DSH>dBiHH8J90ArC#HSoR~*zK*c;P)WH0E~J+TQKe_Li6Q))&mdAURm6r z8@c81)OTeLs<)LQ3d3l5h83Ry<8QWlqUFd|LB_w@Hrh%Gra!}Ax$v#xLyPHi+5+Hd z_W&7mL3JVuZHf3IGBiZey1^T=uu0){oyhuDIWKlfWC`4eES|SyIWe*{f2hP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ld6hK(H88~TIwEX zfI+RPTuv`MMVt;bJ282DO9va4RZwLQdw6Nhi))&nT}DThYegHtuUeG7h6D8VHO^PL zi1dzy_~?Z`vlT~;dNijxEW!et=#5b7Oen>zhEk;VAm6vYzpuCd%;-hJKGW*xMYFN# bKEHbXt>v*7dOrE^(6K9%mPZ!XQy=^Vq<(On diff --git a/Sources/epoch_server/compile/epoch_bases/EPOCH_server_saveBuilding.sqf b/Sources/epoch_server/compile/epoch_bases/EPOCH_server_saveBuilding.sqf index a03b1340..b66f94c0 100644 --- a/Sources/epoch_server/compile/epoch_bases/EPOCH_server_saveBuilding.sqf +++ b/Sources/epoch_server/compile/epoch_bases/EPOCH_server_saveBuilding.sqf @@ -17,37 +17,77 @@ _plyrUID = getPlayerUID _plyr; if (!isNull ropeAttachedTo _vehicle) exitWith{}; _oemType = typeOf _vehicle; + _config = (configFile >> "CfgVehicles" >> _oemType >> "staticClass"); if (isText _config) then { + _staticClass = getText(_config); - if (_staticClass isKindOf "Buildable_Storage") then { + if (_staticClass isKindOf "Buildable_Storage" || _staticClass isKindOf "Constructions_lockedstatic_F") then{ if !(EPOCH_StorageSlots isEqualTo[]) then { - _config = (configFile >> "CfgVehicles" >> _oemType >> "staticClass"); - if (isText(_config)) then { + _slot = EPOCH_StorageSlots deleteAt 0; + EPOCH_StorageSlotsCount = count EPOCH_StorageSlots; + publicVariable "EPOCH_StorageSlotsCount"; - _slot = EPOCH_StorageSlots select 0; - EPOCH_StorageSlots = EPOCH_StorageSlots - [_slot]; + // Secure storage + if (getNumber(configFile >> "CfgVehicles" >> _staticClass >> "isSecureStorage") == 1) then{ + // remove sim _vehiclePos = getposATL _vehicle; - _worldspace = [(_vehiclePos call EPOCH_precisionPos), vectordir _vehicle, vectorup _vehicle]; + _vectorDirAndUp = [vectordir _vehicle, vectorup _vehicle]; deleteVehicle _vehicle; - _storageObj = createVehicle[_staticClass, _vehiclePos, [], 0, "CAN_COLLIDE"]; - _storageObj setVariable["STORAGE_SLOT", _slot, true]; + // create static dummy placeholder for secure storage + _newVehicle = createVehicle[_staticClass, _vehiclePos, [], 0, "CAN_COLLIDE"]; + _newVehicle setVectorDirAndUp _vectorDirAndUp; + _newVehicle setposATL _vehiclePos; - _storageObj setVectorDirAndUp[_worldspace select 1, _worldspace select 2]; + if (!isNull _newVehicle) then{ + + _buildClass = getText(configFile >> "CfgVehicles" >> _staticClass >> "weaponHolderProxy"); + if (_buildClass != "") then{ + + // TODO need some sanity checks here + _storageObj = createVehicle[_buildClass, _vehiclePos, [], 0.0, "CAN_COLLIDE"]; + _storageObj setVectorDirAndUp _vectorDirAndUp; + _storageObj setposATL _vehiclePos; + + // set reference to storage object on dummy object + _newVehicle = setVariable["EPOCH_secStorParent", _storageObj]; + + _storageObj setVariable["EPOCH_Locked", false, true]; + _storageObj setVariable["STORAGE_OWNERS", [_plyrUID]]; + _storageObj setVariable["STORAGE_SLOT", _slot, true]; + + _storageObj call EPOCH_server_save_storage; + _storageObj call EPOCH_server_storageInit; + + diag_log format["STORAGE: %1 created storage %2 at %3", _plyrUID, _buildClass, _pos]; + + }; + }; + + // insecure storage + } else { + + _vehiclePos = getposATL _vehicle; + _vectorDirAndUp = [vectordir _vehicle, vectorup _vehicle]; + deleteVehicle _vehicle; + + _storageObj = createVehicle[_staticClass, _vehiclePos, [], 0, "CAN_COLLIDE"]; + _storageObj setVectorDirAndUp _vectorDirAndUp; _storageObj setposATL _vehiclePos; + _storageObj setVariable["STORAGE_OWNERS", [_plyrUID]]; + _storageObj setVariable["STORAGE_SLOT", _slot, true]; + _storageObj call EPOCH_server_save_storage; _storageObj call EPOCH_server_storageInit; - diag_log format["STORAGE: %1 created storage %2 at %3", getPlayerUID _plyr, _staticClass, _vehiclePos]; + diag_log format["STORAGE: %1 created storage %2 at %3", _plyrUID, _staticClass, _vehiclePos]; - EPOCH_StorageSlotsCount = count EPOCH_StorageSlots; - publicVariable "EPOCH_StorageSlotsCount"; }; }; @@ -57,81 +97,22 @@ if (isText _config) then { if (_vehicle isKindOf "ThingX" || _vehicle isKindOf "Const_Ghost_EPOCH" || _vehicle isKindOf "PlotPole_EPOCH") then { _objSlot = _vehicle getVariable["BUILD_SLOT", -1]; - if (_objSlot == -1) then { + if (_objSlot == -1) then{ _findnextslot = EPOCH_BuildingSlots find 0; - if (_findnextslot != -1) then { + if (_findnextslot != -1) then{ _objSlot = _findnextslot; - EPOCH_BuildingSlots set [_findnextslot,1]; + EPOCH_BuildingSlots set[_findnextslot, 1]; _vehicle setVariable["BUILD_SLOT", _findnextslot, true]; }; }; - // get texture slot index - _textureSlot = _vehicle getVariable["TEXTURE_SLOT", 0]; - EPOCH_BuildingSlotCount = { _x == 0 } count EPOCH_BuildingSlots; publicVariable "EPOCH_BuildingSlotCount"; - if (_objSlot != -1) then { - _vehiclePos = getposATL _vehicle; - // _worldspace = [(_vehiclePos call EPOCH_precisionPos), vectordir _vehicle, vectorup _vehicle]; - // _objHiveKey = format["%1:%2", (call EPOCH_fn_InstanceID), _objSlot]; - _newVehicle = [_vehicle, false] call EPOCH_server_simulSwap; - _newVehicle setVariable["BUILD_OWNER", _plyrUID, true]; - - _slot = "-1"; - if (getNumber(configFile >> "CfgVehicles" >> _staticClass >> "isSecureStorage") == 1) then{ - - //diag_log format["building lockbox %1", _oemType]; - - _buildClass = getText(configFile >> "CfgVehicles" >> _staticClass >> "weaponHolderProxy"); - - if (!isNull _newVehicle) then { - - //diag_log format["building lockbox !isnull %1", _newVehicle]; - - if !(EPOCH_StorageSlots isEqualTo []) then { - - //diag_log format["building lockbox findslot %1", _newVehicle]; - if (_buildClass != "") then{ - - // TODO need some sanity checks here - _storageObj = createVehicle[_buildClass, _vehiclePos, [], 0.0, "CAN_COLLIDE"]; - - _slot = EPOCH_StorageSlots select 0; - EPOCH_StorageSlots = EPOCH_StorageSlots - [_slot]; - - //diag_log format["building lockbox found slot %1", _slot]; - - // missionNamespace setVariable[format["EPOCH_STORAGE_%1", _slot], _storageObj]; - - _newVehicle setVariable["EPOCH_secureStorage", _slot]; - - _newVehicle setVariable["EPOCH_Locked", false, true]; - - _storageObj setVariable["STORAGE_OWNERS", [_plyrUID]]; - - // _storageObj setVariable["EPOCH_secStorParent", _objSlot]; - _storageObj setVariable["STORAGE_SLOT", _slot, true]; - - _storageObj call EPOCH_server_save_storage; - - _storageObj call EPOCH_server_storageInit; - - diag_log format["STORAGE: %1 created storage %2 at %3", _plyrUID, _buildClass, _pos]; - - EPOCH_StorageSlotsCount = count EPOCH_StorageSlots; - publicVariable "EPOCH_StorageSlotsCount"; - }; - }; - }; - } else { - _newVehicle call EPOCH_fnc_saveBuilding; - }; - + _newVehicle call EPOCH_fnc_saveBuilding; }; } else { From bf9531a0cafb91056f0305b8e49f7c3537c3c985 Mon Sep 17 00:00:00 2001 From: vbawol Date: Thu, 15 Oct 2015 22:09:06 -0500 Subject: [PATCH 3/3] fixed typo --- .../@epochhive/addons/a3_epoch_server.pbo | Bin 361173 -> 361171 bytes .../epoch_bases/EPOCH_server_saveBuilding.sqf | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/Server_Install_Pack/@epochhive/addons/a3_epoch_server.pbo b/Server_Install_Pack/@epochhive/addons/a3_epoch_server.pbo index 34df80c2ea26167e4a47c413083d1758cd74c0f4..dcf3376b2557635d6b40be92d92a08bbba749b5d 100644 GIT binary patch delta 100 zcmV-q0Gt2Sg%;C=7O)2c2L5RvRv{3R;R7SHFau-}0t{-imK5|$lj~;%?^Z^@}%<};X zgRWqQu3!PTu3!S7L6ljQ>6p9Q>6rK-4tGd{)tS2bvA1TRK&2s;xVA) F?TjLAC)WS~ diff --git a/Sources/epoch_server/compile/epoch_bases/EPOCH_server_saveBuilding.sqf b/Sources/epoch_server/compile/epoch_bases/EPOCH_server_saveBuilding.sqf index b66f94c0..bbd191cb 100644 --- a/Sources/epoch_server/compile/epoch_bases/EPOCH_server_saveBuilding.sqf +++ b/Sources/epoch_server/compile/epoch_bases/EPOCH_server_saveBuilding.sqf @@ -55,7 +55,7 @@ if (isText _config) then { _storageObj setposATL _vehiclePos; // set reference to storage object on dummy object - _newVehicle = setVariable["EPOCH_secStorParent", _storageObj]; + _newVehicle setVariable["EPOCH_secStorParent", _storageObj]; _storageObj setVariable["EPOCH_Locked", false, true]; _storageObj setVariable["STORAGE_OWNERS", [_plyrUID]];