mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2026-02-08 17:22:54 +03:00
1.7.5.D1202
This commit is contained in:
@@ -48,7 +48,6 @@ if (!isDedicated) then {
|
||||
player_throwObject = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\player_throwObject.sqf";
|
||||
player_alertZombies = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\player_alertZombies.sqf";
|
||||
player_fireMonitor = compile preprocessFileLineNumbers "\z\addons\dayz_code\system\fire_monitor.sqf";
|
||||
//player_combatLogged = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\player_combatLogged.sqf";
|
||||
player_tameDog = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\player_tameDog.sqf";
|
||||
|
||||
//Objects
|
||||
@@ -98,18 +97,39 @@ if (!isDedicated) then {
|
||||
// TODO: need move it in player_monitor.fsm
|
||||
// allow player disconnect from server, if loading hang, kicked by BE etc.
|
||||
[] spawn {
|
||||
private["_timeOut"];
|
||||
private["_timeOut","_display","_control1","_control2"];
|
||||
disableSerialization;
|
||||
_timeOut = 0;
|
||||
while { _timeOut < 60 } do {
|
||||
dayz_loadScreenMsg = "";
|
||||
diag_log "DEBUG: loadscreen guard started.";
|
||||
_display = uiNameSpace getVariable "BIS_loadingScreen";
|
||||
_control1 = _display displayctrl 8400;
|
||||
_control2 = _display displayctrl 102;
|
||||
// 40 sec timeout
|
||||
while { _timeOut < 400 && !dayz_clientPreload } do {
|
||||
if ( isNull _display ) then {
|
||||
waitUntil { !dialog; };
|
||||
startLoadingScreen ["","RscDisplayLoadCustom"];
|
||||
_display = uiNameSpace getVariable "BIS_loadingScreen";
|
||||
_control1 = _display displayctrl 8400;
|
||||
_control2 = _display displayctrl 102;
|
||||
};
|
||||
if ( dayz_loadScreenMsg != "" ) then {
|
||||
_control1 ctrlSetText dayz_loadScreenMsg;
|
||||
dayz_loadScreenMsg = "";
|
||||
};
|
||||
_control2 ctrlSetText format["%1",round(_timeOut*0.1)];
|
||||
_timeOut = _timeOut + 1;
|
||||
sleep 1;
|
||||
sleep 0.1;
|
||||
};
|
||||
if ( !dayz_preloadFinished ) then {
|
||||
endLoadingScreen;
|
||||
if ( !dayz_clientPreload ) then {
|
||||
|
||||
diag_log "DEBUG: loadscreen guard ended with timeout.";
|
||||
disableUserInput false;
|
||||
cutText ["Something went wrong! disconnect and try again!", "BLACK OUT",1];
|
||||
1 cutText ["Something went wrong! disconnect and try again!", "PLAIN"];
|
||||
player enableSimulation false;
|
||||
};
|
||||
} else { diag_log "DEBUG: loadscreen guard ended."; };
|
||||
};
|
||||
dayz_losChance = {
|
||||
private["_agent","_maxDis","_dis","_val","_maxExp","_myExp"];
|
||||
@@ -203,6 +223,7 @@ if (!isDedicated) then {
|
||||
_btnRespawn ctrlEnable false;
|
||||
};
|
||||
|
||||
/*
|
||||
dayz_disableAbort = {
|
||||
private["_display","_btnAbort","_combattimeout"];
|
||||
_combattimeout = player getVariable["combattimeout",0];
|
||||
@@ -215,6 +236,7 @@ if (!isDedicated) then {
|
||||
_btnAbort = _display displayCtrl 104;
|
||||
_btnAbort ctrlEnable false;
|
||||
};
|
||||
*/
|
||||
|
||||
dayz_spaceInterrupt = {
|
||||
private ["_dikCode", "_handled"];
|
||||
|
||||
@@ -22,22 +22,21 @@
|
||||
|
||||
//Server only
|
||||
if (isServer) then {
|
||||
"dayzDeath" addPublicVariableEventHandler {_id = (_this select 1) spawn server_playerDied};
|
||||
"dayzDeath" addPublicVariableEventHandler {(_this select 1) call server_playerDied};
|
||||
"dayzDiscoAdd" addPublicVariableEventHandler {dayz_disco set [count dayz_disco,(_this select 1)];};
|
||||
"dayzDiscoRem" addPublicVariableEventHandler {dayz_disco = dayz_disco - [(_this select 1)];};
|
||||
"dayzPlayerSave" addPublicVariableEventHandler {(_this select 1) call server_playerSync;};
|
||||
"dayzPublishObj" addPublicVariableEventHandler {(_this select 1) call server_publishObj};
|
||||
"dayzUpdateVehicle" addPublicVariableEventHandler {(_this select 1) call server_updateObject};
|
||||
"dayzDeleteObj" addPublicVariableEventHandler {(_this select 1) call local_deleteObj};
|
||||
"dayzPublishVeh" addPublicVariableEventHandler {(_this select 1) call server_publishVeh}; // for vehicle traders
|
||||
// "dayzPublishBank" addPublicVariableEventHandler {(_this select 1) call server_publishBank};
|
||||
"dayzTraderMenu" addPublicVariableEventHandler {(_this select 1) call server_traders}; // for all traders
|
||||
"dayzUpdateVehicle" addPublicVariableEventHandler {_id = (_this select 1) spawn server_updateObject};
|
||||
"dayzDeleteObj" addPublicVariableEventHandler {_id = (_this select 1) spawn local_deleteObj};
|
||||
"dayzLogin" addPublicVariableEventHandler {(_this select 1) call server_playerLogin};
|
||||
"dayzLogin2" addPublicVariableEventHandler {(_this select 1) call server_playerSetup};
|
||||
"dayzPlayerMorph" addPublicVariableEventHandler {(_this select 1) call server_playerMorph};
|
||||
"dayzUpdate" addPublicVariableEventHandler {_id = (_this select 1) spawn dayz_processUpdate};
|
||||
"dayzLoginRecord" addPublicVariableEventHandler {_id = (_this select 1) spawn dayz_recordLogin};
|
||||
"dayzCharSave" addPublicVariableEventHandler {(_this select 1) call server_playerSync};
|
||||
// "dayzPlayerMorph" addPublicVariableEventHandler {(_this select 1) call server_playerMorph};
|
||||
// "dayzUpdate" addPublicVariableEventHandler {_id = (_this select 1) spawn dayz_processUpdate};
|
||||
"dayzLoginRecord" addPublicVariableEventHandler {(_this select 1) call dayz_recordLogin};
|
||||
// "dayzCharSave" addPublicVariableEventHandler {(_this select 1) call server_playerSync};
|
||||
"dayzCharDisco" addPublicVariableEventHandler {(_this select 1) call server_characterSync};
|
||||
};
|
||||
|
||||
@@ -48,8 +47,7 @@ if (!isDedicated) then {
|
||||
"dayzRoadFlare" addPublicVariableEventHandler {(_this select 1) spawn object_roadFlare};
|
||||
"norrnRaDrag" addPublicVariableEventHandler {[_this select 1] execVM "\z\addons\dayz_code\medical\publicEH\animDrag.sqf"};
|
||||
"norrnRnoAnim" addPublicVariableEventHandler {[_this select 1] execVM "\z\addons\dayz_code\medical\publicEH\noAnim.sqf"};
|
||||
"changeCharacter" addPublicVariableEventHandler {(_this select 1) call player_serverModelChange};
|
||||
"dayzSwitch" addPublicVariableEventHandler {(_this select 1) call server_switchPlayer};
|
||||
// "changeCharacter" addPublicVariableEventHandler {(_this select 1) call player_serverModelChange};
|
||||
// "dayzSwitch" addPublicVariableEventHandler {(_this select 1) call server_switchPlayer};
|
||||
"dayzFire" addPublicVariableEventHandler {nul=(_this select 1) spawn BIS_Effects_Burn};
|
||||
//"dayz_combatLog" addPublicVariableEventHandler {nul=(_this select 1) spawn player_combatLogged};
|
||||
};
|
||||
@@ -71,6 +71,7 @@ dayz_resetSelfActions = {
|
||||
s_build_Wire_cat1 = -1;
|
||||
s_player_deleteBuild = -1;
|
||||
s_player_forceSave = -1;
|
||||
s_player_flipveh = -1;
|
||||
};
|
||||
call dayz_resetSelfActions;
|
||||
|
||||
@@ -191,14 +192,13 @@ if(isnil "dayz_maxLocalZombies") then {
|
||||
|
||||
dayz_spawnPos = getPosATL player;
|
||||
|
||||
if(isDedicated) then {
|
||||
dayz_disco = [];
|
||||
};
|
||||
|
||||
if(isServer) then {
|
||||
dayz_disco = [];
|
||||
dayz_players = [];
|
||||
dead_bodyCleanup = [];
|
||||
needUpdate_objects = [];
|
||||
botPlayers = [];
|
||||
};
|
||||
|
||||
if(!isDedicated) then {
|
||||
|
||||
Reference in New Issue
Block a user