DarkflameServer/dDatabase/Tables/CDLootTableTable.h

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

26 lines
708 B
C
Raw Permalink Normal View History

#pragma once
// Custom Classes
#include "CDTable.h"
struct CDLootTable {
unsigned int itemid; //!< The LOT of the item
unsigned int LootTableIndex; //!< The Loot Table Index
unsigned int id; //!< The ID
bool MissionDrop; //!< Whether or not this loot table is a mission drop
unsigned int sortPriority; //!< The sorting priority
};
2023-07-16 07:27:30 +00:00
namespace CDLootTableTable {
private:
std::vector<CDLootTable> entries;
2022-07-28 13:39:57 +00:00
public:
2023-07-16 07:27:30 +00:00
void LoadTableIntoMemory();
// Queries the table with a custom "where" clause
std::vector<CDLootTable> Query(std::function<bool(CDLootTable)> predicate);
2022-07-28 13:39:57 +00:00
const std::vector<CDLootTable>& GetEntries(void) const;
};