From 8a21fc721f58c1955e2aff81a25d2d77677ec686 Mon Sep 17 00:00:00 2001 From: Aireil <33433913+Aireil@users.noreply.github.com> Date: Mon, 4 Mar 2024 18:51:25 +0100 Subject: [PATCH] feat: add AdjustedTotalCastTime to BattleChara (#1694) * feat: add AdjustedTotalCastTime to BattleChara * Update Dalamud/Game/ClientState/Objects/Types/BattleChara.cs Co-authored-by: KazWolfe --------- Co-authored-by: KazWolfe --- .../Game/ClientState/Objects/Types/BattleChara.cs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Dalamud/Game/ClientState/Objects/Types/BattleChara.cs b/Dalamud/Game/ClientState/Objects/Types/BattleChara.cs index 63a5b828a..0c5d16675 100644 --- a/Dalamud/Game/ClientState/Objects/Types/BattleChara.cs +++ b/Dalamud/Game/ClientState/Objects/Types/BattleChara.cs @@ -1,6 +1,7 @@ using System; using Dalamud.Game.ClientState.Statuses; +using Dalamud.Utility; namespace Dalamud.Game.ClientState.Objects.Types; @@ -57,8 +58,22 @@ public unsafe class BattleChara : Character /// /// Gets the total casting time of the spell being cast by the chara. /// + /// + /// This can only be a portion of the total cast for some actions. + /// Use AdjustedTotalCastTime if you always need the total cast time. + /// + [Api10ToDo("Rename so it is not confused with AdjustedTotalCastTime")] public float TotalCastTime => this.Struct->GetCastInfo->TotalCastTime; + /// + /// Gets the plus any adjustments from the game, such as Action offset 2B. Used for display purposes. + /// + /// + /// This is the actual total cast time for all actions. + /// + [Api10ToDo("Rename so it is not confused with TotalCastTime")] + public float AdjustedTotalCastTime => this.Struct->GetCastInfo->AdjustedTotalCastTime; + /// /// Gets the underlying structure. ///