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
  #3  
Old 03-11-2008, 05:57 PM
AndMetal
Developer
 
Join Date: Mar 2007
Location: Ohio
Posts: 648
Default

I think this all has to do with how the items are read.

If I'm not mistaken (one would have to look through the source to confirm), the server finds out what the Item IDs are for each slot & stores them as $item1, $item2, $item3, & $item4. Then, an array (table) is created from that info: %itemcount. I assume the logic is something like this:

Code:
%itemcount{$item1}++;
%itemcount{$item2}++;
%itemcount{$item3}++;
%itemcount{$item4}++;
That way, if you hand in 2 of the items, it increments the key, which is the Item ID, by 1.

I agree, the "better" way to do this is to do something like this:

Code:
%itemcount{%item1{id}} += %itemcount{%item1{stacksize}};
%itemcount{%item2{id}} += %itemcount{%item2{stacksize}};
%itemcount{%item3{id}} += %itemcount{%item3{stacksize}};
%itemcount{%item4{id}} += %itemcount{%item4{stacksize}};
That way, you can stack items AND have them ALL count for the quest.

However, the issue then becomes backwards compatibility. I would think the best way to handle that would be to keep $item1-4 as is, and change just %itemcount to handle the new logic.

Anyone up for digging through the source code?
__________________
GM-Impossible of 'A work in progress'
A non-legit PEQ DB server
How to create your own non-legit server

My Contributions to the Wiki
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 09:34 AM.


 

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