From 92f1d0514bea97d07b31efc2d86b097b6ec802ba Mon Sep 17 00:00:00 2001 From: Kuuuube <61125188+Kuuuube@users.noreply.github.com> Date: Fri, 4 Dec 2020 17:14:11 -0500 Subject: [PATCH] Update Chatter_Exterminator_Interp.cs --- .../Chatter_Exterminator_Interp.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Kuuube's_Chatter_Exterminator/Chatter_Exterminator_Interp.cs b/Kuuube's_Chatter_Exterminator/Chatter_Exterminator_Interp.cs index 02744e9..012297d 100644 --- a/Kuuube's_Chatter_Exterminator/Chatter_Exterminator_Interp.cs +++ b/Kuuube's_Chatter_Exterminator/Chatter_Exterminator_Interp.cs @@ -20,6 +20,8 @@ public AntiChatter(ITimer scheduler) : base(scheduler) { } private SyntheticTabletReport report; private const float threshold = 0.9f; private float _AntichatterOffsetY = 15; + private float _Xoffset = 1.96f; + private float _FuncStretch = 1.7f; public override void UpdateState(SyntheticTabletReport report) { @@ -50,7 +52,7 @@ public Vector2 Filter(Vector2 calcTarget) float target = 1 - threshold; float weight = (float)(1.0 - (1.0 / Pow((float)(1.0 / target), (float)1 / 1000))); - var weightModifier = (float)Pow(((distance * -1 + (AntichatterStrength - 100)) / 100), 999) + _AntichatterOffsetY; + var weightModifier = (float)Pow(((distance * -1 + (AntichatterStrength - _FuncStretch)) / _Xoffset), 19) + _AntichatterOffsetY; // Limit minimum if (weightModifier + _AntichatterOffsetY < 0) @@ -70,4 +72,4 @@ public Vector2 Filter(Vector2 calcTarget) [Property("Chatter Extermination Strength")] public float AntichatterStrength { set; get; } = 3; } -} \ No newline at end of file +}