mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-06-26 06:11:53 +00:00
chore: always build fastfile when there are assets defined
This commit is contained in:
@ -1,5 +1,13 @@
|
||||
#include "ZoneAssetPools.h"
|
||||
|
||||
#include "Game/IW3/GameAssetPoolIW3.h"
|
||||
#include "Game/IW4/GameAssetPoolIW4.h"
|
||||
#include "Game/IW5/GameAssetPoolIW5.h"
|
||||
#include "Game/T5/GameAssetPoolT5.h"
|
||||
#include "Game/T6/GameAssetPoolT6.h"
|
||||
#include "Game/T6/ZoneConstantsT6.h"
|
||||
|
||||
#include <cassert>
|
||||
#include <format>
|
||||
|
||||
ZoneAssetPools::ZoneAssetPools(Zone* zone)
|
||||
@ -52,3 +60,23 @@ ZoneAssetPools::iterator ZoneAssetPools::end() const
|
||||
{
|
||||
return m_assets_in_order.end();
|
||||
}
|
||||
|
||||
std::unique_ptr<ZoneAssetPools> ZoneAssetPools::CreateForGame(const GameId game, Zone* zone, const zone_priority_t priority)
|
||||
{
|
||||
switch (game)
|
||||
{
|
||||
case GameId::IW3:
|
||||
return std::make_unique<GameAssetPoolIW3>(zone, priority);
|
||||
case GameId::IW4:
|
||||
return std::make_unique<GameAssetPoolIW4>(zone, priority);
|
||||
case GameId::IW5:
|
||||
return std::make_unique<GameAssetPoolIW5>(zone, priority);
|
||||
case GameId::T5:
|
||||
return std::make_unique<GameAssetPoolT5>(zone, priority);
|
||||
case GameId::T6:
|
||||
return std::make_unique<GameAssetPoolT6>(zone, priority);
|
||||
default:
|
||||
assert(false);
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
|
@ -52,4 +52,6 @@ public:
|
||||
|
||||
_NODISCARD iterator begin() const;
|
||||
_NODISCARD iterator end() const;
|
||||
|
||||
static std::unique_ptr<ZoneAssetPools> CreateForGame(GameId game, Zone* zone, zone_priority_t priority);
|
||||
};
|
||||
|
Reference in New Issue
Block a user