Quantcast How can I access the UI frames of group members? - WoWInterface
Thread Tools Display Modes
04-16-20, 06:32 PM   #1
Helveg
A Defias Bandit
Join Date: Apr 2020
Posts: 2
How can I access the UI frames of group members?

Hi! I tried googling the answer but it seems to be quite difficult to find anything unless you know the exact name of the API or UIObject that you're looking for.

I'd like to add a little button next to each party member's avatar similar to how it's done for minimap buttons. How can I, from LUA, access their frames? I know that for myself I could use the global "PlayerFrame", is there an analog for group members?
  Reply With Quote
04-16-20, 08:03 PM   #2
Fizzlemizz
I did that?
 
Fizzlemizz's Avatar
Premium Member
AddOn Author - Click to view addons
Join Date: Dec 2011
Posts: 1,214
Assuming you're using the default unit frames:

PartyMemberFrame1
PartyMemberFrame2
PartyMemberFrame3
PartyMemberFrame4

or

Code:
for i=1, 4 do
    local frame = _G["PartyMemberFrame"..i]
--  do whatever for the current frame.
end
Typing /fstack and hovering the mouse over a frame will give you what details of the frame are available(/fstack to close again)

You can also extract the code for the Blizzard UI.
__________________
Fizzlemizz
Maintainer of Discord Unit Frames and Discord Art.
Author of FauxMazzle, FauxMazzleHUD and Move Pad Plus.

Last edited by Fizzlemizz : 04-16-20 at 08:07 PM.
  Reply With Quote
04-17-20, 10:17 AM   #3
Helveg
A Defias Bandit
Join Date: Apr 2020
Posts: 2
Thank you so much! Invaluable information ^_^

Does this community also use StackOverflow?
  Reply With Quote
04-17-20, 11:51 AM   #4
Seerah
Fishing Trainer
 
Seerah's Avatar
WoWInterface Super Mod
Featured
Join Date: Oct 2006
Posts: 10,727
You might be able to find some generic Lua snippets on Stack Overflow. But most any code will be posted here on the forums or linked to someone's pastebin.
__________________
"You'd be surprised how many people violate this simple principle every day of their lives and try to fit square pegs into round holes, ignoring the clear reality that Things Are As They Are." -Benjamin Hoff, The Tao of Pooh

  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » How can I access the UI frames of group members?

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off