• 0

    posted a message on Recount
    I'm brand new to this addon and while I'm really digging it I've noticed one bug. I'm not sure whether the problem is isolated or if its a symptom of greater miscalculation problem.

    I have the "Merge Pets w/ Owners" setting checked and it looks like Recount is trying to provide the best of both worlds: the pets damage is rolled up into my own and I can also see how much damage the pet did. I kind of like this, but it does produce an error in terms of the reporting of percentage of total damage done. The pets damage is getting added into the total amount of damage done twice, once in my total and once for the pet.

    The easiest way to see this is to have your pet solo a mob. The pet and I were listed as having done the same amount of damage (I did 0 + pet damage) and that each had done 50% of the damage. Obviously if my pet killed the mob by itself it should have done 100% of the damage, not 50%.

    Here's a better example though of why this is a problem. I partied up with a friend and the three of us killed a mob and I looked at the data. I'm going to round the numbers here to make it easier, but basically he was listed as doing 3k damage, the pet as 1k and I was listed as 2k (1k by me, and 1k by the pet). So it took 5k damage to kill the mob and my friend did 3k of it - I would expect him to be listed as having done 60% of the damage, but instead he was shown as having done 50%. I was listed as having done 33.3% and the pet as 16.7%.

    I think two changes need to be made when pet data is merged with owners:
    1) Damage from a pet row should not be included in the total value used for calculating percentage.
    2) The percentage shown next to the pet should be their damage divided by the owners merged damage.

    That means in the above scenario, my friends would be reported as having done 60%, I would be credited with 40% and my pet would be reported as 50%. Sure, those numbers don't add up to 100% but its actually more useful for the situation where damage is being merged.

    EDIT 1: I've never written any lua before, but I thought I'd give it a go and I think I've got number 1 at least partially fixed. You need to change Total=Total+Value to if not Recount.db.char.MergePets or not v.Owner then Total=Total+Value end in GUI_Main.lua in the functions Recount:RefreshMainWindow (line 538) and Recount:ReportData (line 713).

    EDIT 2: Did it!! :) Left is without merging pet data, right is with.

    I totally hacked this in, not sure if its right or complete, but I think its a good start for Cryect and I hope he includes it.
    Recount:RefreshMainWindow from:
    local Value,PerSec
    ...
    Value,PerSec=Recount.MainWindow:GetData(v,1)
    if Value>0 then
      Total=Total+Value
      if type(lookup[k])=="table" then
        lookup[k][1]=k
        lookup[k][2]=Value
        lookup[k][3]=Recount.db.char.ClassColors[v.enClass]
        lookup[k][4]=v
        lookup[k][5]=PerSec
      else
        lookup[k]={k,Value,Recount.Colors:GetColor("Class",v.enClass),v,PerSec}
        table.insert(dispTable,lookup[k])
      end
    ...
    if v then
      local percent=100*v[2]/Total
    to:
    local Value,PerSec,OwnerTotal
    ...
    Value,PerSec=Recount.MainWindow:GetData(v,1)
    if Value>0 then
      OwnerTotal=0
      if Recount.db.char.MergePets and v.Owner then
        if data[v.Owner].Fights[Recount.CurDataSet] then
          OwnerTotal=Recount.MainWindow:GetData(data[v.Owner],1)
        end
      else
        Total=Total+Value
      end
    
      if type(lookup[k])=="table" then
        lookup[k][1]=k
        lookup[k][2]=Value
        lookup[k][3]=Recount.db.char.ClassColors[v.enClass]
        lookup[k][4]=v
        lookup[k][5]=PerSec
        lookup[k][6]=OwnerTotal
      else
        lookup[k]={k,Value,Recount.Colors:GetColor("Class",v.enClass),v,PerSec,OwnerTotal}
        table.insert(dispTable,lookup[k])
      end
    ...
    if v then
      local percent=100*v[2]
      if v[6]>0 then
        percent=percent/v[6]
      else				
        percent=percent/Total
      end


    Recount:ReportData from:
    local Value,PerSec
    ...
    if Value>0 then
      Total=Total+Value
    
      if type(lookup[k])=="table" then
        lookup[k][1]=k
        lookup[k][2]=Value
        lookup[k][5]=PerSec
      else
        lookup[k]={k,Value,Recount.Colors:GetColor("Class",v.enClass),v,PerSec}
        table.insert(reportTable,lookup[k])
      end
    end
    ...
    SendChatMessage(i..". "..reportTable[i][1].." "..reportTable[i][2].." ("..PerSec..(math.floor(1000*reportTable[i][2]/Total)/10).."%)",loc,nil,loc2)
    to:
    local Value,PerSec,OwnerTotal
    ...
    if Value>0 then
      OwnerTotal=0
      if Recount.db.char.MergePets and v.Owner then
        if data[v.Owner].Fights[Recount.CurDataSet] then
          OwnerTotal=dataMode[2](this,data[v.Owner],1)
        end
      else
        Total=Total+Value
      end
    
      if type(lookup[k])=="table" then
        lookup[k][1]=k
        lookup[k][2]=Value
        lookup[k][5]=PerSec
        lookup[k][6]=OwnerTotal
      else
        lookup[k]={k,Value,Recount.Colors:GetColor("Class",v.enClass),v,PerSec,OwnerTotal}
        table.insert(reportTable,lookup[k])
      end
    end
    ...
    if reportTable[i][6]>0 then
      SendChatMessage(i..". "..reportTable[i][1].." "..reportTable[i][2].." ("..PerSec..(math.floor(1000*reportTable[i][2]/reportTable[i][6])/10).."%)",loc,nil,loc2)
    else
      SendChatMessage(i..". "..reportTable[i][1].." "..reportTable[i][2].." ("..PerSec..(math.floor(1000*reportTable[i][2]/Total)/10).."%)",loc,nil,loc2)
    end
    Posted in: General AddOns
  • 0

    posted a message on FuBar not spanning across top of screen
    Thanks Seerah; I did just need to drag it out.

    Right after patch, my layout was a bit messed up (with some stuff having disappeared right off the screen) and scaling the UI was the simplest way to get everything back in the right place. I don't remember if FuBar was fully spanned before that, but I had tried unchecking ScaleUI and it didn't seem to change anything. Anyways, stupid me had just assumed top docked bar would span and didn't even think to drag.
    Posted in: FuBar AddOns
  • 0

    posted a message on Errors with UnitFrame Addons?
    Cool! Thanks for figuring out how to fix this. MonkeyQuest needed the same basic fix too:

    MonkeyQuestTooltip.lua, line 45, from:
    -- this function catches the bag mouse over tooltip event
    function MonkeyQuest_NEW_ContainerFrameItemButton_OnEnter()
      -- call the old (probably blizzard's) GameTooltip_OnEvent()
      MonkeyQuest_OLD_ContainerFrameItemButton_OnEnter();
    to:
    -- this function catches the bag mouse over tooltip event
    function MonkeyQuest_NEW_ContainerFrameItemButton_OnEnter(frame)
      -- call the old (probably blizzard's) GameTooltip_OnEvent()
      MonkeyQuest_OLD_ContainerFrameItemButton_OnEnter(frame);
    Posted in: Unit Frames
  • 0

    posted a message on FuBar not spanning across top of screen
    I've updated for the new patch, but one problem I've seen is that FuBar is not spanning all the way across the screen. Its ending early on the right side, 3/4 or so of the full width. Is anyone else having this problem?
    Posted in: FuBar AddOns
  • 0

    posted a message on Prat 2.0 Chat Mod Framework (Official Thread)
    Is it possible to set up chat and combat log windows so that the newest messages appear at the top and older messages pushed further and further down?
    Posted in: General AddOns
  • 0

    posted a message on Bartender3 - Action Bar AddOn for WoW 2.0
    I'm new to this addon and don't really have time to scan the whole thread, so apologies if this has already been discussed ad nauseum.

    I'm curious as to why the addon does not auto hide any of the extra blizzard action bars that can be displayed by checking boxes in the Advanced Interface Options menu the way the regularly displayed action bar is hidden. I can of course uncheck them, but this has an undesireable consequence.

    When you display a Right or Bottom action bar it is removed from the pool of bars that can be cycled through via shift mousewheel, shift up arrow and shift down arrow. Bartender will also skip over any checked and visible bar when cycling through which is a good thing. Unfortuneately, we don't want those bars to be visiable and that seems to be the only way in which bartender will skip over a bar. Even if the bar is not enabled, you can cycle to it. If the bar is not enabled and empty, you'll just get an empty space where you used to have buttons until you get to the next bar.

    I don't want to have cycle through all 6 bars when I'm looking for the one I want. I like narrowing that down to a few bars that are meant to be mutually exclusive and which I switch to depending on context (i.e. one bar for weaker mobs and another for bosses).

    Bartender just needs to take care of hiding ALL the blizzard bars and then I'm set.

    Also - when I change my equipped weapon the icon for the Attack action is not updating the way it would on the blizz bars.
    Posted in: General AddOns
  • To post a comment, please or register a new account.