Aviana / LunaUnitFrames

Unit Frames for WoW Classic
245 stars 102 forks source link

XP bar is not visible as Deathknight #935

Closed stan1226 closed 2 years ago

stan1226 commented 2 years ago

The XP bar is not visible when playing a Deathknight even though it's set to on. Works fine for all other classes. Activating and Deactivating Runes or Ghoul bar doesn't help.

stan1226 commented 2 years ago

Ok I actually found the error, it's in libs\oUF_Plugins\oUF_XPBar\oUF_XPBar.lua line 91: if( UnitLevel(unit) == MAX_PLAYER_LEVEL or (UnitIsUnit(unit, "pet") and UnitLevel(unit) == UnitLevel("player")) ) then element.xpBar:Hide()

My DK was level 60, it looks like somehow the value MAX_PLAYER_LEVEL is still set to 60, so it hides your xp bar if you are exactly level 60. If I replace MAX_PLAYER_LEVEL in the line to 80 the xp bar is visible again. I couldn't find where MAX_PLAYER_LEVEL is stored or coming wrong, but it's a wrong value for wotlk classic