Commit Graph
525 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 59aad5b662 correct links 2026-06-20 23:11:38 -05:00
Brues 0ec082992d Add ClassicAPI (optional) to README requirements
List ClassicAPI in the Requirements table as Optional — it enables the
dispel-type conditionals ([magic], [curse], [disease], [poison],
[dispellable], [magicbuff]), which degrade gracefully without it.
2026-06-20 23:05:08 -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 86d16f507b Point README wiki links to brues-code fork
The wiki lives on the brues-code fork; update all 10 Full Documentation
links from jrc13245 to brues-code. SP_SwingTimer download links (a
separate project) are left untouched.
2026-06-20 23:02:09 -05:00
Brues 69318572c7 Add ClassicAPI adoption backlog
Document opportunities to use ClassicAPI (modern C_* API backport for
the 1.12 client) in the addon: C_UnitAuras for target aura/dispel-type
conditionals, GetWeaponEnchantInfo enchant IDs for poison/imbue checks,
GetUnitSpeed to drop the MonkeySpeed dependency, plus C_Spell, C_Timer,
UnitGUID, native focus, and Tier-3 items.

Each entry cites API.md line refs and the addon files it touches, and
notes the cross-cutting requirement to feature-detect with fallback
(mirroring the nampower HasMinimumVersion pattern).
2026-06-20 22:22:27 -05:00
Brues 51b6b26985 Auto-discover registered slash commands in macro checker
The macro syntax checker validated commands against a hardcoded
VALID_COMMANDS table, so any command not on the list (e.g. /dump) was
flagged "Unknown command" even when the client/addon accepted it.

Add CleveRoids.IsRegisteredCommand: scans SlashCmdList and its
SLASH_<KEY>N globals into a cache (rebuilt on PLAYER_ENTERING_WORLD,
lazy-built on first use) so any command registered the addon way is
accepted automatically. Wire it into the validator alongside the
hardcoded table and the user whitelist.

Trim now-redundant hardcoded entries: the third-party addon block
(/aux, /rinse, /cursive, ...) and this addon's own self-registering
commands. Keep only commands NOT in SlashCmdList: Blizzard builtins
(/cast, /target, /run, ...), /focus (pfUI, only present when loaded),
and the chat/social/emote builtins FrameXML handles internally.
2026-06-20 22:11:47 -05:00
Brues 0d95c4a0a6 update nampower link 2026-06-20 21:58:02 -05:00
Torio 3a196c484f Merge pull request #154 from josh-sachs/feature/bg-conditional
add [bg]/[nobg] conditional for battleground detection
2026-04-07 17:10:58 -04:00
Jrc13245 f12d49ae8e add rupture to personal debuffs 2026-04-07 17:13:20 -04: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
Torio 97bc74c3b4 Merge pull request #153 from josh-sachs/fix/pet-boolean-conditional
fix bare [pet]/[nopet] conditionals not evaluating
2026-04-02 19:28:58 -04:00
Jrc13245 e51c4f7136 fix pfui libdebuff and extra overflowframe tracking 2026-04-02 15:02:50 -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 95bf408ed7 fix pet, focus, and add new conditional playercontrolled 2026-04-01 14:41:24 -04:00
Jrc13245 809b04b9de fix debuff tracking alongside pfui 2026-04-01 14:18:08 -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 7577c76050 fix highlight 2026-03-29 10:24:13 -04:00
Jrc13245 3aa3d616c1 fix highlights with multiline 2026-03-29 08:58:51 -04:00
Jrc13245 ecdc9e92f3 add new shorter aliases 2026-03-28 17:54:53 -04:00
Jrc13245 ae6f4105c2 add new shorter aliases 2026-03-28 17:54:28 -04:00
Torio 09862dba48 Merge pull request #141 from DCV-2142/main
Update OverflowBuffFrame.lua
2026-03-28 17:44:21 -04:00
DCV-2142 af1e57c254 Update OverflowBuffFrame.lua
Fixed player's buff frame not appearing when enabling test mode
2026-03-28 19:30:12 +02:00
Jrc13245 498fa90f45 fix firstaction interaction with applymain and applyoff 2026-03-28 10:25:33 -04:00
Torio 14ec23a6f7 Merge pull request #139 from verge20/main
fix CreatureTypes bug
2026-03-27 17:19:52 -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
verge20 cafc6924a7 fix CreatureTypes bug 2026-03-26 20:13:33 +08:00
Jrc13245 aea93b14bf filter player when using multiscan help 2026-03-24 08:20:15 -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 cb5ce8f824 warn when pfui macrotweak is enabled 2026-03-24 07:22:11 -04:00
Jrc13245 223edb6cfb add conditional rangetimer and rtimer and their noable versions 2026-03-23 16:08:16 -04:00
Torio 9137d6d268 Merge pull request #136 from verge20/main
fix zhCN translation bug
2026-03-22 15:57:22 -04:00
verge20 eb4c6d5470 fix zhCN bug 2026-03-22 00:55:55 +00: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 0e6371692e update for DragonFlightReloaded 2026-03-21 09:02:04 -04:00
Jrc13245 72de9a00cc flyout compatibility 2026-03-20 21:44:12 -04:00
Jrc13245 4a34cf25ce fix talent error 2026-03-20 13:37:50 -04:00
Jrc13245 cc87fac66f fix table error 2026-03-19 13:49:09 -04:00
Jrc13245 137e08a209 fix target overflowframe and possible immunity system fix 2026-03-17 18:25:20 -04:00
Jrc13245 11e33fc0d3 fix match error 2026-03-15 14:18:21 -04:00
Jrc13245 9b2c0d2191 fix nodebuff returning false on broken cc, fix multiscan nearest + class filter 2026-03-15 13:01:23 -04:00
Jrc13245 d380fe314c feature live passing conditional checker 2026-03-15 12:17:45 -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 03e124bcc0 bump version 2026-03-13 08:31:05 -04:00