mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-14 04:02:37 +03:00
setdate experiment
This commit is contained in:
@@ -91,4 +91,8 @@ player addWeapon "Loot";
|
|||||||
player addWeapon "Flare";
|
player addWeapon "Flare";
|
||||||
|
|
||||||
sleep 0.1;
|
sleep 0.1;
|
||||||
|
|
||||||
|
if (!isNull _old) then {
|
||||||
|
// this should not be needed as player is deleted in player_switchModel?
|
||||||
deleteVehicle _old;
|
deleteVehicle _old;
|
||||||
|
};
|
||||||
|
|||||||
@@ -312,7 +312,7 @@ if (!isDedicated) then {
|
|||||||
};
|
};
|
||||||
|
|
||||||
if (_dikCode in actionKeys "ForceCommandingMode") then {_handled = true};
|
if (_dikCode in actionKeys "ForceCommandingMode") then {_handled = true};
|
||||||
if (_dikCode in actionKeys "PushToTalk" and (diag_tickdiag_tickTime - dayz_lastCheckBit > 10)) then {
|
if (_dikCode in actionKeys "PushToTalk" and (diag_tickTime - dayz_lastCheckBit > 10)) then {
|
||||||
dayz_lastCheckBit = diag_tickTime;
|
dayz_lastCheckBit = diag_tickTime;
|
||||||
[player,50,true,(getPosATL player)] spawn player_alertZombies;
|
[player,50,true,(getPosATL player)] spawn player_alertZombies;
|
||||||
};
|
};
|
||||||
@@ -395,6 +395,20 @@ if (!isDedicated) then {
|
|||||||
_handled
|
_handled
|
||||||
};
|
};
|
||||||
|
|
||||||
|
player_setDate = {
|
||||||
|
private ["_setdatebool","_forEachIndex","_newdate","_n"];
|
||||||
|
_setdatebool = false;
|
||||||
|
_n = _this;
|
||||||
|
{
|
||||||
|
if (_x != (_n select _forEachIndex)) exitWith {
|
||||||
|
_setdatebool = true;
|
||||||
|
};
|
||||||
|
} forEach date;
|
||||||
|
if (_setdatebool) then {
|
||||||
|
setDate _newdate;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
player_serverModelChange = {
|
player_serverModelChange = {
|
||||||
private["_object","_model"];
|
private["_object","_model"];
|
||||||
_object = _this select 0;
|
_object = _this select 0;
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ if (isServer) then {
|
|||||||
|
|
||||||
//Client only
|
//Client only
|
||||||
if (!isDedicated) then {
|
if (!isDedicated) then {
|
||||||
"PVDZE_plr_SetDate" addPublicVariableEventHandler {setDate (_this select 1)};
|
"PVDZE_plr_SetDate" addPublicVariableEventHandler {(_this select 1) call player_setDate};
|
||||||
"PVDZE_obj_RoadFlare" addPublicVariableEventHandler {(_this select 1) spawn object_roadFlare};
|
"PVDZE_obj_RoadFlare" addPublicVariableEventHandler {(_this select 1) spawn object_roadFlare};
|
||||||
"PVDZE_plr_Morph2" addPublicVariableEventHandler {(_this select 1) call player_serverModelChange};
|
"PVDZE_plr_Morph2" addPublicVariableEventHandler {(_this select 1) call player_serverModelChange};
|
||||||
"PVDZE_plr_Morph" addPublicVariableEventHandler {(_this select 1) call server_switchPlayer};
|
"PVDZE_plr_Morph" addPublicVariableEventHandler {(_this select 1) call server_switchPlayer};
|
||||||
|
|||||||
Reference in New Issue
Block a user