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

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

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #8  
Old 02-16-2012, 04:22 AM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

If you are trying to delete items from the NPC when it dies during EVENT_DEATH or something like that directly on the NPC's perl script, you will need to be using $npc commands, not $corpse stuff. At that time, I don't think the $corpse entity exists yet for that NPC.

Under the NPC class, there is this quest object:
Code:
RemoveItem(item_id, quantity= 0, slot= 0)
Unfortunately, I don't see any quest object yet to find items or item slots on an NPC. One could certainly be created though easy enough I am sure. But, in the mean-time, if you know the item IDs that you want to delete, you could just do a for loop through each possible slot 0 to 25 or something and try to delete the item you want deleted. If you don't know what item ID that would be, it may get a little more complicated. You would just need to create an array of item IDs when someone hands items to the NPC then just run the for loop on each item ID in that array. Should work fine.

Removing it from the corpse itself would probably be easier, but you would need to do it from something like player.pl or something. Since you can't really use EVENT_LOOT for that (I don't think), you may just need to send a signal to another NPC when the main NPC is killed and then have a timer that waits a second (to allow the corpse to be created) then searches all corpses and removes those items at that time.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
 


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 12:45 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 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3