1
0
mirror of https://github.com/RaidMax/IW4M-Admin.git synced 2025-06-11 15:52:25 -05:00

fixed profanity bug

fix the shared GUID connect
fix linux  log issue
This commit is contained in:
RaidMax
2018-09-08 20:20:11 -05:00
parent 36f7c5bc51
commit e221b830f6
9 changed files with 24 additions and 40 deletions

View File

@ -70,7 +70,7 @@ namespace IW4MAdmin.Plugins.ProfanityDeterment
foreach (string word in objectionalWords)
{
containsObjectionalWord |= Regex.IsMatch(E.Origin.Name.ToLower(), word, RegexOptions.IgnoreCase);
containsObjectionalWord |= Regex.IsMatch(E.Data.ToLower(), word, RegexOptions.IgnoreCase);
// break out early because there's at least one objectional word
if (containsObjectionalWord)

View File

@ -8,7 +8,7 @@ var plugin = {
if (gameEvent.Type === 3 ||
gameEvent.Type === 4) {
if (gameEvent.Origin.NetworkId === -805366929435212061) {
gameEvent.Origin.Kick('Your GUID is generic. Delete players/guids.dat and rejoin', _utilities.IW4MAdminClient);
gameEvent.Origin.Kick('Your GUID is generic. Delete players/guids.dat and rejoin', _IW4MAdminClient);
}
}
},

View File

@ -668,7 +668,7 @@ namespace IW4MAdmin.Plugins.Stats.Helpers
if (clientHistory.RatingHistoryId == 0)
{
ctx.Add(clientHistory);
Log.WriteDebug($"adding first time client history {client.ClientId}");
// Log.WriteDebug($"adding first time client history {client.ClientId}");
await ctx.SaveChangesAsync();
}
@ -696,7 +696,7 @@ namespace IW4MAdmin.Plugins.Stats.Helpers
.First();
ctx.Remove(ratingToRemove);
Log.WriteDebug($"remove oldest rating {client.ClientId}");
//Log.WriteDebug($"remove oldest rating {client.ClientId}");
await ctx.SaveChangesAsync();
}
@ -713,7 +713,7 @@ namespace IW4MAdmin.Plugins.Stats.Helpers
ctx.Update(ratingToUnsetNewest);
ctx.Entry(ratingToUnsetNewest).Property(r => r.Newest).IsModified = true;
ratingToUnsetNewest.Newest = false;
Log.WriteDebug($"unsetting previous newest flag {client.ClientId}");
//Log.WriteDebug($"unsetting previous newest flag {client.ClientId}");
await ctx.SaveChangesAsync();
}
}
@ -732,7 +732,7 @@ namespace IW4MAdmin.Plugins.Stats.Helpers
// add new rating for current server
ctx.Add(newServerRating);
Log.WriteDebug($"adding new server rating {client.ClientId}");
//Log.WriteDebug($"adding new server rating {client.ClientId}");
await ctx.SaveChangesAsync();
#endregion
@ -780,7 +780,7 @@ namespace IW4MAdmin.Plugins.Stats.Helpers
.First();
ctx.Remove(ratingToRemove);
Log.WriteDebug($"remove oldest overall rating {client.ClientId}");
//Log.WriteDebug($"remove oldest overall rating {client.ClientId}");
await ctx.SaveChangesAsync();
}
@ -797,7 +797,7 @@ namespace IW4MAdmin.Plugins.Stats.Helpers
ctx.Update(ratingToUnsetNewest);
ctx.Entry(ratingToUnsetNewest).Property(r => r.Newest).IsModified = true;
ratingToUnsetNewest.Newest = false;
Log.WriteDebug($"unsetting overall newest rating {client.ClientId}");
//Log.WriteDebug($"unsetting overall newest rating {client.ClientId}");
await ctx.SaveChangesAsync();
}
}
@ -816,7 +816,7 @@ namespace IW4MAdmin.Plugins.Stats.Helpers
ctx.Add(averageRating);
#endregion
Log.WriteDebug($"adding new average rating {client.ClientId}");
//Log.WriteDebug($"adding new average rating {client.ClientId}");
await ctx.SaveChangesAsync();
}
}