Added caching for behavior parameter table (#621)

* Added caching for table

Added caching for table

Add more caching

Update MasterServer.cpp

grds

Update CDBehaviorParameterTable.cpp

Update CDBehaviorParameterTable.h

Update CDBehaviorTemplateTable.cpp

Update Behavior.cpp

Update Behavior.cpp

change to map

Remove redundant query

* Remove include

* change to enum

* Update Behavior.cpp

* Use already cached table

* Update Behavior.cpp
This commit is contained in:
David Markowitz
2022-07-08 23:07:52 -07:00
committed by GitHub
parent dddc33607b
commit 485de6173a
7 changed files with 93 additions and 126 deletions

View File

@@ -19,7 +19,7 @@ public:
/*
* Static
*/
static std::map<uint32_t, Behavior*> Cache;
static std::unordered_map<uint32_t, Behavior*> Cache;
static CDBehaviorParameterTable* BehaviorParameterTable;
static Behavior* GetBehavior(uint32_t behaviorId);