Advertisement
Guest User

Untitled

a guest
Aug 13th, 2016
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. local ItemId = 10541 -- Item needs to have spell on use
  2. local MenuId = 124 -- Unique ID to recognize player gossip menu among others
  3.  
  4. local function OnGossipHello(event, player, object)
  5. player:GossipClearMenu()
  6. player:GossipMenuAddItem(0, "Open Vendor", 1, 1)
  7. player:GossipSendMenu(1, object, MenuId) -- MenuId required for player gossip
  8. end
  9.  
  10. local function OnGossipSelect(event, player, object, sender, intid, code, menuid)
  11. if (intid == 1) then
  12. player:SetCurrentVendor(90000)
  13. end
  14. end
  15.  
  16. RegisterItemGossipEvent(10541, 1, OnGossipHello)
  17. RegisterItemGossipEvent(10541, 2, OnGossipSelect)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement