EC: New logic for pet training progress gump

As noted at this link, the pet training progress gump can get in the way.  if you want to simply prevent the gump from showing, just follow what's posted in that link.

The below change to GumpsParsing.lua, GumpsParsing.ShowHide
will only show the pet training progress gump if any pet is below 100% training status.

Insert new block of code under the italics+bold line.

	for gumpID, value in pairs(GumpData.Gumps) do

if (gumpID == 999139) then -- avoid displaying pet training progress gump when all pets at 100%

local completedcount = 0
local labelcount = 0

for label, data in pairs(GumpData.Gumps[999139].Labels) do
-- data.tid == 1114513 -- header (one per training progress gump), ReplaceTokens(GetStringFromTid(data.tid), data.tidParms)
-- data.text -- array, name of pet and completion%

if( data.tid == 1153582 ) then -- completed, one per pet @ 100%
completedcount = completedcount + 1

labelcount = labelcount + 1

local completedlabelcount = completedcount * 3 -- expect 3 label instances for each completed pet

if( completedlabelcount ~= 0 and completedlabelcount == (labelcount-1) ) then -- labelcount-1, do not include header label.
continue -- skip showing the gump

Sign In or Register to comment.