2
0
mirror of https://github.com/Laupetin/OpenAssetTools.git synced 2026-02-10 17:43:03 +00:00

refactor: introduce subasset loading

This commit is contained in:
Jan Laupetin
2026-02-05 16:25:00 +00:00
parent 1be411b371
commit aa47ffa629
255 changed files with 1668 additions and 3132 deletions

View File

@@ -9,7 +9,7 @@ In this case:
(actual asset, not a reference) techniqueset `trivial_floatz_2992w610`
*/
#include "Game/T6/GameAssetPoolT6.h"
#include "Game/T6/T6.h"
#include "Linker.h"
#include "OatTestPaths.h"
#include "SystemTestsPaths.h"
@@ -100,15 +100,14 @@ namespace
REQUIRE(maybeZone);
auto zone = std::move(*maybeZone);
auto pools = dynamic_cast<GameAssetPoolT6*>(zone->m_pools.get());
REQUIRE(zone->m_game_id == GameId::T6);
REQUIRE(zone->m_platform == GamePlatform::PC);
REQUIRE(zone->m_name == "CombinedZoneT6");
REQUIRE(pools->GetTotalAssetCount() == 2);
REQUIRE(pools->m_technique_set->GetAsset("trivial_floatz_2992w610"));
REQUIRE(zone->m_pools.GetTotalAssetCount() == 2);
REQUIRE(zone->m_pools.GetAsset<T6::AssetTechniqueSet>("trivial_floatz_2992w610"));
const auto* material = pools->m_material->GetAsset("test");
const auto* material = zone->m_pools.GetAsset<T6::AssetMaterial>("test");
REQUIRE(material);
REQUIRE(material->Asset()->techniqueSet);
REQUIRE(material->Asset()->techniqueSet->name == "trivial_floatz_2992w610"s);