1. #1
    Deleted

    Changing "PartyMemberFrame" to "CompactPartyFrameMember"

    Hello. I'm trying to fix an addon that displays my teammates pvp-trinkets next to their frames in my party, it's working for the old PartyMemberFrame but I'm trying to get it to work for the Raid-Style Party Frames. Here's the code:

    Code:
    local trinkets = {}
    local events = CreateFrame("Frame")             
    local partyFrame, trinket
            for i = 1, MAX_PARTY_MEMBERS do
                    partyFrame = "PartyMemberFrame"..i
                    trinket = CreateFrame("Cooldown", partyFrame.."Trinket")
                    trinket:SetPoint("TOPRIGHT", partyFrame, 30, -6)
                    trinket:SetSize(24, 24)
                    trinket.icon = trinket:CreateTexture(nil, "BACKGROUND")
                    trinket.icon:SetAllPoints()
                    trinket.icon:SetTexture("Interface\\Icons\\inv_jewelry_trinketpvp_02")
                    trinket:Hide()
                    trinkets["party"..i] = trinket
            end 
    function events:UNIT_SPELLCAST_SUCCEEDED(unitID, spell, rank, lineID, spellID)
            if not trinkets[unitID] then
                    return
            end
            if spellID == 59752 or spellID == 42292 then
                    CooldownFrame_SetTimer(trinkets[unitID], GetTime(), 120, 1)             
            elseif spellID == 7744 then
                    CooldownFrame_SetTimer(trinkets[unitID], GetTime(), 45, 1)              
            end
    end
    function events:PLAYER_ENTERING_WORLD()         
                             self:RegisterEvent("UNIT_SPELLCAST_SUCCEEDED")                           
                             for _, trinket in pairs(trinkets) do
                               trinket:SetCooldown(0, 0)
                               trinket:Hide()
                             end 
    end
    events:SetScript("OnEvent", function(self, event, ...) return self[event](self, ...) end)
    events:RegisterEvent("PLAYER_ENTERING_WORLD")
    So I've tried changing the PartyMemberFrame to CompactPartyFrameMember without any success, I've looked at other addons that edits the blizzard raid frames to try get a clue on how to do it but I can't get it to work. Does anyone here know how I do to attach the trinkets to the right party member in the raid frames?

    Would appreciate it a lot if someone could teach me how to do it!
    Last edited by mmoc9c50efb943; 2013-03-26 at 09:35 AM.

  2. #2
    Deleted
    Anyone who can help with this? I would like to have the addon as well.

  3. #3
    Try /fstack. I am not sure but raid style party frsmes call compactraidmember%d

  4. #4
    Deleted
    Aleaa I've tried that. And it's what I'm saying in the topic that it does not work. You have to do something else I guess. :/

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •