Compare commits
2 Commits
faf84a0bf2
...
7c6130891a
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7c6130891a | ||
|
|
eee4ac1b83 |
@@ -27,17 +27,31 @@ addMissionEventHandler ["EntityKilled", {
|
|||||||
|
|
||||||
if not (_unit isKindOf "CAManBase") exitWith {};
|
if not (_unit isKindOf "CAManBase") exitWith {};
|
||||||
|
|
||||||
if not (isInRemainsCollector _unit) exitWith {};
|
|
||||||
|
|
||||||
// format["%1 from group %2 died at %3", _unit, group _unit, [datetime] call BIS_fnc_timeToString] remoteExec ["systemChat"];
|
|
||||||
_unit setVariable["milsim_death_time", time];
|
_unit setVariable["milsim_death_time", time];
|
||||||
// _unit addEventHandler ["Deleted", {
|
|
||||||
// params ["_entity"];
|
_unit addEventHandler ["Deleted", {
|
||||||
// isGC = _entity getVariable["milsim_garbage_collected", false];
|
params ["_entity"];
|
||||||
// format["%1 from was deleted by custom gc: %2", _entity, str isGC ] remoteExec ["systemChat"];
|
_remainsCollector = _entity getVariable["milsim_garbage_collected", false];
|
||||||
// }];
|
_decayTime = time - (_entity getVariable ["milsim_death_time", time]);
|
||||||
|
|
||||||
|
_i = allUsers select { (getUserInfo _x)#1 isEqualTo _ownerId;};
|
||||||
|
_owner = if ( _i isEqualTo []) then [ { "server" }, { (getUserInfo (_i#0))#3 }];
|
||||||
|
|
||||||
|
diag_log format["isServer: %5, deleted object owned by: %1 via remainsCollector: %2 after %3 seconds of type: %4", _owner, str (not _remainsCollector), _decayTime, _entity, isServer];
|
||||||
|
}];
|
||||||
}];
|
}];
|
||||||
|
|
||||||
|
|
||||||
|
// add zeus deletion logging to curator objects
|
||||||
|
{
|
||||||
|
_x addEventHandler ["CuratorObjectDeleted", {
|
||||||
|
params ["_curator", "_entity"];
|
||||||
|
|
||||||
|
_decayTime = time - (_entity getVariable ["milsim_death_time", time]);
|
||||||
|
diag_log format["deleted object: %1 via curator: %2 after %3 seconds", _entity, name _curator, _decayTime];
|
||||||
|
}];
|
||||||
|
} foreach _curators;
|
||||||
|
|
||||||
// declare init complete to other modules
|
// declare init complete to other modules
|
||||||
missionNamespace setVariable [QGVARMAIN(complete), true, true];
|
missionNamespace setVariable [QGVARMAIN(complete), true, true];
|
||||||
|
|
||||||
|
|||||||
@@ -27,11 +27,11 @@ GVAR(deadUnitCleanupPFH) = [
|
|||||||
_dead = _dead select [0, _toDelete];
|
_dead = _dead select [0, _toDelete];
|
||||||
{
|
{
|
||||||
_unit = _x#1;
|
_unit = _x#1;
|
||||||
// _unit setVariable ["milsim_garbage_collected", true];
|
_unit setVariable ["milsim_garbage_collected", true];
|
||||||
deleteVehicle (_unit);
|
deleteVehicle (_unit);
|
||||||
} foreach _dead;
|
} foreach _dead;
|
||||||
},
|
},
|
||||||
180,
|
450,
|
||||||
[],
|
[],
|
||||||
{ // on creation
|
{ // on creation
|
||||||
[
|
[
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ localNamespace setVariable [QGVAR(checkReinsertQueueClassesAdded), []];
|
|||||||
localNamespace setVariable [QGVAR(lastReinsertQueueCheck), diag_tickTime];
|
localNamespace setVariable [QGVAR(lastReinsertQueueCheck), diag_tickTime];
|
||||||
|
|
||||||
// add actions to pilot classes, and don't apply to child classes
|
// add actions to pilot classes, and don't apply to child classes
|
||||||
[["B_Helipilot_F", "B_helicrew_F"], false] call FUNC(addCheckQueueSelfAction);
|
// [["B_Helipilot_F", "B_helicrew_F"], false] call FUNC(addCheckQueueSelfAction);
|
||||||
/////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user