Wykkyd's Avatar
Files 0
Downloads 0
Favorites 0
My AddOns
    View Bug Report
    Soul Gems
    Bug #: 998
    File: Wykkyd Framework Suite
    Date: 08/05/14 05:10 AM
    By: Garkin
    Status: Fixed
    "mhFramework\Lib\Bazgrim\Toolbar\SoulGems.lua":

    Missing space on line 4, correct is:
    Lua Code:
    1. local retVal, c = "", {215/255,213/255,205/255,1}

    When you enter Cyrodiil, your level is adjusted to 50 and you have to use Grand Soul Gems, however bar shows low level soul gems. You can change it on the line 6:
    Lua Code:
    1. local myLevel, GEM_TYPE = GetUnitEffectiveLevel("player"), SOUL_GEM_PETTY

    And by the way, I'm not sure why you use global constants such as SOUL_GEM_GRAND when you can use actual player level. This is modified SoulGems.lua which I currently use:

    Lua Code:
    1. WF_BazgrimToolbar.GetSoulGems = function()
    2.     local style = WF_GetOrDefault( "Empty / Full", WF_SavedVars.BazgrimToolbar["Tools"][WF_TOOLBAR_TOOL_GEMS])
    3.     local useIcon = WF_GetOrDefault( true, WF_SavedVars.BazgrimToolbar["ToolOptions"]["gems_icon"] )
    4.     local retVal, c = "", {215/255,213/255,205/255,1}
    5.     local name, icon, icon2, stackCount = "", "", "", 0
    6.     local myLevel, GEM_TYPE = GetUnitEffectiveLevel("player"), SOUL_GEM_PETTY
    7.     local emptyCount, fullCount = 0, 0
    8.     name, icon, stackCount = GetSoulGemInfo(SOUL_GEM_TYPE_EMPTY, myLevel, true); emptyCount = stackCount;
    9.     name, icon2, stackCount = GetSoulGemInfo(SOUL_GEM_TYPE_FILLED, myLevel, true); fullCount = stackCount;
    10.     if style == "Empty / Full" then retVal = emptyCount .. " / ".. "|c00FF00"..fullCount.."|r"
    11.     elseif style == "Empty" then retVal = emptyCount
    12.     elseif style == "Full" then retVal = "|c00FF00"..fullCount.."|r" end
    13.     if (icon2 ~= "" and icon2 ~= nil) and icon2 ~= "/esoui/art/icons/icon_missing.dds" then icon = icon2 end
    14.     if useIcon then
    15.         local o = bazgrimToolbar.Tools[WF_TOOLBAR_TOOL_GEMS].Control
    16.         if o.Icon == nil then o.Icon = WF_BazgrimToolbar.MakeSpacerControl( o ); end
    17.         o.Icon:SetTexture( icon )
    18.         o.IconSize = 16
    19.         o.BufferSize = 24
    20.         if not o.UseIcon then
    21.             o.Icon:SetDimensions( o.IconSize, o.IconSize )
    22.             o.Icon:ClearAnchors()
    23.             o.Icon:SetAnchor( RIGHT, o, LEFT, -8, 0 )
    24.             o.Icon:SetHidden(false)
    25.             local aBool, aPoint, aTarget, aTargetPoint, aX, aY = o:GetAnchor()
    26.             o.PreviousAnchor = {aPoint, aTarget, aTargetPoint, aX, aY}
    27.             o:ClearAnchors()
    28.             o:SetAnchor( aPoint, aTarget, aTargetPoint, aX + o.BufferSize + 4, aY )
    29.         end
    30.         o.UseIcon = true
    31.     else
    32.         local o = bazgrimToolbar.Tools[WF_TOOLBAR_TOOL_GEMS].Control
    33.         if o.UseIcon == true then
    34.             o.Icon:SetDimensions( o.IconSize, o.IconSize )
    35.             o.Icon:ClearAnchors()
    36.             o.Icon:SetAnchor( RIGHT, o, LEFT, -4, 0 )
    37.             o.Icon:SetHidden(true)
    38.             if o.PreviousAnchor ~= nil then
    39.                 o:ClearAnchors()
    40.                 o:SetAnchor( o.PreviousAnchor[1], o.PreviousAnchor[2], o.PreviousAnchor[3], o.PreviousAnchor[4], o.PreviousAnchor[5] )
    41.             end
    42.             o.PreviousAnchor = nil
    43.         end
    44.         o.UseIcon = false
    45.     end
    46.     return retVal, c
    47. end

    and I have commented out global variables for soul gems in Globals.lua.

    RSS 2.0 Feed for Bug CommentsNotes Sort Options
    By: Garkin - 08/05/14 05:13 AM
    Ah, line 6 in modified SoulGems.lua should be just:
    lua Code:
    1. local myLevel = GetUnitEffectiveLevel("player")
    I forgot to remove GEM_TYPE variable when I do not use it anymore.
    By: Wykkyd - 08/05/14 06:48 AM
    Thanks for the help, man. As soon as I vet the change it'll be in the next version update.