Version 6.1.1 - Chat & Nameplate Level Fixes

Bugfixes:
- Fixed targeting high-level players overwriting known level with -1
- Chat now shows "??" instead of -1 for unknown levels
- Nameplates now use stored level from database after reload
- Nameplate level color now uses difficulty color when loaded from DB

Config Changes:
- Chat player level display now disabled by default
This commit is contained in:
Meow
2026-01-08 19:02:02 +01:00
parent 9aec4c57df
commit e83ff80538
7 changed files with 42 additions and 7 deletions
+16 -3
View File
@@ -1,6 +1,6 @@
# pfUI - Turtle WoW Edition
[![Version](https://img.shields.io/badge/version-6.1.0-blue.svg)](https://github.com/me0wg4ming/pfUI)
[![Version](https://img.shields.io/badge/version-6.1.1-blue.svg)](https://github.com/me0wg4ming/pfUI)
[![Turtle WoW](https://img.shields.io/badge/Turtle%20WoW-1.18.0-brightgreen.svg)](https://turtlecraft.gg/)
[![SuperWoW](https://img.shields.io/badge/SuperWoW-Enhanced-purple.svg)](https://github.com/balakethelock/SuperWoW)
[![Nampower](https://img.shields.io/badge/Nampower-Optional-yellow.svg)](https://gitea.com/avitasia/nampower)
@@ -14,11 +14,24 @@ This version includes significant performance improvements, DLL-enhanced feature
---
## What's New in Version 6.1.1 (January 8, 2026)
### 🐛 Bugfixes
- ✅ **Chat Level Display Fix** - Fixed targeting high-level players overwriting known level with -1. Now shows "??" for unknown levels instead of -1
- ✅ **Nameplate Level Fix** - Nameplates now use stored level from database after reload instead of showing "??"
- ✅ **Nameplate Level Color** - Level color now correctly uses difficulty color when loaded from database
### ⚙️ Config Changes
- ✅ **Chat Player Levels** - Now disabled by default (was enabled)
---
## What's New in Version 6.1.0 (January 8, 2026)
### 🐛 Bugfixes
- ✅ **Performance improvement for visible Nameplates**
- ✅ **40-Yard Range Check Fix** - Fixed range check not working for raid/party frames due to throttle variable conflict (`this.tick` vs `this.throttleTick`)
- ✅ **Aggro Indicator Fix** - Fixed aggro indicator not displaying properly on raid/party frames (same throttle issue)
- ✅ **Aggro Detection Cache** - Improved aggro cache to only cache positive results, allowing instant detection when aggro changes while maintaining performance
@@ -159,7 +172,7 @@ Turtle WoW includes TBC spells in the Vanilla client. This version includes all
---
**Version:** 6.1.0
**Version:** 6.1.1
**Release Date:** January 8, 2026
**Compatibility:** Turtle WoW 1.18.0
**Optional DLLs:** SuperWoW, Nampower, UnitXP_SP3 (enhanced features when available)
+1 -1
View File
@@ -730,7 +730,7 @@ function pfUI:LoadConfig()
pfUI:UpdateConfig("chat", "text", "detecturl", "1")
pfUI:UpdateConfig("chat", "text", "classcolor", "1")
pfUI:UpdateConfig("chat", "text", "whosearchunknown", "0")
pfUI:UpdateConfig("chat", "text", "playerlevel", "1")
pfUI:UpdateConfig("chat", "text", "playerlevel", "0")
pfUI:UpdateConfig("chat", "left", "width", "380")
pfUI:UpdateConfig("chat", "left", "height", "180")
pfUI:UpdateConfig("chat", "right", "enable", "0")
+4
View File
@@ -131,6 +131,8 @@ libunitscan:SetScript("OnEvent", function()
if UnitIsPlayer(scan) then
_, class = UnitClass(scan)
level = UnitLevel(scan)
-- UnitLevel returns -1 for unknown levels, don't overwrite known values
level = level > 0 and level or nil
name = UnitName(scan)
guild = GetGuildInfo(scan)
AddData("players", name, class, level, nil, guild)
@@ -138,6 +140,8 @@ libunitscan:SetScript("OnEvent", function()
_, class = UnitClass(scan)
elite = UnitClassification(scan)
level = UnitLevel(scan)
-- UnitLevel returns -1 for unknown levels, don't overwrite known values
level = level > 0 and level or nil
name = UnitName(scan)
AddData("mobs", name, class, level, elite)
end
+5 -1
View File
@@ -797,11 +797,15 @@ pfUI:RegisterModule("chat", "vanilla:tbc", function ()
local real, _ = strsplit(":", name)
local level = GetPlayerLevel(real)
if level then
if level and level > 0 then
local levelcolor = rgbhex(GetDifficultyColor(level))
-- Add level after the player name, before the closing bracket
text = string.gsub(text, "(|Hplayer:" .. name .. "|h.-|h|r)" .. right,
"%1 " .. levelcolor .. level .. "|r" .. right)
elseif level and level <= 0 then
-- Show ?? for unknown levels (e.g. -1 from UnitLevel)
text = string.gsub(text, "(|Hplayer:" .. name .. "|h.-|h|r)" .. right,
"%1 |cffff0000??|r" .. right)
end
end
end
+14
View File
@@ -664,6 +664,14 @@ pfUI:RegisterModule("nameplates", "vanilla", function ()
local name = plate.original.name:GetText()
local level = plate.original.level:IsShown() and plate.original.level:GetObjectType() == "FontString" and tonumber(plate.original.level:GetText()) or "??"
local class, ulevel, elite, player, guild = GetUnitData(name, true)
-- Use database level if available and valid (fixes ?? after reload)
local levelFromDB = false
if ulevel and ulevel > 0 then
level = ulevel
levelFromDB = true
end
local target = plate.istarget
local mouseover = UnitExists("mouseover") and plate.original.glow:IsShown() or nil
local unitstr = target and "target" or mouseover and "mouseover" or nil
@@ -787,6 +795,12 @@ pfUI:RegisterModule("nameplates", "vanilla", function ()
plate.name:SetText(GetNameString(name))
plate.level:SetText(string.format("%s%s", level, (elitestrings[elite] or "")))
-- Set level color from GetDifficultyColor when using DB level
if levelFromDB and type(level) == "number" then
local color = GetDifficultyColor(level)
plate.level:SetTextColor(color.r + 0.3, color.g + 0.3, color.b + 0.3, 1)
end
if guild and C.nameplates.showguildname == "1" then
plate.guild:SetText(guild)
+1 -1
View File
@@ -3,7 +3,7 @@
## Author: Shagu
## Notes: A complete user interface replacement.
## Notes-ruRU: Полная замена пользовательского интерфейса.
## Version: 6.1.0
## Version: 6.1.1
## SavedVariables: pfUI_profiles, pfUI_addon_profiles, pfUI_cache
## SavedVariablesPerCharacter: pfUI_config, pfUI_init, pfUI_playerDB
+1 -1
View File
@@ -3,7 +3,7 @@
## Author: Shagu
## Notes: A complete user interface replacement.
## Notes-ruRU: Полная замена пользовательского интерфейса.
## Version: 6.1.0
## Version: 6.1.1
## SavedVariables: pfUI_profiles, pfUI_addon_profiles, pfUI_cache
## SavedVariablesPerCharacter: pfUI_config, pfUI_init, pfUI_playerDB