From 1eb13ec5a357c43c5366c276dce87fba6f713fc6 Mon Sep 17 00:00:00 2001 From: Bardur Arantsson Date: Tue, 13 Jun 2017 18:24:42 +0200 Subject: Move alloc_* tables to Game struct We also change the arrays to std::vector<> --- src/alloc.hpp | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 src/alloc.hpp (limited to 'src/alloc.hpp') diff --git a/src/alloc.hpp b/src/alloc.hpp new file mode 100644 index 00000000..1d4ce815 --- /dev/null +++ b/src/alloc.hpp @@ -0,0 +1,29 @@ +#pragma once + +#include "h-basic.h" +#include "alloc_entry.hpp" + +#include + +/** + * Allocations of object kinds and monster races. + */ +struct Alloc { + + /* + * The entries in the "kind allocator table" + */ + std::vector kind_table; + + /* + * The flag to tell if kind_table contains valid entries + * for normal (i.e. kind_is_legal) object allocation + */ + bool kind_table_valid = false; + + /* + * The entries in the "race allocator table" + */ + std::vector race_table; + +}; -- cgit v1.2.3