mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2026-02-25 17:31:36 +03:00
1.0.1.94 DEV BUILD
This commit is contained in:
@@ -2,7 +2,7 @@ private ["_object","_myGroup","_id","_playerID","_playerName","_characterID","_p
|
||||
_playerID = _this select 0;
|
||||
_playerName = _this select 1;
|
||||
_object = call compile format["player%1",_playerID];
|
||||
_characterID = _object getVariable ["characterID","0"];
|
||||
_characterID = _object getVariable ["CharacterID","0"];
|
||||
_timeout = _object getVariable["combattimeout",0];
|
||||
|
||||
_playerIDtoarray = [];
|
||||
|
||||
@@ -248,7 +248,7 @@ if (_randomSpot) then {
|
||||
dayz_players set [count dayz_players,_playerObj];
|
||||
|
||||
//record player pos locally for server checking
|
||||
_playerObj setVariable["characterID",_characterID,true];
|
||||
_playerObj setVariable["CharacterID",_characterID,true];
|
||||
_playerObj setVariable["humanity",_humanity,true];
|
||||
_playerObj setVariable["humanity_CHK",_humanity];
|
||||
//_playerObj setVariable["worldspace",_worldspace,true];
|
||||
|
||||
@@ -6,7 +6,7 @@ _magazines = _this select 1;
|
||||
_forceGear = _this select 3;
|
||||
_force = true;
|
||||
|
||||
_characterID = _character getVariable ["characterID","0"];
|
||||
_characterID = _character getVariable ["CharacterID","0"];
|
||||
_charPos = getPosATL _character;
|
||||
_isInVehicle = vehicle _character != _character;
|
||||
_timeSince = 0;
|
||||
@@ -185,7 +185,7 @@ if (_characterID != "0") then {
|
||||
|
||||
// If player is in a vehicle, keep its position updated
|
||||
if (vehicle _character != _character) then {
|
||||
// [vehicle _character, "position"] call server_updateObject;
|
||||
//[vehicle _character, "position"] call server_updateObject;
|
||||
if (!(vehicle _character in needUpdate_objects)) then {
|
||||
//diag_log format["DEBUG: Added to NeedUpdate=%1",_object];
|
||||
needUpdate_objects set [count needUpdate_objects, vehicle _character];
|
||||
|
||||
@@ -20,7 +20,7 @@ _key call server_hiveWrite;
|
||||
|
||||
_object setVariable ["lastUpdate",time];
|
||||
_object setVariable ["ObjectUID", _uid,true];
|
||||
// _object setVariable ["characterID",_charID,true];
|
||||
// _object setVariable ["CharacterID",_charID,true];
|
||||
|
||||
_object addMPEventHandler ["MPKilled",{_this call object_handleServerKilled;}];
|
||||
// Test disabling simulation server side on buildables only.
|
||||
|
||||
@@ -131,8 +131,13 @@ if (isServer and isNil "sm_done") then {
|
||||
_object setVariable ["lastUpdate",time];
|
||||
_object setVariable ["ObjectID", _idKey, true];
|
||||
|
||||
_lockable = 0;
|
||||
if(isNumber (configFile >> "CfgVehicles" >> _type >> "lockable")) then {
|
||||
_lockable = getNumber(configFile >> "CfgVehicles" >> _type >> "lockable");
|
||||
};
|
||||
|
||||
// fix for leading zero issues on safe codes after restart
|
||||
if (_type in DZE_LockedStorage) then {
|
||||
if (_lockable == 4) then {
|
||||
_codeCount = (count (toArray _ownerID));
|
||||
if(_codeCount == 3) then {
|
||||
_ownerID = format["0%1", _ownerID];
|
||||
@@ -145,6 +150,16 @@ if (isServer and isNil "sm_done") then {
|
||||
};
|
||||
};
|
||||
|
||||
if (_lockable == 3) then {
|
||||
_codeCount = (count (toArray _ownerID));
|
||||
if(_codeCount == 2) then {
|
||||
_ownerID = format["0%1", _ownerID];
|
||||
};
|
||||
if(_codeCount == 1) then {
|
||||
_ownerID = format["00%1", _ownerID];
|
||||
};
|
||||
};
|
||||
|
||||
_object setVariable ["CharacterID", _ownerID, true];
|
||||
|
||||
clearWeaponCargoGlobal _object;
|
||||
@@ -154,14 +169,14 @@ if (isServer and isNil "sm_done") then {
|
||||
_object addMPEventHandler ["MPKilled",{_this call object_handleServerKilled;}];
|
||||
// Test disabling simulation server side on buildables only.
|
||||
_object enableSimulation false;
|
||||
// used for inplace upgrades and lock/unlock of safe
|
||||
_object setVariable ["OEMPos", _pos, true];
|
||||
};
|
||||
|
||||
_object setdir _dir;
|
||||
_object setpos _pos;
|
||||
_object setDamage _damage;
|
||||
|
||||
_object setVariable ["OEMPos", _pos, true];
|
||||
|
||||
if (count _intentory > 0) then {
|
||||
if (_type in DZE_LockedStorage) then {
|
||||
// Fill variables with loot
|
||||
|
||||
Reference in New Issue
Block a user