Restore Mistweaver functionality in Midnight#9
Open
EricaPomme wants to merge 4 commits into
Open
Conversation
The blanket 'if VgerCore.IsMidnight then return nil end' guard was too broad -- it disabled all buff-stack tracking for all Midnight players even out of combat, where aura data is fully readable. Replace with a per-entry issecretvalue() check inside the loop so that out-of-combat reads work normally and in-combat reads still return nil gracefully when spell IDs are secret.
Uses UNIT_SPELLCAST_SUCCEEDED to synthetically count stacks of SpellID 202090, with C_Traits talent detection for Way of the Crane (+2 vs +1 stacks per Tiger Palm). Bumped to 1.12.5.
Contributor
Author
|
Added back part of the guard. Playing my enh shaman was playing tones on combat end. It should currently only play for monk; or any class explicitly allowed by the guard. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Restores Teachings of the Monastery (SpellID 202090) stack tracking for Mistweaver Monks in WoW Midnight (12.0+). The buff stacks up to 4, granted by Tiger Palm (+1, or +2 with Way of the Crane selected) and consumed by Blackout Kick.
New approach: UNIT_SPELLCAST_SUCCEEDED
We count stacks synthetically by listening for Tiger Palm (100780) and Blackout Kick (100784) casts on the player, maintaining a local counter. This event delivers reliable spell IDs
without touching any protected data.
KittyOnEvent signature change (arg3)
UNIT_SPELLCAST_SUCCEEDED passes three event arguments: unitTarget, castGUID, spellID. The existing signature only accepted arg1 and arg2. We added arg3 to receive spellID. The handler
only acts when arg1 == "player", so no other event path is affected.
Way of the Crane detection via C_Traits
With the talent active, each Tiger Palm grants 2 stacks instead of 1. IsSpellKnown(388779) returns false. IsPlayerSpell(388779) returns true for all Monk specs regardless of whether the talent is selected (it's present in the class talent tree for every loadout). We use C_Traits tree traversal -- GetNodeInfo + entryIDsWithCommittedRanks -- to check whether the player has specifically committed their choice to the 388779 entry at that node. This correctly returns true/false per loadout.
Testing performed
Testing was performed against training dummies in Silvermoon on my Pandaren-A monk.