Commit Graph

12 Commits

Author SHA1 Message Date
David Markowitz
7671cc6865
CDClient cleanup and optimization (#1023)
* CDClient cleanup and optimization

- Use static function to get table name
- Remove unused GetName function
- Replace above function with a static GetTableName function
- Remove verbose comments
- Remove verbose initializers
- Remove need to specify table name when getting a table by name
- Remove unused typedef for mac and linux

* Re-add unused table

Convert tables to singletons

- Convert all CDClient tables to singletons
- Move Singleton.h to dCommon
- Reduce header clutter in CDClientManager
2023-03-17 07:36:21 -07:00
David Markowitz
8920cd1063
Use field names instead of numbers for CDClient tables (#945) 2023-01-07 01:48:59 -08:00
David Markowitz
bd28e4051f
Fix Hash Collisions in CDBehaviorParameter table (#930)
* Fix hashing

* Update CDBehaviorParameterTable.cpp
2022-12-29 03:43:52 -06:00
aronwk-aaron
19e77a38d8 format codebase 2022-07-28 08:39:57 -05:00
David Markowitz
b7497a47e4
Lower memory usage of Behavior Parameter Table by 10MB (#627)
* 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

* Reduce memory usage

Reduces the memory usage for the BehaviorParameter table by 10MB in memory.

* Update CDBehaviorTemplateTable.cpp
2022-07-11 20:43:09 -07:00
David Markowitz
485de6173a
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
2022-07-08 23:07:52 -07:00
TheMatt2
59afc63a2f Merge DarkflameServer 2022-01-30 13:40:08 -05:00
Avery
f6558aa31e
implement jetpack behavior and remove hardcoded jetpacks (#411) 2022-01-24 14:02:56 -08:00
TheMatt2
4ff84e0730 Fix whitespace 2022-01-15 13:37:43 -05:00
TheMatt2
3de3932503 Comply with Xiphoseer required changes.
Remove the CDClientDatabase::ExecuteQueryWithArgs() function and replace 
it with CDClientDatabase::CreatePreppedStmt().

This prevents a developer from accidently using %s, or incorrectly 
passing std::string, and causing a silent error.
2022-01-12 22:48:27 -05:00
TheMatt2
4796b551ad Additional SQLite lookup sanitizing with CDClientDatabase::ExecuteQueryWithArgs() 2022-01-06 16:05:03 -05:00
Unknown
0545adfac3 Public release of the DLU server code!
Have fun!
2021-12-05 18:54:36 +01:00