Smarter
Member
- Joined
- Jan 15, 2010
- Messages
- 763
- Reaction score
- 9
I am writing a Loot Info plugin as requested by a member, and have been going about methods of how to best go about this. Currently my idea is to hook LOOT_OPENED. Upon fire:
However, I see some flaws with this method. One being that this will record all available loot in the Loot window, not what the user actually picks up. I have yet to come up with a method to confirm that other than keeping a cached record of the In Bag Loot to compare with when LOOT_OPEN is called. Does anyone have an opinion or something that I have not seen in the API? Thank you.
Code:
//On Loot_Opened:
/* Get Styx.Logic.Inventory.Frames.LootFrame.LootFrame.LootItems -- (# of Items In Loot Window)
* Grab Info with Styx.Logic.Inventory.Frames.LootFrame.LootFrame.LootInfo(int)
* which returns >
* Styx.Logic.Inventory.Frames.LootFrame.LootSlotInfo
* - Name, Quantity, Rarity,
* Grab ItemID (Styx.Logic.Inventory.Frames.LootFrame.LootFrame.GetItemId(int)) for all not marked as Locked)
* Record Styx.Logic.Inventory.Frames.LootFrame.LootFrame.LootingObjectGuid -- Object GUID
*/
However, I see some flaws with this method. One being that this will record all available loot in the Loot window, not what the user actually picks up. I have yet to come up with a method to confirm that other than keeping a cached record of the In Bag Loot to compare with when LOOT_OPEN is called. Does anyone have an opinion or something that I have not seen in the API? Thank you.