Performance improvement for collecting scripts, by reserving size in ScriptSource.
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2020-04-25 11:33:25 +02:00
parent 3b1c0e84e1
commit 734d056449
14 changed files with 26 additions and 0 deletions

View File

@@ -80,6 +80,7 @@ namespace CreatureLib::Battling {
Creature* GetUser() noexcept { return _user; }
LearnedAttack* GetAttack() noexcept { return _attack; }
size_t ScriptCount() const override { return _user->ScriptCount() + 1; }
protected:
void GetActiveScripts(Arbutils::Collections::List<ScriptWrapper>& scripts) override {