From 22f7578ed23d5927bf8a54c9c4e390688548dc5f Mon Sep 17 00:00:00 2001 From: Xian55 <367101+Xian55@users.noreply.github.com> Date: Wed, 15 May 2024 21:39:19 +0200 Subject: [PATCH] Addon: [1.7.57] Added paladin Holy Power which count as a Combo Point. Core: RequirementFactory: Map Paladin Holy Power to combo point --- Addons/DataToColor/DataToColor.lua | 2 +- Addons/DataToColor/DataToColor.toc | 2 +- Core/Requirement/RequirementFactory.cs | 4 +++- README.md | 1 + 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Addons/DataToColor/DataToColor.lua b/Addons/DataToColor/DataToColor.lua index e0d915c0..bcee9f45 100644 --- a/Addons/DataToColor/DataToColor.lua +++ b/Addons/DataToColor/DataToColor.lua @@ -681,7 +681,7 @@ function DataToColor:CreateFrames() DataToColor.uiErrorMessage = 0 Pixel(int, DataToColor:CastingInfoSpellId(DataToColor.C.unitPlayer), 53) -- SpellId being cast - Pixel(int, DataToColor:getAvgEquipmentDurability() * 100 + (GetComboPoints(DataToColor.C.unitPlayer, DataToColor.C.unitTarget) or 0), 54) + Pixel(int, DataToColor:getAvgEquipmentDurability() * 100 + ((DataToColor.C.CHARACTER_CLASS_ID == 2 and UnitPower(DataToColor.C.unitPlayer, Enum.PowerType.HolyPower) or GetComboPoints(DataToColor.C.unitPlayer, DataToColor.C.unitTarget)) or 0), 54) -- for paladin holy power or combo points local playerBuffCount = DataToColor:populateAuraTimer(UnitBuff, DataToColor.C.unitPlayer, DataToColor.playerBuffTime) local playerDebuffCount = DataToColor:populateAuraTimer(UnitDebuff, DataToColor.C.unitPlayer, nil) diff --git a/Addons/DataToColor/DataToColor.toc b/Addons/DataToColor/DataToColor.toc index 9a735411..064d4bab 100644 --- a/Addons/DataToColor/DataToColor.toc +++ b/Addons/DataToColor/DataToColor.toc @@ -3,7 +3,7 @@ ## Title: DataToColor ## Author: FreeHongKongMMO ## Notes: Displays data as colors -## Version: 1.7.56 +## Version: 1.7.57 ## RequiredDeps: ## OptionalDeps: Ace3, LibRangeCheck, LibClassicCasterino ## SavedVariables: diff --git a/Core/Requirement/RequirementFactory.cs b/Core/Requirement/RequirementFactory.cs index 6a967352..71609bb6 100644 --- a/Core/Requirement/RequirementFactory.cs +++ b/Core/Requirement/RequirementFactory.cs @@ -206,6 +206,7 @@ public RequirementFactory(IServiceProvider sp, ClassConfiguration classConfig) { "UnholyRune", playerReader.UnholyRune }, { "TotalRune", playerReader.MaxRune }, { "Combo Point", playerReader.ComboPoints }, + { "Holy Power", playerReader.ComboPoints }, { "Durability%", playerReader.AvgEquipDurability }, { "BagCount", bagReader.BagItemCount }, { "FoodCount", bagReader.FoodItemCount }, @@ -602,7 +603,8 @@ PowerType.Energy or PowerType.RuneFrost => playerReader.FrostRune, PowerType.RuneUnholy => playerReader.UnholyRune, PowerType.HealthCost => playerReader.HealthCurrent, - //PowerType.ComboPoints => playerReader.ComboPoints, + PowerType.HolyPower or + PowerType.ComboPoints => playerReader.ComboPoints, _ => throw new NotImplementedException($"{type.ToStringF()}"), }; diff --git a/README.md b/README.md index 06dba9e7..d0d420bd 100644 --- a/README.md +++ b/README.md @@ -1208,6 +1208,7 @@ Formula: `[Keyword] [Operator] [Numeric integer value]` | `UnholyRune` | Player current unholy runes | | `TotalRune` | Player current runes (blood+frost+unholy+death) | | `Combo Point` | Player current combo points on the target | +| `Holy Power` | Player current Holy Power points on the target | | `Durability%` | Player worn equipment average durability. **0-99** value range. | | `BagCount` | How many items in the player inventory | | `FoodCount` | Returns the highest amount of food type, item count |