View Single Post
02/10/15, 04:12 PM   #46
circonian
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 613
Originally Posted by Garkin View Post
Is there easy way to tell if you are interacting with fence or with regular merchant? Intraction type for both is INTREACTION_VENDOR.
I didn't see any API like IsAtFence()
There is a FENCE_SCENE though, you could check the current scene.

I also saw these which you might find useful, they are all from the FENCE_MANAGER

Lua Code:
  1. EVENT_MANAGER:RegisterForEvent("ZO_Fence_Manager", EVENT_OPEN_FENCE, function(eventCode) self:OnFenceOpened() end)
  2. EVENT_MANAGER:RegisterForEvent("ZO_Fence_Manager", EVENT_CLOSE_STORE, function(eventCode) self:OnFenceClosed() end)
  3.  
  4. self:FireCallbacks("FenceOpened", self.sellsUsed, self.laundersUsed)
  5. self:FireCallbacks("FenceClosed")
  6. self:FireCallbacks("FenceSellSuccess")
  7. self:FireCallbacks("FenceLaunderSuccess")
  8. self:FireCallbacks("FenceUpdated", self.totalSells, sellsUsed, self.totalLaunders, laundersUsed)
  9. self:FireCallbacks("FenceEnterSell", self.totalSells, self.sellsUsed)
  10. self:FireCallbacks("FenceEnterLaunder", self.totalLaunders, self.laundersUsed)
  11. self:FireCallbacks("FenceInventoryUpdated")
  Reply With Quote