Implemented Animation Clip asset and animation controller #410

Merged
XiaoQiDigipen merged 66 commits from SP3-22-AnimationController into main 2023-03-09 16:19:40 +08:00
2 changed files with 2 additions and 1 deletions
Showing only changes of commit ab2f3e395b - Show all commits

View File

@ -87,6 +87,7 @@ namespace SHADE
animClip->name = newAssetName;
animClip->firstIndex = firstIndex;
animClip->lastIndex = lastIndex;
animClip->animRawDataAssetId = SHResourceManager::GetAssetID<SHRawAnimation>(rawAnimation).value_or(0);
SHAssetManager::SaveAsset(containerAsset->id);
// Close

View File

@ -370,7 +370,7 @@ namespace SHADE
loadedAssetData.emplace_back(assetId);
return resourceHub.Create<ResourceType>
(
LoadOrGet<SHRawAnimation>(assetId), // TODO: Wrong, we need to grab the parent asset's ID
LoadOrGet<SHRawAnimation>(assetData.animRawDataAssetId),
assetData.firstIndex,
assetData.lastIndex
);