Go Back   EQEmulator Home > EQEmulator Forums > Archives > Archive::Development > Archive::Development

Archive::Development Archive area for Development's posts that were moved here after an inactivity period of 90 days.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 06-11-2003, 11:55 AM
krich
Hill Giant
 
Join Date: May 2003
Location: The Great Northwest
Posts: 150
Default Quests...Memory Hog?

I just realized just how much memory Quests take up...

They use about 465k (not counting the linked list overhead) per NPCType that has a quest file and if there is a "default" quest file, then it's 465k for EVERY NPCType! That would hurt my poor 128Mb server were I to put in all the quests published in the Quest forum.

The struct is as follows:


Quote:
struct Events {
int index;
int npcid;
char event[100][100];
int line[65535];
char command[100][2048];
};
One could save memory by converting the event and command definitions into linked lists themselves, as such:

Quote:
struct EventList {
char event[100]
char command[2048]
}

struct Events {
int npcid;
int line[65535]; //Anyone know what this is for?
MyList <EventList> MyEvents;
};
Or something like that... Thus reducing the memory footprint by only using memory when there is something to actually remember. The hard part is that this would require an overhaul of the quest code to use the new structs.

Comments, Ideas, Complaints?

Regards,

krich
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 02:30 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