mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-10 10:50:24 +00:00
NPC Faction lists to new shared memory scheme
This commit is contained in:
@@ -28,8 +28,9 @@ void LoadItems(SharedDatabase *database) {
|
||||
EQEmu::IPCMutex mutex("items");
|
||||
mutex.Lock();
|
||||
|
||||
int32 items = -1;
|
||||
uint32 max_item = 0;
|
||||
int32 items = database->GetItemsCount(&max_item);
|
||||
database->GetItemsCount(items, max_item);
|
||||
if(items == -1) {
|
||||
EQ_EXCEPT("Shared Memory", "Unable to get any items from the database.");
|
||||
}
|
||||
@@ -39,8 +40,6 @@ void LoadItems(SharedDatabase *database) {
|
||||
mmf.ZeroFile();
|
||||
|
||||
void *ptr = mmf.Get();
|
||||
database->LoadItems(ptr, size, items, max_item);
|
||||
mmf.SetLoaded();
|
||||
|
||||
database->LoadItems(ptr, size, items, max_item);
|
||||
mutex.Unlock();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user