2
0
mirror of https://github.com/Laupetin/OpenAssetTools.git synced 2026-01-23 00:31:48 +00:00

chore: use CommonTechset instead of TechsetDefinition

This commit is contained in:
Jan Laupetin
2026-01-19 22:13:12 +00:00
parent 2a034d512e
commit d714afbcdd
40 changed files with 306 additions and 301 deletions

View File

@@ -0,0 +1,21 @@
#pragma once
#include "Asset/IZoneAssetCreationState.h"
#include "Techset/CommonTechset.h"
#include <memory>
#include <string>
#include <unordered_map>
namespace techset
{
class CommonTechsetCache final : public IZoneAssetCreationState
{
public:
[[nodiscard]] CommonTechset* GetCachedTechsetDefinition(const std::string& techsetName) const;
void AddCommonTechsetToCache(std::string name, std::unique_ptr<CommonTechset> definition);
private:
std::unordered_map<std::string, std::unique_ptr<CommonTechset>> m_cache;
};
} // namespace techset