Commit Graph
219 Commits
Author SHA1 Message Date
Brues 73e8938d76 Use ClassicAPI for action-bar mapping, spell IDs, and dynamic pfUI icons
GetActionInfo:
- Add ClassicAPI.GetActionInfo wrapper; rewrite GetActionButtonInfo
  (Generic.lua) to use it and resolve names via GetSpellRecField /
  GetItem / GetMacroInfo, replacing the per-slot GameTooltip scan +
  texture heuristic. Powers reactive-ability slot detection.
- Delete the dead SuperWoW-GetActionText copy of GetActionButtonInfo.

Spell IDs in the index:
- IndexSpells now uses ClassicAPI GetSpellInfo(slot, bookType), whose
  10th return is the spellID, so every Spells entry carries .id (one
  call also replaces GetSpellName + GetSpellTexture).

Dynamic pfUI action-button icons (pairs with the pfUI fork change):
- GameTooltip.SetAction hook renders spells via ClassicAPI
  SetSpellByID(spell.id) instead of SetSpell(spellSlot, bookType) +
  manual rank text. Items stay location-based (instance data).
- Drop the redundant GetActionSpellSlot -> GetSpellCooldown cooldown
  shim in the pfUI handler; pfUI now routes through the hooked
  GetActionCooldown when it defers macro scanning to us.
2026-06-21 00:11:46 -05:00
Brues b28f4452b9 Make ClassicAPI a hard requirement; remove movement fallbacks
ClassicAPI is now required, not optional. The load-time requirement
check warns when it's missing (Core.lua), the same as Nampower/UnitXP,
and ClassicAPI-backed code calls the API directly with no fallbacks.

- ClassicAPI.lua: drop the HasUnitAuras/HasUnitSpeed/HasIsFalling
  capability gates and pcall hedging; wrappers call C_UnitAuras /
  GetUnitSpeed / IsFalling directly. Keep IsAvailable (used by the
  requirement check) and the version helpers.
- [moving]: ClassicAPI GetUnitSpeed is the only source. Removed the
  MonkeySpeed integration, the Nampower PlayerIsMoving branch, and the
  100 Hz position-tracking buffer in Core.lua's OnUpdate (with its
  POS_TRACK_INTERVAL constant and UnitPosition upvalue). Removed the
  now-dead speed==nil guards and WarnNoSpeedSource.
- README: ClassicAPI moved to Required; MonkeySpeed dropped from
  Supported Addons.
- docs/CLASSICAPI-TODO.md: record the mandatory/no-fallbacks policy.
2026-06-20 23:47:23 -05:00
Brues c05fc754e6 Add ClassicAPI dispel-type conditionals via C_UnitAuras
Introduce ClassicAPI.lua, a feature-detection layer for the ClassicAPI
client mod that mirrors NampowerAPI's HasMinimumVersion pattern
(IsAvailable / HasMinimumVersion / HasUnitAuras). UnitHasDispelType
scans a unit's auras via C_UnitAuras and reports the dispel type,
scanning debuffs or buffs based on a helpful flag.

Add conditionals backed by it:
- Debuff side (defensive cleanse): [magic] [curse] [disease] [poison]
  [dispellable] + negations
- Buff side (offensive dispel/strip): [magicbuff] [dispellablebuff]
  + negations

All are no-arg booleans, default to @target (honor @unit), and degrade
gracefully without ClassicAPI: positive checks return false, negated
return true, since vanilla cannot read aura dispel types. The existing
ValidateAura path is untouched. MacroErrorChecker auto-accepts them via
the Keywords table; they're registered in BOOLEAN_CONDITIONALS so they
parse as flags. Loaded after NampowerAPI in the TOC.
2026-06-20 23:03:23 -05:00
Brues 0d95c4a0a6 update nampower link 2026-06-20 21:58:02 -05:00
Josh Sachs d863387bce add [bg]/[nobg] conditional for battleground detection
Uses GetBattlefieldStatus to check whether any battlefield queue
slot is in the "active" state, which indicates the player is
currently inside a battleground instance.
2026-04-06 21:05:03 -04:00
Josh Sachs 0a240a52c0 fix bare [pet]/[nopet] conditionals not evaluating
pet and nopet were missing from BOOLEAN_CONDITIONALS, so bare
[pet] (no type argument) was parsed as a spell-name match against
UnitCreatureFamily instead of a simple existence check.
2026-04-02 12:31:42 -04:00
Jrc13245 fbbbb1fcce updates for unified tracking 2026-04-01 16:11:47 -04:00
Jrc13245 765256642a update immunity of cc spells not mistaken for immunity to dmg type 2026-03-31 20:04:13 -04:00
Jrc13245 25b689f5cb fix non standard token usage like focustarget 2026-03-30 16:25:01 -04:00
Jrc13245 f2046497bd fix some spells not working properly when target explicitly set 2026-03-30 08:16:27 -04:00
Jrc13245 498fa90f45 fix firstaction interaction with applymain and applyoff 2026-03-28 10:25:33 -04:00
Jrc13245 719021ff65 Add set conditional, rmarkorder, Reliquary DBC integration, and fix immunity tracking false positives 2026-03-27 16:01:34 -04:00
Jrc13245 58974de765 no more forced addon disable, just warnings about required dlls, and also multiscan + help conditional works on friendlies 2026-03-24 07:50:13 -04:00
Jrc13245 5bb8ebe9b7 add item count support for inbag/noinbag conditional, fix macro frame whitelist and error log on macro frame 2026-03-21 12:03:46 -04:00
Jrc13245 72de9a00cc flyout compatibility 2026-03-20 21:44:12 -04:00
Jrc13245 137e08a209 fix target overflowframe and possible immunity system fix 2026-03-17 18:25:20 -04:00
Jrc13245 4ddac30726 fix inrange distance measuring, add distance range count threshold for enemy count, add filters for count mode, fix stopattack 2026-03-15 11:11:40 -04:00
Jrc13245 de8760f872 fix item counts on actionbars and new conditional addition facing and nofacing 2026-03-14 09:02:11 -04:00
Jrc13245 50a9cc1913 fix class conditional and stopattack defer 2026-03-13 20:53:59 -04:00
Jrc13245 efdcde3eca performance updates, meleerange conditional checks if unit is alive 2026-03-11 19:57:33 -04:00
Jrc13245 ff73210d2d some debug 2026-03-09 15:37:51 -04:00
Jrc13245 69b9c08a2b fix meleerange and count mode 2026-03-08 16:38:57 -04:00
Jrc13245 b4a442e23a fix target by class with no target selected 2026-03-08 12:49:52 -04:00
Jrc13245 470ad3fd24 fix cleartarget conditional 2026-03-07 16:34:26 -05:00
Jrc13245 46c3f3a07c update deferstopattack 2026-03-07 11:04:18 -05:00
Jrc13245 5c67b52c4e fix reatargeting and stopattack 2026-03-07 11:02:32 -05:00
Jrc13245 348c621c5d remove cleartarget conditional, update stopattack 2026-03-07 11:00:29 -05:00
Jrc13245 0de2747175 update stopattack and cleartarget 2026-03-06 21:16:38 -05:00
Jrc13245 aca7b2af3b retarget conditional, fix defer frame to use polling approach 2026-03-06 20:36:24 -05:00
Jrc13245 720246e473 defer stopattack to the next frame 2026-03-06 20:21:42 -05:00
Jrc13245 52b831c2c2 stopattack and cleartarget conditionals 2026-03-06 20:14:08 -05:00
Jrc13245 bb6b8a0d5b make stopattack faster 2026-03-06 20:04:58 -05:00
Jrc13245 17f28dcdfd feature mouseuse and attempt to fix stopattack 2026-03-06 19:43:36 -05:00
Jrc13245 34190ccbd8 fix debuff and buff tracking 2026-03-06 18:55:39 -05:00
Jrc13245 2f698403e5 fix showtooltip icon for multiple evaluation keywords 2026-03-06 17:35:44 -05:00
Jrc13245 9c05a6fc6a fix pfui loading objects without superwow 2026-03-03 11:10:55 -05:00
Jrc13245 82b2ab889f remove superwow requirement by using nampower, update nampower support to 3_1_0 2026-03-02 19:55:53 -05:00
Jrc13245 6fa4e28318 Merge branch 'no-superwow' 2026-03-02 17:52:41 -05:00
Jrc13245 b56beef4b2 remove more superwow only functions 2026-03-02 09:01:34 -05:00
Jrc13245 685f2d3c59 fix focus nil error 2026-03-01 11:27:39 -05:00
Jrc13245 2f0f000733 no superwow required, update for nampower 3 2026-03-01 09:33:41 -05:00
Jrc13245 58c7ab8457 castsequence always resets when all spells are done casting, reset=X where X is a number is only for when the sequence has not been advanced in X seconds, reset 2026-02-27 14:54:19 -05:00
Jrc13245 a50a5c7e7c use pfui swingtimer if SP not available, fix vanish regeant count 2026-02-27 07:59:05 -05:00
Jrc13245 836c0e0020 updates for inbag 2026-02-26 17:28:36 -05:00
Jrc13245 f9d405ce1b fix inbag item icon updates and ? ignore tooltip 2026-02-26 17:21:02 -05:00
Jrc13245 4b673b14a7 fix auto shot spammable for all classes and when used with conditionals 2026-02-25 21:47:27 -05:00
Jrc13245 543f2e80fe fixes for overflow frames 2026-02-24 21:40:44 -05:00
Jrc13245 9811d9c894 update for nampower 2_41_0 and update readme 2026-02-22 20:00:21 -05:00
Jrc13245 bc193c24bc update overflow frame to disable default, rename frame for clarity, update readme for information 2026-02-21 11:39:27 -05:00
Jrc13245 d41271bbed remove gmatch and match polyfill and fix reactive surprise attack 2026-02-20 14:57:39 -05:00