Thread Tools Display Modes
07/11/14, 02:21 PM   #1
klaro00
 
klaro00's Avatar
Join Date: Apr 2014
Posts: 31
Looking for event name of vendor/merchant actions (bought or sold items)

Hi,

I'm looking for a specific event, can't find it... I want to get informed whenever I buy or sell something. There is an event for changes in my inventory/bag, and also an event for changes of my gold stack.

But is there an event which directly tells me how many items of what type I just bought or sold? Anyone can give me a clue?

Thanks,
Klaro

Last edited by klaro00 : 07/11/14 at 02:56 PM. Reason: typo
  Reply With Quote
07/11/14, 07:12 PM   #2
Harven
 
Harven's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 135
Hey,
I think you may be interested in events listed here: http://wiki.esoui.com/Events#Vendors and functions listed here: http://wiki.esoui.com/API#Store_.28Buy.2FSell.29
  Reply With Quote
07/12/14, 02:29 AM   #3
klaro00
 
klaro00's Avatar
Join Date: Apr 2014
Posts: 31
Hi,

thanks for the advice. I constantly examine the API documentation for addon development; in particular I think there is no special event for selling and buying (I hope I'm wrong...).

Well, I could infer selling/byuing activities by tracking changes in my gold stack and correalting it to changes in my inventory, which would be an indirect approach.

I'm missing the one event that tells me "you just sold x items of type y for z gold".

// Klaro
  Reply With Quote
07/12/14, 02:54 AM   #4
zgrssd
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 280
Currently there are a total of 469 EVENT_ constants in the global table (each of them containing the events ID). Finding the right one can be tricky
Have you looked at those:
EVENT_BUY_RECEIPT = 131234
EVENT_SELL_RECEIPT = 131235
EVENT_BUYBACK_RECEIPT = 131236
EVENT_UPDATE_BUYBACK = 131233

Some other constant with sell or buy in thier name:
SI_ITEM_ACTION_SELL = 1829
SI_PROMPT_TITLE_SELL_ITEMS = 3546
SI_SELL_RECEIPT_FREE = 2035
SI_SELL_RECEIPT_MONEY = 2034
SLOT_TYPE_BUY_MULTIPLE = 8
SLOT_TYPE_STORE_BUY = 6

I also think that the "Buyback" area is considered another Character bag, similar to the account bank and the worn items:
BAG_BACKPACK = 1
BAG_BANK = 2
BAG_BUYBACK = 4
BAG_DELETE = 255
BAG_GUILDBANK = 3
BAG_TRANSFER = 5
BAG_WORN = 0

Last edited by zgrssd : 07/12/14 at 03:00 AM.
  Reply With Quote
07/12/14, 03:03 AM   #5
klaro00
 
klaro00's Avatar
Join Date: Apr 2014
Posts: 31
Ooops... I had a wrong German translation in mind when seeing EVENT_BUY_RECEIPT and EVENT_SELL_RECEIPT. Very emberassing... At least I could have seen the event meaning by their event arguments... Sorry to bother you guys; these events are what I need.

// Klaro
  Reply With Quote

ESOUI » AddOns » AddOn Help/Support » Looking for event name of vendor actions (bought or sold items)


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