Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Q&A

Quests::Q&A This is the quest support section

Reply
 
Thread Tools Display Modes
  #1  
Old 10-15-2020, 10:22 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default Looking for a way to clear vendor temp inventory

Greetings!

I am Looking for a way to clear vendor temp inventory.

Apparently there is no actual quest commands available for that
other than: (which set, count, but don't clear)

quest::MerchantCountItem(uint32 npc_id, uint32 item_id)
quest::MerchantSetItem(uint32 npc_id, uint32 item_id, [uint32 quantity])

Thank You!
Reply With Quote
  #2  
Old 10-16-2020, 06:41 AM
Thalix's Avatar
Thalix
Sarnak
 
Join Date: Sep 2016
Posts: 91
Default

LUA NPC:ClearItemList() or Perl $npc->ClearItemList() does not work?
Reply With Quote
  #3  
Old 10-16-2020, 07:32 AM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

Quote:
Originally Posted by Thalix View Post
LUA NPC:ClearItemList() or Perl $npc->ClearItemList() does not work?
Sadly no. KinglyKrab explains that they are for clearing of loot of npc.
Reply With Quote
  #4  
Old 10-16-2020, 08:37 PM
blackdragonsdg
Dragon
 
Join Date: Dec 2008
Location: Tennessee
Posts: 654
Default

If all else fails you can use a perl script to run sql against your db clearing the merchant temp list then reload npc data to make it update. It may also be possible with lua but I have never tried anything along those lines in lua. It is probably best to do what your wanting within the confines of the quest system but if that doesn't work out then this can be another option.
Reply With Quote
  #5  
Old 10-16-2020, 09:34 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

I figured out a solution - by using a combination of MerchantCountItem and MerchantSetItem I managed to enforce a list clear by doing a loop on range of items. Its cumbersome but it works for now =)

My next goal is - NPC run Auction house =) I know some server implemented that few years back, so if anyone aware of any free code - I would much appreciate that =)
Otherwise I will have to code it from ground up =)
Reply With Quote
  #6  
Old 10-16-2020, 09:36 PM
demonstar55
Demi-God
 
Join Date: Apr 2008
Location: MA
Posts: 1,164
Default

Quote:
Originally Posted by Thalix View Post
LUA NPC:ClearItemList() or Perl $npc->ClearItemList() does not work?
Those are loot functions it looks like (if anyone was wondering why they didn't work)
Reply With Quote
  #7  
Old 10-16-2020, 09:53 PM
ChaosSlayerZ's Avatar
ChaosSlayerZ
Demi-God
 
Join Date: Mar 2009
Location: Umm
Posts: 1,492
Default

Ok i think i have one question left. I been working with pre-defined list of items. What if I want to look over entire vendor inventory (I don't know what he has there) and ask him to list all items he got on him?
Reply With Quote
Reply


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

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

Forum Jump

   

All times are GMT -4. The time now is 07:35 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3