|
|
|
|
@@ -5,8 +5,14 @@
|
|
|
|
|
[format ["(EventHandler) OnUserConnected fired: %1", _this], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
|
|
|
|
|
private _userInfo = (getUserInfo _networkId);
|
|
|
|
|
if (isNil "_userInfo") exitWith {
|
|
|
|
|
[format ["(EventHandler) OnUserConnected: No user info found for %1", _networkId], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
_userInfo params ["_playerID", "_ownerId", "_playerUID", "_profileName", "_displayName", "_steamName", "_clientState", "_isHC", "_adminState", "_networkInfo", "_unit"];
|
|
|
|
|
if (_isHC) exitWith {};
|
|
|
|
|
if (_isHC) exitWith {
|
|
|
|
|
[format ["(EventHandler) OnUserConnected: %1 is HC, skipping", _playerID], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
(AttendanceTracker getVariable ["allUsers", createHashMap]) set [_networkId, _userInfo];
|
|
|
|
|
[
|
|
|
|
|
@@ -16,7 +22,7 @@
|
|
|
|
|
_profileName,
|
|
|
|
|
_steamName,
|
|
|
|
|
nil // send rowId on d/c only
|
|
|
|
|
] call attendanceTracker_fnc_writeAttendance;
|
|
|
|
|
] call attendanceTracker_fnc_logServerEvent;
|
|
|
|
|
|
|
|
|
|
}],
|
|
|
|
|
["OnUserDisconnected", {
|
|
|
|
|
@@ -25,10 +31,14 @@
|
|
|
|
|
[format ["(EventHandler) OnUserDisconnected fired: %1", _this], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
|
|
|
|
|
private _userInfo = (AttendanceTracker getVariable ["allUsers", createHashMap]) get _networkId;
|
|
|
|
|
if (isNil "_userInfo") exitWith {};
|
|
|
|
|
if (isNil "_userInfo") exitWith {
|
|
|
|
|
[format ["(EventHandler) OnUserDisconnected: No user info found for %1", _networkId], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
_userInfo params ["_playerID", "_ownerId", "_playerUID", "_profileName", "_displayName", "_steamName", "_clientState", "_isHC", "_adminState", "_networkInfo", "_unit", "_rowId"];
|
|
|
|
|
if (_isHC) exitWith {};
|
|
|
|
|
if (_isHC) exitWith {
|
|
|
|
|
[format ["(EventHandler) OnUserDisconnected: %1 is HC, skipping", _playerID], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
[
|
|
|
|
|
"Server",
|
|
|
|
|
@@ -37,7 +47,7 @@
|
|
|
|
|
_profileName,
|
|
|
|
|
_steamName,
|
|
|
|
|
(if (!isNil "_rowId") then {_rowId} else {nil}) // send rowId on d/c only
|
|
|
|
|
] call attendanceTracker_fnc_writeAttendance;
|
|
|
|
|
] call attendanceTracker_fnc_logServerEvent;
|
|
|
|
|
}],
|
|
|
|
|
["PlayerConnected", {
|
|
|
|
|
params ["_id", "_uid", "_name", "_jip", "_owner", "_idstr"];
|
|
|
|
|
@@ -45,10 +55,14 @@
|
|
|
|
|
[format ["(EventHandler) PlayerConnected fired: %1", _this], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
|
|
|
|
|
private _userInfo = (getUserInfo _idstr);
|
|
|
|
|
if (isNil "_userInfo") exitWith {};
|
|
|
|
|
if (isNil "_userInfo") exitWith {
|
|
|
|
|
[format ["(EventHandler) PlayerConnected: No user info found for %1", _idstr], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
_userInfo params ["_playerID", "_ownerId", "_playerUID", "_profileName", "_displayName", "_steamName", "_clientState", "_isHC", "_adminState", "_networkInfo", "_unit"];
|
|
|
|
|
if (_isHC) exitWith {};
|
|
|
|
|
if (_isHC) exitWith {
|
|
|
|
|
[format ["(EventHandler) PlayerConnected: %1 is HC, skipping", _playerID], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
(AttendanceTracker getVariable ["allUsers", createHashMap]) set [_playerID, _userInfo];
|
|
|
|
|
[
|
|
|
|
|
@@ -74,7 +88,9 @@
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
_userInfo params ["_playerID", "_ownerId", "_playerUID", "_profileName", "_displayName", "_steamName", "_clientState", "_isHC", "_adminState", "_networkInfo", "_unit", "_rowId"];
|
|
|
|
|
if (_isHC) exitWith {};
|
|
|
|
|
if (_isHC) exitWith {
|
|
|
|
|
[format ["(EventHandler) HandleDisconnect: %1 is HC, skipping", _playerID], "DEBUG"] call attendanceTracker_fnc_log;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
[
|
|
|
|
|
"Mission",
|
|
|
|
|
|