# v12.0.1.2 (2026-04-01)

## Bug Fixes

### Combat reliability — complete overhaul
WoW 12.0's secret-value system restricts aura data reads in M+/rated combat. All alert and sound failures in combat have been resolved through three complementary approaches:

- **All event-driven `Evaluate()` calls are now deferred** via `C_Timer.After(0, ...)`. Direct calls from events like `PLAYER_TARGET_CHANGED` inherited taint from secure frame operations, causing `aura.spellId` to be flagged as "tainted by NemHotAlerts" and throw on the next read. Deferring breaks the taint chain.

- **`issecretvalue()` is now the first gate** in all aura evaluation paths, checked before any field access. This mirrors LifebloomGlow's pattern and is more robust than per-field guards — one check at the top, all fields safe below it.

- **SOTF detection now uses spell-cast tracking as a combat fallback.** `GetAuraDataBySpellID` returns a restricted placeholder in combat (all fields nil). The addon now also tracks SOTF via `UNIT_SPELLCAST_SUCCEEDED`: Swiftmend sets a `sotfProcPending` flag, and casting Rejuvenation/Germination/Regrowth clears it. This event is not subject to secret-value restrictions.

- **SOTF timer now starts immediately** when Swiftmend is cast, seeded from `GetTime()`, rather than waiting for a successful aura query.

- **SOTF alert now persists when entering combat** with the proc already active. `PLAYER_REGEN_DISABLED` carries forward the pending state so the combat fallback path keeps the alert alive.

- **`PLAYER_REGEN_DISABLED` and `PLAYER_REGEN_ENABLED` now registered** to re-evaluate on combat transitions.

### Other fixes
- Lifebloom scan switched to `GetAuraDataBySpellID` (providing the ID to the API rather than reading it back), bypassing secret-value comparison failures
- All `C_UnitAuras` API calls use the module-level localized table reference, consistent with LifebloomGlow's approach

## Options Panel
- Sounds section height corrected to match Nem: Pet Alerts exactly
- Alert rows and buttons repositioned to match Nem: Pet Alerts spacing

## Slash Commands
Added missing commands to match Nem: Pet Alerts parity:
- `/nha on` — Enable addon
- `/nha off` — Disable addon
- `/nha toggle` — Toggle on/off
- `/nha status` — Show enabled state, test mode, and per-alert status
- `/nha version` — Show addon version
- `/nha reset` — Wipe saved variables and reload UI
- `/nha unlock` — Unlock frame (complement to existing `/nha lock`)
- All commands available via `/hotalerts` alias

---

# v12.0.1.1 (2026-03-31)

Initial release of **Nem: HoT Alerts**. Part of the Nem addon suite.

---

## Overview

Nem: HoT Alerts is a Restoration Druid addon that provides text alerts, countdown timers, and icon proc glows for Lifebloom pandemic tracking and Soul of the Forest proc consumption. Built as a standalone, self-contained addon with full options panel, configurable sounds, and font customization — matching the Nem suite visual style.

---

## Text Alerts

- **Lifebloom Expiring** — displays `* LIFEBLOOM EXPIRING *` when Lifebloom enters its pandemic window (last 4.5 seconds of base duration). Anchored to a fixed 4.5s window so Swiftmend extensions never change the trigger timing
- **Soul of the Forest** — displays `* CAST REJUV *` when the Soul of the Forest proc buff is active on the player
- Both alerts support configurable text colors, flash animation, and independent enable/disable toggles
- Alert position is draggable and saved per session

## Countdown Timers

- **Lifebloom timer** — live per-frame countdown displayed beneath the LB alert text, color-coded by urgency:
  - `4.5s – 2.1s` → `#aaff00` yellow-green
  - `2.0s – 1.1s` → `#ffd000` gold
  - `1.0s and below` → `#ff6600` deep orange
- **Soul of the Forest timer** — live per-frame countdown displayed beneath the SOTF alert text, color-coded by urgency:
  - `15s – 10.1s` → `#aaff00` yellow-green
  - `10s – 5.1s` → `#ffd000` gold
  - `5.0s and below` → `#ff6600` deep orange
- Both timers are anchored to their respective alert rows and move together when the frame is repositioned
- Timer font, scale, and size all scale proportionally with the alert font settings
- Each timer has an independent **Show Timer** toggle in the options panel (checked by default)

## Icon Glow

- Attaches a LibCustomGlow-1.0 `ProcGlow` border glow directly to buff frame icons in the game UI
- **Lifebloom** icons glow in the configured LB color when inside the pandemic window
- **Empowered Rejuvenation / Germination** icons glow in the configured SOTF color when the Soul of the Forest proc was consumed into the cast (detected via icon ID change)
- Glow operates independently of text alert toggles — icon glow remains active even when the text alert for that spell is disabled
- Glow color automatically matches the configured alert colors
- Compatible with Compact unit frames (party, raid), Target frame, and Focus frame
- Handles buffFrame recycling correctly when LB falls off and the frame is reused by another aura
- Toggle on/off via the **Icon Glow** option in the Display section

## Sounds

- Configurable sound alert for **Lifebloom Expiring** — fires once on entry into the pandemic window
- Configurable sound alert for **Soul of the Forest** proc — fires once when the buff appears
- Preview button for each sound
- 11 bundled sounds in `Media\` folder
- LibSharedMedia-3.0 support for additional sounds from other addons

## Options Panel

Matches the Nem: Pet Alerts UI layout and style throughout.

- **Display section** — Enable Addon, Flash Animation, Icon Glow toggles; Alert Text Scale and Font Size sliders with live EditBox input; Alert Font dropdown (46 bundled fonts + LibSharedMedia extras)
- **Sounds section** — per-alert sound enable toggle, WowStyle1 dropdown picker, and Preview button for each alert
- **Alerts section** — per-alert enable/disable with color swatch (opens WoW color picker) and Show Timer toggle displayed inline
- **Buttons** — Test (cycling countdown preview through all color tiers), Unlock Frame (drag to reposition), Reset Position
- Test mode shows live cycling countdowns for both timers so all color tiers are visible during preview
- Version footer bottom-right

## Technical

- Single-file build — `NemHotAlerts.lua` only, no separate Options.lua
- Self-contained: bundled `Fonts\`, `Media\`, and `Libs\` folders
  - LibStub, CallbackHandler-1.0, LibSharedMedia-3.0, LibCustomGlow-1.0
- MIT licensed — Copyright (c) 2026 Nemreaper
- Druid-only with graceful chat message on other classes
- Slash commands: `/nha`, `/hotalerts`
- Addon compartment button support
- `OnUpdate` per-frame timer updates — smooth countdown independent of the 0.25s ticker
