Removed workaround for PlayerDisconnected

Tested and working again.
Should be better then searching (foreach allunits)
This commit is contained in:
He-Man 2016-12-12 19:36:00 +01:00 committed by GitHub
parent 31371482c8
commit 6cb5de71b5

View File

@ -80,17 +80,7 @@ addMissionEventHandler ["PlayerConnected", {
['Connected', [_uid, _name]] call EPOCH_fnc_server_hiveLog;
}];
onPlayerDisconnected {
params ["_id", "_uid", "_name"];
_unit = objNull;
{
if ((_x getVariable["PUID", "0"]) == _uid) exitWith {
_unit = _x;
};
} forEach allUnits;
[_unit,_id,_uid,_name] call EPOCH_server_onPlayerDisconnect
};
// addMissionEventHandler ["HandleDisconnect", {_this call EPOCH_server_onPlayerDisconnect}];
addMissionEventHandler ["HandleDisconnect", {_this call EPOCH_server_onPlayerDisconnect}];
diag_log "Epoch: Setup Side Settings";
//set side status