mirror of
https://github.com/RaidMax/IW4M-Admin.git
synced 2025-06-10 23:31:13 -05:00
tweaked the custom callbacks and added two new fields that are logged
prevent script kill events with no valid origin or target from being triggered
This commit is contained in:
@ -176,6 +176,12 @@ namespace StatsPlugin.Helpers
|
||||
{
|
||||
await AddStandardKill(attacker, victim);
|
||||
|
||||
if (victim == null)
|
||||
{
|
||||
Log.WriteError($"[AddScriptKill] Victim is null");
|
||||
return;
|
||||
}
|
||||
|
||||
var statsSvc = ContextThreads[serverId];
|
||||
var playerDetection = Servers[serverId].PlayerDetections[attacker.ClientNumber];
|
||||
|
||||
@ -209,7 +215,7 @@ namespace StatsPlugin.Helpers
|
||||
|
||||
if (victim == null)
|
||||
{
|
||||
Log.WriteError($"Stats: Victim is null");
|
||||
Log.WriteError($"[AddStandardKill] Victim is null");
|
||||
return;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user