DarkflameServer/dDatabase/CDClientDatabase/CDClientManager.h
David Markowitz dc29f5962d
Move CDClientManager to be a namespace (#1431)
Tested that worlds still load data as expected.  Had no use being a singleton anyways.
2024-02-08 23:40:43 -06:00

27 lines
451 B
C++

#pragma once
#include "CDTable.h"
#include "Singleton.h"
#define UNUSED_TABLE(v)
/**
* Initialize the CDClient tables so they are all loaded into memory.
*/
namespace CDClientManager {
void LoadValuesFromDatabase();
void LoadValuesFromDefaults();
/**
* Fetch a table from CDClient
*
* @tparam Table type to fetch
* @return A pointer to the requested table.
*/
template<typename T>
T* GetTable() {
return &T::Instance();
}
};