OneCoke - Player Notification

Track nearby players with a lightweight addon that detects both factions and lets you target, whisper, watch, or look them up instantly.

File Details

OneCoke - PlayerNotification.zip

  • R
  • Jul 10, 2026
  • 15.56 KB
  • 7
  • 2.5.6+5
  • Classic TBC

File Name

OneCoke - PlayerNotification.zip

Supported Versions

  • 2.5.6
  • 2.5.5
  • 2.5.4
  • 2.5.3
  • 2.5.2
  • 2.5.1
## 2026-07-10

**Rescan cooldown** — the Nearby list was re-sorting constantly because every
re-detection of a player (nameplate, mouseover, combat log, etc.) bumped
their timestamp and jumped them to the top of the list. Added a cooldown so
an already-recorded player is left alone for a while before being updated
again.
- Default 30 seconds.
- Exposed as a "Rescan cooldown" slider in Settings (0–120s, step 5).

**Detection notifications** — added a notice when a new player is spotted,
separate from Watch List alerts.
- Fading on-screen toast with the player's class-colored name (~2s hold,
  1s fade). Toggle: "Show a fading screen notification when a player is
  detected."
- A short sound cue, currently FileDataID 567203 (mDeathImpactColossalDirtA).
  Toggle: "Play a sound when a player is detected."
- "Test Sound" button in Settings to preview the cue without waiting for a
  real detection.
- Both respect the existing "Show players from my own faction" filter, so
  they don't fire on friendly players by default.

**Scan restriction dropdown** — added a Settings dropdown to pause scanning
based on location:
- Always scan (no restrictions) — default
- Disable scan completely
- Disable scan in major cities (the eight racial capitals)
- Disable scan in non-PvP cities (racial capitals + Shattrath City)
- Disable scan in non-PvP areas (any sanctuary-flagged zone, cities or not)

### Files touched
- `Core.lua` — new saved-variable defaults (`rescanSeconds`, `screenNotify`,
  `detectSound`, `scanDisableMode`).
- `Scanner.lua` — rescan-gate logic, `NotifyDetected`/`PlayDetectSound`,
  `IsScanningDisabled` and the city/zone lookup tables.
- `UI.lua` — detection toast frame (`ShowDetectionToast`).
- `Options.lua` — new slider and dropdown widgets, and the checkboxes/button
  wiring all of the above into the Settings panel.