1
0
mirror of https://github.com/RaidMax/IW4M-Admin.git synced 2025-06-10 15:20:48 -05:00

update anti-cheat offset calculation

This commit is contained in:
RaidMax
2019-06-12 10:27:15 -05:00
parent e8af8914d2
commit 48c86d8cf5
3 changed files with 48 additions and 26 deletions

View File

@ -29,7 +29,10 @@ namespace IW4MAdmin.Plugins.Stats.Cheat
public const double MaxStrainBan = 0.9;
public static double MaxOffset(int sampleSize) => Math.Exp(Math.Max(-3.07 + (-3.07 / Math.Sqrt(sampleSize)), -3.07 - (-3.07 / Math.Sqrt(sampleSize))) + 4 * (0.869));
private const double _offsetMeanLog = -2.727273;
private const double _offsetSdLog = 0.458325;
public static double MaxOffset(int sampleSize) => Math.Exp(Math.Max(_offsetMeanLog + (_offsetMeanLog / Math.Sqrt(sampleSize)), _offsetMeanLog - (_offsetMeanLog / Math.Sqrt(sampleSize))) + 4 * (_offsetSdLog));
public const double MaxStrainFlag = 0.36;
public static double GetMarginOfError(int numKills) => 1.6455 / Math.Sqrt(numKills);