diff --git a/Resources/AnimationLockTime.json b/Resources/AnimationLockTime.json index f204cf956..7bae09c85 100644 --- a/Resources/AnimationLockTime.json +++ b/Resources/AnimationLockTime.json @@ -183,6 +183,7 @@ "7527": 0.6, "7528": 0.6, "7529": 0.6, + "7541": 0.6, "7546": 0.6, "7548": 0.6, "7557": 0.6, diff --git a/RotationSolver.Basic/DataCenter.cs b/RotationSolver.Basic/DataCenter.cs index 3abffcd94..2d9db4cc8 100644 --- a/RotationSolver.Basic/DataCenter.cs +++ b/RotationSolver.Basic/DataCenter.cs @@ -312,10 +312,8 @@ public static float DPSTaken public static ActionID LastGCD { get; private set; } = 0; public static ActionID LastAbility { get; private set; } = 0; - public static float Ping => Math.Min(Math.Min(ActionFetchTime /2, Service.Config.MaxPing), - LastRTT == 0 ? float.MaxValue : LastRTT); - public static float ActionFetchTime { get; private set; } = 0.07f; - public static float LastRTT { get; set; } = 0; + public static float Ping => Math.Min(Service.Config.MaxPing, LastRTT); + public static float LastRTT { get; set; } = 0.1f; public const float MinAnimationLock = 0.6f; public static unsafe void AddActionRec(Action act) @@ -328,18 +326,9 @@ public static unsafe void AddActionRec(Action act) case ActionCate.Spell: case ActionCate.WeaponSkill: LastAction = LastGCD = id; - if (ActionManager.GetAdjustedCastTime(ActionType.Spell, (uint)id) == 0) - { - ActionFetchTime = WeaponElapsed; - } break; case ActionCate.Ability: LastAction = LastAbility = id; - - if (!act.IsRealGCD() && ActionManager.GetMaxCharges((uint)id, Service.Player.Level) < 2) - { - ActionFetchTime = ActionManager.Instance()->GetRecastGroupDetail(act.CooldownGroup - 1)->Elapsed; - } break; default: return; diff --git a/RotationSolver/UI/RotationConfigWindow_Debug.cs b/RotationSolver/UI/RotationConfigWindow_Debug.cs index 3aa82d4ac..979fc457d 100644 --- a/RotationSolver/UI/RotationConfigWindow_Debug.cs +++ b/RotationSolver/UI/RotationConfigWindow_Debug.cs @@ -51,7 +51,6 @@ private unsafe void DrawStatus() ImGui.Text("TimeToNext: " + DataCenter.NextAbilityToNextGCD.ToString()); ImGui.Text("WeaponElapsed: " + DataCenter.WeaponElapsed.ToString()); ImGui.Text("AnimationLock: " + DataCenter.ActionRemain.ToString()); - ImGui.Text("Fetch Time: " + DataCenter.ActionFetchTime.ToString()); ImGui.Text("Have pet: " + DataCenter.HasPet.ToString()); ImGui.Text("Hostile Near Count: " + DataCenter.NumberOfHostilesInRange.ToString()); diff --git a/RotationSolver/UI/RotationConfigWindow_Param.cs b/RotationSolver/UI/RotationConfigWindow_Param.cs index 509bf1474..df438c406 100644 --- a/RotationSolver/UI/RotationConfigWindow_Param.cs +++ b/RotationSolver/UI/RotationConfigWindow_Param.cs @@ -31,7 +31,7 @@ private void DrawParamBasic() ref Service.Config.MaxPing, Service.Default.MaxPing, min: 100, max: 500); ImGui.SameLine(); - ImGui.Text($" Ping:{DataCenter.LastRTT:F3} Fetch: {DataCenter.ActionFetchTime:F3}"); + ImGui.Text($" Ping:{DataCenter.LastRTT:F3}"); DrawFloatNumber(LocalizationManager.RightLang.ConfigWindow_Param_ActionAhead, ref Service.Config.ActionAhead, Service.Default.ActionAhead, max: 0.5f); diff --git a/RotationSolver/Updaters/ActionUpdater.cs b/RotationSolver/Updaters/ActionUpdater.cs index afa69a6b9..90f2bfd41 100644 --- a/RotationSolver/Updaters/ActionUpdater.cs +++ b/RotationSolver/Updaters/ActionUpdater.cs @@ -175,7 +175,7 @@ internal unsafe static void DoAction() && ActionManager.Instance()->QueuedActionId != NextAction.AdjustedID || Service.Player.CurrentHp == 0) return; - var maxAhead = Math.Max(DataCenter.MinAnimationLock - DataCenter.ActionFetchTime - 0.03f, 0.08f); + var maxAhead = Math.Max(DataCenter.MinAnimationLock - DataCenter.Ping, 0.08f); var ahead = Math.Min(maxAhead, Service.Config.ActionAhead); //GCD