mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-20 10:26:28 +03:00
1.7.5.D1202
This commit is contained in:
@@ -4,30 +4,29 @@
|
||||
item0[] = {"init",0,250,-75.000000,-400.000000,25.000000,-350.000000,0.000000,"init"};
|
||||
item1[] = {"true",8,218,-75.000000,-175.000000,25.000000,-125.000000,0.000000,"true"};
|
||||
item2[] = {"waiting",2,250,-75.000000,-100.000000,25.000000,-50.000000,0.000000,"waiting"};
|
||||
item3[] = {"too_many_dead",4,218,-150.000000,-25.000000,-50.000000,25.000000,2.000000,"too many" \n "dead"};
|
||||
item4[] = {"cleanup_dead",2,250,-150.000000,50.000000,-50.000000,100.000000,0.000000,"cleanup" \n "dead"};
|
||||
item5[] = {"too_many_objects",4,218,-25.000000,-25.000000,75.000000,25.000000,0.000000,"too many" \n "objects"};
|
||||
item6[] = {"cleanup_objects",2,250,-25.000000,50.000000,75.000000,100.000000,0.000000,"cleanup" \n "objects"};
|
||||
item7[] = {"time_sync",4,218,-275.000000,-25.000000,-175.000000,25.000000,1.000000,"time" \n "sync"};
|
||||
item8[] = {"sync_the_time",2,250,-275.000000,50.000000,-175.000000,100.000000,0.000000,"sync" \n "the time"};
|
||||
item3[] = {"time_dead",4,218,-300.000000,-25.000000,-200.000000,25.000000,4.000000,"time" \n "dead"};
|
||||
item4[] = {"cleanup_dead",2,250,-300.000000,50.000000,-200.000000,100.000000,0.000000,"cleanup" \n "dead"};
|
||||
item5[] = {"time_items",4,218,0.000000,-25.000000,100.000000,25.000000,2.000000,"time" \n "items"};
|
||||
item6[] = {"cleanup_items",2,250,0.000000,50.000000,100.000000,100.000000,0.000000,"cleanup" \n "items"};
|
||||
item7[] = {"time_sync",4,218,-150.000000,-25.000000,-50.000000,25.000000,3.000000,"time" \n "sync"};
|
||||
item8[] = {"sync_the_time",2,250,-150.000000,50.000000,-50.000000,100.000000,0.000000,"sync" \n "the time"};
|
||||
item9[] = {"true",8,218,-75.000000,125.000000,25.000000,175.000000,0.000000,"true"};
|
||||
item10[] = {"general_cleanup",2,250,-75.000000,200.000000,25.000000,250.000000,0.000000,"general" \n "cleanup"};
|
||||
item11[] = {"",7,210,-304.000000,220.999985,-296.000000,229.000015,0.000000,""};
|
||||
item12[] = {"",7,210,-304.000000,-154.000000,-296.000000,-146.000000,0.000000,""};
|
||||
item13[] = {"",7,210,221.000000,-79.000000,229.000000,-71.000000,0.000000,""};
|
||||
item14[] = {"",7,210,221.000000,146.000000,229.000000,154.000000,0.000000,""};
|
||||
item15[] = {"initialized",4,218,-75.000000,-325.000000,25.000000,-275.000000,0.000000,"initialized"};
|
||||
item16[] = {"prepare",2,250,-75.000000,-250.000000,25.000000,-200.000000,0.000000,"prepare"};
|
||||
item17[] = {"update_objects",2,4346,100.000000,50.000000,200.000000,100.000000,0.000000,"update objects"};
|
||||
item18[] = {"need_update",4,218,100.000000,-25.000000,200.000000,25.000000,1.000000,"need update"};
|
||||
item19[] = {"",7,210,221.000000,-79.000000,229.000000,-71.000000,0.000000,""};
|
||||
link0[] = {0,15};
|
||||
item11[] = {"",7,210,-341.500000,220.999985,-333.500000,229.000015,0.000000,""};
|
||||
item12[] = {"",7,210,-341.500000,-154.000000,-333.500000,-146.000000,0.000000,""};
|
||||
item13[] = {"initialized",4,218,-75.000000,-325.000000,25.000000,-275.000000,0.000000,"initialized"};
|
||||
item14[] = {"prepare",2,250,-75.000000,-250.000000,25.000000,-200.000000,0.000000,"prepare"};
|
||||
item15[] = {"update_objects",2,250,150.000000,50.000000,250.000000,100.000000,0.000000,"update objects"};
|
||||
item16[] = {"time_obj_update",4,218,150.000000,-25.000000,250.000000,25.000000,1.000000,"time" \n "obj update"};
|
||||
item17[] = {"anti_hack",4,218,150.000000,-100.000000,250.000000,-50.000000,0.000000,"anti hack"};
|
||||
item18[] = {"check_for_hacker",2,4346,150.000000,-175.000000,250.000000,-125.000000,0.000000,"check for" \n "hackers"};
|
||||
link0[] = {0,13};
|
||||
link1[] = {1,2};
|
||||
link2[] = {2,3};
|
||||
link3[] = {2,5};
|
||||
link4[] = {2,7};
|
||||
link5[] = {2,13};
|
||||
link6[] = {2,18};
|
||||
link5[] = {2,16};
|
||||
link6[] = {2,17};
|
||||
link7[] = {3,4};
|
||||
link8[] = {4,9};
|
||||
link9[] = {5,6};
|
||||
@@ -39,14 +38,13 @@ link14[] = {10,11};
|
||||
link15[] = {11,12};
|
||||
link16[] = {12,1};
|
||||
link17[] = {13,14};
|
||||
link18[] = {13,19};
|
||||
link19[] = {14,9};
|
||||
link20[] = {15,16};
|
||||
link21[] = {16,1};
|
||||
link22[] = {17,9};
|
||||
link23[] = {18,17};
|
||||
globals[] = {25.000000,1,0,0,0,640,480,1,24,6316128,1,-396.580658,354.272186,463.204498,-386.553192,911,1031,1};
|
||||
window[] = {2,-1,-1,-1,-1,1020,322,1651,78,3,929};
|
||||
link18[] = {14,1};
|
||||
link19[] = {15,9};
|
||||
link20[] = {16,15};
|
||||
link21[] = {17,18};
|
||||
link22[] = {18,1};
|
||||
globals[] = {25.000000,1,0,0,0,640,480,1,33,6316128,1,-380.893097,315.695129,343.738464,-460.417511,803,927,1};
|
||||
window[] = {2,-1,-1,-1,-1,1039,132,1246,132,3,820};
|
||||
*//*%FSM</HEAD>*/
|
||||
class FSM
|
||||
{
|
||||
@@ -78,60 +76,58 @@ class FSM
|
||||
class waiting
|
||||
{
|
||||
name = "waiting";
|
||||
init = /*%FSM<STATEINIT""">*/"//diag_log ""CLEANUP: Waiting for next task"";" \n
|
||||
"_numDead = {local _x} count allDead;" \n
|
||||
""/*%FSM</STATEINIT""">*/;
|
||||
init = /*%FSM<STATEINIT""">*/""/*%FSM</STATEINIT""">*/;
|
||||
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||||
class Links
|
||||
{
|
||||
/*%FSM<LINK "too_many_dead">*/
|
||||
class too_many_dead
|
||||
/*%FSM<LINK "time_dead">*/
|
||||
class time_dead
|
||||
{
|
||||
priority = 2.000000;
|
||||
priority = 4.000000;
|
||||
to="cleanup_dead";
|
||||
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"(_numDead > 300)"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"(time - _lastDeadCheck) > 600"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/"_lastDeadCheck = time;"/*%FSM</ACTION""">*/;
|
||||
};
|
||||
/*%FSM</LINK>*/
|
||||
/*%FSM<LINK "time_sync">*/
|
||||
class time_sync
|
||||
{
|
||||
priority = 1.000000;
|
||||
priority = 3.000000;
|
||||
to="sync_the_time";
|
||||
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"((time - _lastUpdate) > 300)"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/"_lastUpdate = time;"/*%FSM</ACTION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"(time - _lastTimeSync) > 300"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/"_lastTimeSync = time;"/*%FSM</ACTION""">*/;
|
||||
};
|
||||
/*%FSM</LINK>*/
|
||||
/*%FSM<LINK "need_update">*/
|
||||
class need_update
|
||||
/*%FSM<LINK "time_items">*/
|
||||
class time_items
|
||||
{
|
||||
priority = 2.000000;
|
||||
to="cleanup_items";
|
||||
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"(time - _lastItemCheck) > 60"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/"_lastItemCheck = time;"/*%FSM</ACTION""">*/;
|
||||
};
|
||||
/*%FSM</LINK>*/
|
||||
/*%FSM<LINK "time_obj_update">*/
|
||||
class time_obj_update
|
||||
{
|
||||
priority = 1.000000;
|
||||
to="update_objects";
|
||||
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"( (count needUpdate_objects) > 0 && (time-_lastNeedUpdate>10) )"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/"_lastNeedUpdate = time;"/*%FSM</ACTION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"(time-_lastObjectUpdateCheck) > 10"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/"_lastObjectUpdateCheck = time;"/*%FSM</ACTION""">*/;
|
||||
};
|
||||
/*%FSM</LINK>*/
|
||||
/*%FSM<LINK "true">*/
|
||||
class true
|
||||
/*%FSM<LINK "anti_hack">*/
|
||||
class anti_hack
|
||||
{
|
||||
priority = 0.000000;
|
||||
to="general_cleanup";
|
||||
to="check_for_hacker";
|
||||
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||||
};
|
||||
/*%FSM</LINK>*/
|
||||
/*%FSM<LINK "too_many_objects">*/
|
||||
class too_many_objects
|
||||
{
|
||||
priority = 0.000000;
|
||||
to="cleanup_objects";
|
||||
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"((time - _timeNem) > 60)"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/"_timeNem = time;"/*%FSM</ACTION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"(time-_timeHackCheck) > 1"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/"_timeHackCheck = time;"/*%FSM</ACTION""">*/;
|
||||
};
|
||||
/*%FSM</LINK>*/
|
||||
};
|
||||
@@ -141,80 +137,85 @@ class FSM
|
||||
class cleanup_dead
|
||||
{
|
||||
name = "cleanup_dead";
|
||||
init = /*%FSM<STATEINIT""">*/"diag_log (""CLEANUP: TOO MANY DEAD BODIES"");" \n
|
||||
init = /*%FSM<STATEINIT""">*/"_numDead = {local _x} count allDead;" \n
|
||||
"" \n
|
||||
"diag_log (""CLEANUP: PERFORMING BODY CLEANUP ON "" + str(_numDead) + "" BODIES"");" \n
|
||||
"if (_numDead > 300) then { " \n
|
||||
"" \n
|
||||
"_delQtyZ = 0;" \n
|
||||
"_numZombie = {_x isKindOf ""zZombie_Base""} count allDead;" \n
|
||||
"{" \n
|
||||
" if (local _x) then {" \n
|
||||
" if (_x isKindOf ""zZombie_Base"") then {" \n
|
||||
" deleteVehicle _x;" \n
|
||||
" _delQtyZ = _delQtyZ + 1;" \n
|
||||
" } else {" \n
|
||||
" _exists = _x in _deadBodies;" \n
|
||||
" if(!_exists) then {" \n
|
||||
" _deadBodies set [count _deadBodies,_x];" \n
|
||||
" diag_log (""CLEANUP: TOO MANY DEAD BODIES"");" \n
|
||||
" diag_log (""CLEANUP: PERFORMING BODY CLEANUP ON "" + str(_numDead) + "" BODIES"");" \n
|
||||
"" \n
|
||||
" _delQtyZ = 0; " \n
|
||||
" _numZombie = {_x isKindOf ""zZombie_Base""} count allDead;" \n
|
||||
" {" \n
|
||||
" if (local _x) then {" \n
|
||||
" if (_x isKindOf ""zZombie_Base"") then {" \n
|
||||
" deleteVehicle _x;" \n
|
||||
" _delQtyZ = _delQtyZ + 1;" \n
|
||||
" } else {" \n
|
||||
" _exists = _x in _deadBodies;" \n
|
||||
" if(!_exists) then {" \n
|
||||
" _deadBodies set [count _deadBodies,_x];" \n
|
||||
" };" \n
|
||||
" };" \n
|
||||
" };" \n
|
||||
" };" \n
|
||||
"} forEach allDead;" \n
|
||||
" } forEach allDead;" \n
|
||||
"" \n
|
||||
"//Cleanup players" \n
|
||||
"_body = objNull;" \n
|
||||
"_delQtyP = 0;" \n
|
||||
"_delDo = _numDead - _numZombie;" \n
|
||||
"_delDo = ((_delDo min (count _deadBodies)) -1);" \n
|
||||
"if (_delDo<1) then {_delDo=1};" \n
|
||||
"for ""_i"" from 0 to _delDo do {" \n
|
||||
" _body = _deadBodies select _i;" \n
|
||||
" if(!isNil ""_body"") then {" \n
|
||||
" _pos = getPosATL _body;" \n
|
||||
" _sfx = nearestObject [_pos,""Sound_Flies""];" \n
|
||||
" if (!(isNull _sfx)) then {" \n
|
||||
" deleteVehicle _sfx;" \n
|
||||
" //Cleanup players" \n
|
||||
" _body = objNull;" \n
|
||||
" _delQtyP = 0;" \n
|
||||
" _delDo = _numDead - _numZombie;" \n
|
||||
" _delDo = ((_delDo min (count _deadBodies)) -1);" \n
|
||||
" if (_delDo<1) then {_delDo=1};" \n
|
||||
" for ""_i"" from 0 to _delDo do {" \n
|
||||
" _body = _deadBodies select _i;" \n
|
||||
" if(!isNil ""_body"") then {" \n
|
||||
" _pos = getPosATL _body;" \n
|
||||
" _sfx = nearestObject [_pos,""Sound_Flies""];" \n
|
||||
" if (!(isNull _sfx)) then {" \n
|
||||
" deleteVehicle _sfx;" \n
|
||||
" };" \n
|
||||
" deleteVehicle _body;" \n
|
||||
" _delQtyP = _delQtyP + 1;" \n
|
||||
" };" \n
|
||||
" deleteVehicle _body;" \n
|
||||
" _delQtyP = _delQtyP + 1;" \n
|
||||
" };" \n
|
||||
" _deadBodies set [_i,""DEL""];" \n
|
||||
" _deadBodies set [_i,""DEL""];" \n
|
||||
"" \n
|
||||
"//Let's move this into the body removal sequence so uncontrolled flies are removed only if corpses are cleaned" \n
|
||||
"//Check Flies" \n
|
||||
"_isOK=-1;" \n
|
||||
"_dwUSOFC=0;" \n
|
||||
"{" \n
|
||||
" //_isOk = {!alive _x} count (nearestObjects [_x, [""CAManBase""], 2]);" \n
|
||||
" _isOk = {!alive _x} count (_x nearEntities [[""CAManBase""], 2]);" \n
|
||||
" if (_isOk>-1) then {" \n
|
||||
" diag_log (""DW_DEBUG _isOK: "" + str(_isOK) );" \n
|
||||
" };" \n
|
||||
" if ((_isOk>-1) AND (_isOK<1)) then {" \n
|
||||
" //diag_log (""CLEANUP: DELETING A SOUND OF FLIES"");" \n
|
||||
"_dwUSOFC=_dwUSOFC+1;" \n
|
||||
" deleteVehicle _x;" \n
|
||||
" diag_log (""CLEANUP: DELETED AN UNCONTROLLED SOUND OF FLIES:"" + str(_dwUSOFC) );" \n
|
||||
" };" \n
|
||||
"} forEach allMissionObjects ""Sound_Flies"";" \n
|
||||
" //Let's move this into the body removal sequence so uncontrolled flies are removed only if corpses are cleaned" \n
|
||||
" //Check Flies" \n
|
||||
" _isOK=-1;" \n
|
||||
" _dwUSOFC=0;" \n
|
||||
" {" \n
|
||||
" //_isOk = {!alive _x} count (nearestObjects [_x, [""CAManBase""], 2]);" \n
|
||||
" _isOk = {!alive _x} count (_x nearEntities [[""CAManBase""], 2]);" \n
|
||||
" if (_isOk>-1) then {" \n
|
||||
" diag_log (""DW_DEBUG _isOK: "" + str(_isOK) );" \n
|
||||
" };" \n
|
||||
" if ((_isOk>-1) AND (_isOK<1)) then {" \n
|
||||
" //diag_log (""CLEANUP: DELETING A SOUND OF FLIES"");" \n
|
||||
" _dwUSOFC=_dwUSOFC+1;" \n
|
||||
" deleteVehicle _x;" \n
|
||||
" diag_log (""CLEANUP: DELETED AN UNCONTROLLED SOUND OF FLIES:"" + str(_dwUSOFC) );" \n
|
||||
" };" \n
|
||||
" } forEach allMissionObjects ""Sound_Flies"";" \n
|
||||
"" \n
|
||||
"" \n
|
||||
"//Let's move this into the body removal sequence so uncontrolled fireplaces are removed only if corpses are cleaned" \n
|
||||
"//clean fireplaces" \n
|
||||
"_dwUFPC=0;" \n
|
||||
"{" \n
|
||||
" if (local _x) then {" \n
|
||||
" //diag_log (""CLEANUP: DELETING A UNCONTROLLED FIREPLACE"");" \n
|
||||
" deleteVehicle _x;" \n
|
||||
"_dwUFPC=_dwUFPC+1;" \n
|
||||
" diag_log (""CLEANUP: DELETED AN UNCONTROLLED FIREPLACE:"" + str(_dwUFPC) );" \n
|
||||
" //Let's move this into the body removal sequence so uncontrolled fireplaces are removed only if corpses are cleaned" \n
|
||||
" //clean fireplaces" \n
|
||||
" _dwUFPC=0;" \n
|
||||
" {" \n
|
||||
" if (local _x) then {" \n
|
||||
" //diag_log (""CLEANUP: DELETING A UNCONTROLLED FIREPLACE"");" \n
|
||||
" deleteVehicle _x;" \n
|
||||
" _dwUFPC=_dwUFPC+1;" \n
|
||||
" diag_log (""CLEANUP: DELETED AN UNCONTROLLED FIREPLACE:"" + str(_dwUFPC) );" \n
|
||||
" };" \n
|
||||
" } forEach allMissionObjects ""Land_Fire_DZ"";" \n
|
||||
"" \n
|
||||
" };" \n
|
||||
"} forEach allMissionObjects ""Land_Fire_DZ"";" \n
|
||||
" _deadBodies = _deadBodies - [""DEL""];" \n
|
||||
"" \n
|
||||
" diag_log (""CLEANUP: DELETED "" + str(_delQtyP) + "" PLAYER BODIES AND "" + str(_delQtyZ) + "" BODIES"");" \n
|
||||
"" \n
|
||||
"};" \n
|
||||
"_deadBodies = _deadBodies - [""DEL""];" \n
|
||||
"" \n
|
||||
"diag_log (""CLEANUP: DELETED "" + str(_delQtyP) + "" PLAYER BODIES AND "" + str(_delQtyZ) + "" BODIES"");" \n
|
||||
""/*%FSM</STATEINIT""">*/;
|
||||
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||||
class Links
|
||||
@@ -232,25 +233,27 @@ class FSM
|
||||
};
|
||||
};
|
||||
/*%FSM</STATE>*/
|
||||
/*%FSM<STATE "cleanup_objects">*/
|
||||
class cleanup_objects
|
||||
/*%FSM<STATE "cleanup_items">*/
|
||||
class cleanup_items
|
||||
{
|
||||
name = "cleanup_objects";
|
||||
name = "cleanup_items";
|
||||
init = /*%FSM<STATEINIT""">*/"_missionObjs = allMissionObjects ""WeaponHolder"";" \n
|
||||
"_qty = count _missionObjs;" \n
|
||||
"" \n
|
||||
"//diag_log (""CLEANUP: PERFORMING ITEM CLEANUP: TOTAL "" + str(_qty) + "" LOOT BAGS"");" \n
|
||||
"_delQty = 0;" \n
|
||||
"_qtyLoc = 0;" \n
|
||||
"{" \n
|
||||
" if (local _x) then {" \n
|
||||
" _qtyLoc = _qtyLoc + 1; // debugging" \n
|
||||
" _keep = _x getVariable [""permaLoot"",false];" \n
|
||||
" _nearby = {isPlayer _x} count (_x nearEntities [[""CAManBase""], 100]);" \n
|
||||
" _nearby = {isPlayer _x} count (_x nearEntities [[""CAManBase""], 100]);" \n
|
||||
" if ( (!_keep) && (_nearby==0) ) then {" \n
|
||||
" deleteVehicle _x;" \n
|
||||
" _delQty = _delQty + 1;" \n
|
||||
" };" \n
|
||||
" };" \n
|
||||
"} forEach _missionObjs;" \n
|
||||
"" \n
|
||||
"if (_delQty > 0) then {" \n
|
||||
" diag_log (""CLEANUP: DELETED "" + str(_delQty) + "" LOOT BAGS"");" \n
|
||||
"};" \n
|
||||
@@ -287,8 +290,8 @@ class FSM
|
||||
" setDate _date;" \n
|
||||
" dayzSetDate = _date;" \n
|
||||
" publicVariable ""dayzSetDate"";" \n
|
||||
" diag_log (""TIME SYNC: Local Time set to "" + str(_date));" \n
|
||||
"};" \n
|
||||
" diag_log (""TIME SYNC: Local Time set to "" + str(_date));" \n
|
||||
" };" \n
|
||||
"};" \n
|
||||
""/*%FSM</STATEINIT""">*/;
|
||||
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||||
@@ -330,36 +333,8 @@ class FSM
|
||||
" } forEach allMissionObjects ""ReammoBox"";" \n
|
||||
"*/" \n
|
||||
"" \n
|
||||
"//Check for hackers" \n
|
||||
" {" \n
|
||||
" if(vehicle _x != _x && !(vehicle _x in _safety) && (typeOf vehicle _x) != ""ParachuteWest"") then {" \n
|
||||
" diag_log (""CLEANUP: KILLING A HACKER "" + (name _x) + "" "" + str(_x) + "" IN "" + (typeOf vehicle _x));" \n
|
||||
" (vehicle _x) setDamage 1;" \n
|
||||
" _x setDamage 1;" \n
|
||||
" };" \n
|
||||
" } forEach allUnits;" \n
|
||||
"" \n
|
||||
"/*" \n
|
||||
"//Let's move this into the body removal sequence so uncontrolled flies are removed only if corpses are cleaned" \n
|
||||
"//Check Flies" \n
|
||||
"_isOK=-1;" \n
|
||||
"_dwUSOFC=0;" \n
|
||||
"{" \n
|
||||
" //_isOk = {!alive _x} count (nearestObjects [_x, [""CAManBase""], 2]);" \n
|
||||
" _isOk = {!alive _x} count (_x nearEntities [[""CAManBase""], 2]);" \n
|
||||
" if (_isOk>-1) then {" \n
|
||||
" diag_log (""DW_DEBUG _isOK: "" + str(_isOK) );" \n
|
||||
" };" \n
|
||||
" if ((_isOk>-1) AND (isOK<1)) then {" \n
|
||||
" //diag_log (""CLEANUP: DELETING A SOUND OF FLIES"");" \n
|
||||
"_dwUSOFC=_dwUSOFC+1;" \n
|
||||
" deleteVehicle _x;" \n
|
||||
" diag_log (""CLEANUP: DELETED AN UNCONTROLLED SOUND OF FLIES:"" + str(_dwUSOFC) );" \n
|
||||
" };" \n
|
||||
"} forEach allMissionObjects ""Sound_Flies"";" \n
|
||||
"*/" \n
|
||||
"" \n
|
||||
"dayz_serverObjectMonitor = _safety;"/*%FSM</STATEINIT""">*/;
|
||||
"dayz_serverObjectMonitor = _safety;" \n
|
||||
""/*%FSM</STATEINIT""">*/;
|
||||
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||||
class Links
|
||||
{
|
||||
@@ -384,10 +359,12 @@ class FSM
|
||||
"" \n
|
||||
"_safety = dayz_serverObjectMonitor;" \n
|
||||
"" \n
|
||||
"_lastUpdate = time;" \n
|
||||
"_timeNem = time;" \n
|
||||
"_lastTimeSync = time;" \n
|
||||
"_lastDeadCheck = time;" \n
|
||||
"_lastItemCheck = time;" \n
|
||||
"_lastObjectUpdateCheck = time;" \n
|
||||
"_timeHackCheck = time;" \n
|
||||
"_deadBodies = [];" \n
|
||||
"_lastNeedUpdate = time;" \n
|
||||
"_maxBodies = 15;" \n
|
||||
""/*%FSM</STATEINIT""">*/;
|
||||
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||||
@@ -410,13 +387,16 @@ class FSM
|
||||
class update_objects
|
||||
{
|
||||
name = "update_objects";
|
||||
init = /*%FSM<STATEINIT""">*/"diag_log format[""DEBUG: needUpdate_objects=%1"",needUpdate_objects];" \n
|
||||
"{" \n
|
||||
"// _x setVariable [""needUpdate"",false,true];" \n
|
||||
" needUpdate_objects = needUpdate_objects - [_x];" \n
|
||||
" [_x,""all""] spawn server_updateObject;" \n
|
||||
init = /*%FSM<STATEINIT""">*/"if ((count needUpdate_objects) > 0) then {" \n
|
||||
"" \n
|
||||
"} forEach needUpdate_objects;" \n
|
||||
" diag_log format[""DEBUG: needUpdate_objects=%1"",needUpdate_objects];" \n
|
||||
"" \n
|
||||
" {" \n
|
||||
" //_x setVariable [""needUpdate"",false,true];" \n
|
||||
" needUpdate_objects = needUpdate_objects - [_x];" \n
|
||||
" [_x,""all""] call server_updateObject; //should be call!!!" \n
|
||||
" } forEach needUpdate_objects;" \n
|
||||
"};" \n
|
||||
""/*%FSM</STATEINIT""">*/;
|
||||
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||||
class Links
|
||||
@@ -434,6 +414,37 @@ class FSM
|
||||
};
|
||||
};
|
||||
/*%FSM</STATE>*/
|
||||
/*%FSM<STATE "check_for_hacker">*/
|
||||
class check_for_hacker
|
||||
{
|
||||
name = "check_for_hacker";
|
||||
init = /*%FSM<STATEINIT""">*/"//Check for hackers" \n
|
||||
" {" \n
|
||||
" if(vehicle _x != _x) then {" \n
|
||||
" if (!(vehicle _x in _safety) && ((typeOf vehicle _x) != ""ParachuteWest"")) then {" \n
|
||||
" diag_log (""CLEANUP: KILLING A HACKER "" + (name _x) + "" "" + str(_x) + "" IN "" + (typeOf vehicle _x));" \n
|
||||
" (vehicle _x) setDamage 1;" \n
|
||||
" _x setDamage 1;" \n
|
||||
" };" \n
|
||||
" };" \n
|
||||
" } forEach allUnits;" \n
|
||||
""/*%FSM</STATEINIT""">*/;
|
||||
precondition = /*%FSM<STATEPRECONDITION""">*/""/*%FSM</STATEPRECONDITION""">*/;
|
||||
class Links
|
||||
{
|
||||
/*%FSM<LINK "true">*/
|
||||
class true
|
||||
{
|
||||
priority = 0.000000;
|
||||
to="waiting";
|
||||
precondition = /*%FSM<CONDPRECONDITION""">*/""/*%FSM</CONDPRECONDITION""">*/;
|
||||
condition=/*%FSM<CONDITION""">*/"true"/*%FSM</CONDITION""">*/;
|
||||
action=/*%FSM<ACTION""">*/""/*%FSM</ACTION""">*/;
|
||||
};
|
||||
/*%FSM</LINK>*/
|
||||
};
|
||||
};
|
||||
/*%FSM</STATE>*/
|
||||
};
|
||||
initState="init";
|
||||
finalStates[] =
|
||||
|
||||
@@ -144,7 +144,6 @@ diag_log "HIVE: Starting";
|
||||
_countr = _countr + 1;
|
||||
} forEach _objWpnTypes;
|
||||
};
|
||||
};
|
||||
|
||||
if (_object isKindOf "AllVehicles") then {
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user