File Details
TomoCastbar
- R
- Mar 27, 2026
- 65.53 KB
- 167
- 12.0.5+2
- Retail
File Name
TomoCastbar-2.0.0.zip
Supported Versions
- 12.0.5
- 12.0.1
- 12.0.0
## [2.0.0] — 2026-03-27
### New Features
#### LibSharedMedia-3.0 Support
- **Bundled library** — LibStub, CallbackHandler-1.0, and LibSharedMedia-3.0 are now included in `Libs/`. No external dependency required.
- **Bar texture picker** — Lists all statusbar textures registered by LSM from other addons (SharedMedia, etc.). Replaces the 3-option dropdown.
- **Font picker** — All fonts registered in LSM are available for spell name and timer texts.
- **Live texture update** — When another addon changes the global LSM statusbar, all castbars update instantly without a reload.
- **Graceful fallback** — If LSM is unavailable or a media name is not found, falls back to built-in Blizzard textures and fonts.
#### Spark Animations — 4 Styles
The spark system has been completely rewritten as a dedicated module (`Modules/SparkAnimations.lua`). All styles share the same texture pool (1 head + 1 glow + 4 tails).
| Style | Description |
|---|---|
| **Comet** *(default)* | Classic trailing glow. Bright head with 4 fading tails. Clean and performant. |
| **Pulse** | Concentric expanding rings ripple outward from the leading edge, fading as they expand. |
| **Helix** | Tail elements oscillate vertically in phase-offset sine waves around the leading edge. |
| **Glitch** | Randomized RGB chromatic aberration layers flicker with a digital glitch aesthetic. |
New config options: Animation Style dropdown, Glow Intensity slider, Tail Intensity slider, Spark Head Color / Glow Color / Tail Color pickers.
#### Localization — 7 Languages
TomoCastbar now ships with 8 locales covering all major World of Warcraft regions:
| File | Language | Region |
|---|---|---|
| `enUS.lua` | English | Americas, Oceania |
| `frFR.lua` | Français | France, Belgium |
| `deDE.lua` | Deutsch | Germany, Austria, Switzerland |
| `esES.lua` | Español | Spain + Latin America (esMX) |
| `itIT.lua` | Italiano | Italy |
| `ptBR.lua` | Português | Brazil + Portugal (ptPT) |
| `ruRU.lua` | Русский | Russia, CIS |
| `zhCN.lua` | 简体中文 | Mainland China |
Each locale is loaded conditionally (`if GetLocale() ~= "xx" then return end`) so only one locale is active at runtime. enUS is the base — all keys fall back to English if a translation is missing. All 81 localization keys are covered in every language.
#### Timer Format Options
Three display modes selectable in config:
| Mode | Display | Use case |
|---|---|---|
| Remaining | `1.5` | Classic minimal |
| Remaining / Total | `1.5 / 3.0` | Arena — gauge cast length |
| Elapsed | `1.5` | Personal tracking preference |
#### Spell Name Truncation
New Max Length slider (0–40 characters). Long spell names are truncated with `…` to prevent overlap with the timer text. Set to `0` to disable.
#### Class Color for Target / Focus Bars
New Class Color checkbox. When enabled, target and focus castbars use the unit's class color. Falls back to the configured Cast Color for NPCs and unknown classes. Particularly useful in arena.
### Improvements
#### Precise Per-Cast Latency
- Previously used `GetNetStats()` which returns average world latency, not per-spell latency.
- Now tracks `UNIT_SPELLCAST_SENT` to measure the exact client→server round-trip for the current spell.
- Matches the behavior of Quartz's Latency module.
#### Interrupter Name Display
- Interrupt text now shows: `Interrupted (PlayerName)` instead of just `Interrupted`.
- GUID resolved via `UnitNameFromGUID()` from the `UNIT_SPELLCAST_INTERRUPTED` event.
#### Pushback Detection (`UNIT_SPELLCAST_DELAYED`)
- Now registered for all three units.
- When a cast is pushed back by damage, timings are re-read from the API and the bar updates instantly.
#### Zone Change / Login Recovery (`PLAYER_ENTERING_WORLD`)
- All three castbars register `PLAYER_ENTERING_WORLD`.
- Ongoing casts on the target or focus are now correctly detected after login, UI reload, or zone change.
#### Performance — OnUpdate Throttling
- Bar fill value and spark position update every frame (smooth 60 fps).
- Timer text throttled to **20 updates/second** (every 50ms), down from 60. ~66% reduction in `string.format` calls per castbar during combat.
#### Performance — Local Upvalues
- All frequently-called globals (`GetTime`, `math.max`, `math.min`, `string.format`, `UnitCastingInfo`, etc.) are cached as local upvalues at module scope.
- Eliminates repeated `_G` table lookups in `OnUpdate`.
#### Performance — Reusable Cast Info Table
- `GetSafeCastInfo()` reuses a single module-level table instead of allocating a new one per call.
- Reduces GC pressure during high-event combat.
### Files Changed
| File | Change |
|---|---|
| `TomoCastbar.toc` | Libs entries, all 8 locale entries, Notes-XX fields, version 2.0.0 |
| `Libs/LibStub/LibStub.lua` | **New** — bundled |
| `Libs/CallbackHandler-1.0/CallbackHandler-1.0.lua` | **New** — bundled |
| `Libs/LibSharedMedia-3.0/LibSharedMedia-3.0.lua` | **New** — bundled |
| `Modules/SparkAnimations.lua` | **New** — 4 animation styles, shared spark texture pool |
| `Modules/Castbar.lua` | LSM integration, spark dispatch, all new events, latency fix, perf improvements |
| `Core/Database.lua` | Added `barTextureLSM`, `fontLSM`, `sparkStyle`, `sparkGlowAlpha`, `sparkTailAlpha`, `sparkColor`, `sparkGlowColor`, `sparkTailColor`, `timerFormat`, `spellNameMaxLen`, `useClassColor` |
| `Locales/enUS.lua` | 81 keys, 16 new for v2.0 features |
| `Locales/frFR.lua` | Updated — all 81 keys translated |
| `Locales/deDE.lua` | **New** — German, full 81 keys |
| `Locales/esES.lua` | **New** — Spanish (ES + MX), full 81 keys |
| `Locales/itIT.lua` | **New** — Italian, full 81 keys |
| `Locales/ptBR.lua` | **New** — Portuguese (BR + PT), full 81 keys |
| `Locales/ruRU.lua` | **New** — Russian, full 81 keys |
| `Locales/zhCN.lua` | **New** — Simplified Chinese, full 81 keys |
| `Config/ConfigUI.lua` | *(pending)* New sections: Textures & Media (LSM), Spark Animation, Advanced |
### Upgrade Notes
- **No action required** — existing saved variables are automatically merged with new defaults.
- The new `barTextureLSM` defaults to `"Blizzard"` — same visual result as before.
- LibSharedMedia-3.0 is bundled. If already installed by another addon, LibStub's versioning handles coexistence safely.
- Use `/tcb reset` to apply all defaults from scratch if needed.

