appeal website is always show on kick
previously banned for recursion fixed
This commit is contained in:
parent
d0be08629d
commit
3c0e101f14
@ -5,7 +5,7 @@
|
|||||||
<TargetFramework>netcoreapp2.1</TargetFramework>
|
<TargetFramework>netcoreapp2.1</TargetFramework>
|
||||||
<MvcRazorExcludeRefAssembliesFromPublish>false</MvcRazorExcludeRefAssembliesFromPublish>
|
<MvcRazorExcludeRefAssembliesFromPublish>false</MvcRazorExcludeRefAssembliesFromPublish>
|
||||||
<PackageId>RaidMax.IW4MAdmin.Application</PackageId>
|
<PackageId>RaidMax.IW4MAdmin.Application</PackageId>
|
||||||
<Version>2.1.1</Version>
|
<Version>2.1.2</Version>
|
||||||
<Authors>RaidMax</Authors>
|
<Authors>RaidMax</Authors>
|
||||||
<Company>Forever None</Company>
|
<Company>Forever None</Company>
|
||||||
<Product>IW4MAdmin</Product>
|
<Product>IW4MAdmin</Product>
|
||||||
@ -75,7 +75,7 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Update="Microsoft.NETCore.App"/>
|
<PackageReference Update="Microsoft.NETCore.App" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<Target Name="PreBuild" BeforeTargets="PreBuildEvent">
|
<Target Name="PreBuild" BeforeTargets="PreBuildEvent">
|
||||||
|
@ -217,14 +217,17 @@ namespace IW4MAdmin
|
|||||||
|
|
||||||
if (currentBan.Type == Penalty.PenaltyType.TempBan)
|
if (currentBan.Type == Penalty.PenaltyType.TempBan)
|
||||||
{
|
{
|
||||||
string formattedKick = String.Format(RconParser.GetCommandPrefixes().Kick, polledPlayer.ClientNumber, $"{loc["SERVER_TB_REMAIN"]} ({(currentBan.Expires - DateTime.UtcNow).TimeSpanText()} left)");
|
string formattedKick = String.Format(
|
||||||
|
RconParser.GetCommandPrefixes().Kick,
|
||||||
|
polledPlayer.ClientNumber,
|
||||||
|
$"{loc["SERVER_TB_REMAIN"]} ({(currentBan.Expires - DateTime.UtcNow).TimeSpanText()} {loc["WEBFRONT_PENALTY_TEMPLATE_REMAINING"]})");
|
||||||
await this.ExecuteCommandAsync(formattedKick);
|
await this.ExecuteCommandAsync(formattedKick);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
await player.Kick($"{loc["SERVER_BAN_PREV"]} {currentBan.Offense}", autoKickClient);
|
await player.Kick($"{loc["SERVER_BAN_PREV"]} {currentBan.Offense} ({loc["SERVER_BAN_APPEAL"]} {Website})", autoKickClient);
|
||||||
|
|
||||||
if (player.Level != Player.Permission.Banned && currentBan.Type == Penalty.PenaltyType.Ban)
|
if (player.Level != Player.Permission.Banned && currentBan.Type == Penalty.PenaltyType.Ban)
|
||||||
await player.Ban($"{loc["SERVER_BAN_PREV"]} {currentBan.Offense}", autoKickClient);
|
await player.Ban($"{currentBan.Offense}", autoKickClient);
|
||||||
|
|
||||||
// they didn't fully connect so empty their slot
|
// they didn't fully connect so empty their slot
|
||||||
Players[player.ClientNumber] = null;
|
Players[player.ClientNumber] = null;
|
||||||
|
@ -46,7 +46,7 @@ namespace IW4MAdmin.Plugins.Stats
|
|||||||
await Manager.RemovePlayer(E.Origin);
|
await Manager.RemovePlayer(E.Origin);
|
||||||
break;
|
break;
|
||||||
case GameEvent.EventType.Say:
|
case GameEvent.EventType.Say:
|
||||||
if (!string.IsNullOrEmpty(E.Data) &&
|
if (!string.IsNullOrEmpty(E.Data) &&
|
||||||
E.Origin.ClientId > 1)
|
E.Origin.ClientId > 1)
|
||||||
await Manager.AddMessageAsync(E.Origin.ClientId, E.Owner.GetHashCode(), E.Data);
|
await Manager.AddMessageAsync(E.Origin.ClientId, E.Owner.GetHashCode(), E.Data);
|
||||||
break;
|
break;
|
||||||
@ -84,8 +84,8 @@ namespace IW4MAdmin.Plugins.Stats
|
|||||||
await Manager.AddStandardKill(E.Origin, E.Target);
|
await Manager.AddStandardKill(E.Origin, E.Target);
|
||||||
break;
|
break;
|
||||||
case GameEvent.EventType.Damage:
|
case GameEvent.EventType.Damage:
|
||||||
// if (!E.Owner.CustomCallback)
|
// if (!E.Owner.CustomCallback)
|
||||||
Manager.AddDamageEvent(E.Data, E.Origin.ClientId, E.Target.ClientId, E.Owner.GetHashCode());
|
Manager.AddDamageEvent(E.Data, E.Origin.ClientId, E.Target.ClientId, E.Owner.GetHashCode());
|
||||||
break;
|
break;
|
||||||
case GameEvent.EventType.ScriptDamage:
|
case GameEvent.EventType.ScriptDamage:
|
||||||
killInfo = (E.Data != null) ? E.Data.Split(';') : new string[0];
|
killInfo = (E.Data != null) ? E.Data.Split(';') : new string[0];
|
||||||
@ -113,7 +113,6 @@ namespace IW4MAdmin.Plugins.Stats
|
|||||||
Utilities.CurrentLocalization.LocalizationIndex["PLUGINS_STATS_COMMANDS_TOP_TEXT"],
|
Utilities.CurrentLocalization.LocalizationIndex["PLUGINS_STATS_COMMANDS_TOP_TEXT"],
|
||||||
"/Stats/TopPlayersAsync");
|
"/Stats/TopPlayersAsync");
|
||||||
|
|
||||||
|
|
||||||
// meta data info
|
// meta data info
|
||||||
async Task<List<ProfileMeta>> getStats(int clientId)
|
async Task<List<ProfileMeta>> getStats(int clientId)
|
||||||
{
|
{
|
||||||
@ -169,7 +168,6 @@ namespace IW4MAdmin.Plugins.Stats
|
|||||||
double chestAbdomenRatio = 0;
|
double chestAbdomenRatio = 0;
|
||||||
double hitOffsetAverage = 0;
|
double hitOffsetAverage = 0;
|
||||||
double maxStrain = clientStats.Count(c => c.MaxStrain > 0) == 0 ? 0 : clientStats.Max(cs => cs.MaxStrain);
|
double maxStrain = clientStats.Count(c => c.MaxStrain > 0) == 0 ? 0 : clientStats.Max(cs => cs.MaxStrain);
|
||||||
//double maxAngle = clientStats.Max(cs => cs.HitLocations.Max(hl => hl.MaxAngleDistance));
|
|
||||||
|
|
||||||
if (clientStats.Where(cs => cs.HitLocations.Count > 0).FirstOrDefault() != null)
|
if (clientStats.Where(cs => cs.HitLocations.Count > 0).FirstOrDefault() != null)
|
||||||
{
|
{
|
||||||
@ -231,12 +229,6 @@ namespace IW4MAdmin.Plugins.Stats
|
|||||||
Value = Math.Round(maxStrain, 3),
|
Value = Math.Round(maxStrain, 3),
|
||||||
Sensitive = true
|
Sensitive = true
|
||||||
},
|
},
|
||||||
/*new ProfileMeta()
|
|
||||||
{
|
|
||||||
Key = "Max Angle Distance",
|
|
||||||
Value = Math.Round(maxAngle, 1),
|
|
||||||
Sensitive = true
|
|
||||||
}*/
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user