Implemented Animation Clip asset and animation controller #410
|
@ -246,7 +246,7 @@ namespace SHADE
|
||||||
bool Editor::renderFieldEditorInternal<AssetID, AnimationClipAsset>(const std::string& fieldName, interior_ptr<AnimationClipAsset> managedValPtr, EditorFieldFunc<uint32_t>, bool* isHovered, RangeAttribute^)
|
bool Editor::renderFieldEditorInternal<AssetID, AnimationClipAsset>(const std::string& fieldName, interior_ptr<AnimationClipAsset> managedValPtr, EditorFieldFunc<uint32_t>, bool* isHovered, RangeAttribute^)
|
||||||
{
|
{
|
||||||
uint32_t assetId = managedValPtr->NativeAssetID;
|
uint32_t assetId = managedValPtr->NativeAssetID;
|
||||||
if (SHEditorUI::InputAssetField(fieldName, assetId, AssetType::FONT, isHovered))
|
if (SHEditorUI::InputAssetField(fieldName, assetId, AssetType::ANIM_CLIP, isHovered))
|
||||||
{
|
{
|
||||||
*managedValPtr = AnimationClipAsset(assetId);
|
*managedValPtr = AnimationClipAsset(assetId);
|
||||||
return true;
|
return true;
|
||||||
|
@ -258,7 +258,7 @@ namespace SHADE
|
||||||
bool Editor::renderFieldEditorInternal<AssetID, AnimationControllerAsset>(const std::string& fieldName, interior_ptr<AnimationControllerAsset> managedValPtr, EditorFieldFunc<uint32_t>, bool* isHovered, RangeAttribute^)
|
bool Editor::renderFieldEditorInternal<AssetID, AnimationControllerAsset>(const std::string& fieldName, interior_ptr<AnimationControllerAsset> managedValPtr, EditorFieldFunc<uint32_t>, bool* isHovered, RangeAttribute^)
|
||||||
{
|
{
|
||||||
uint32_t assetId = managedValPtr->NativeAssetID;
|
uint32_t assetId = managedValPtr->NativeAssetID;
|
||||||
if (SHEditorUI::InputAssetField(fieldName, assetId, AssetType::MESH, isHovered))
|
if (SHEditorUI::InputAssetField(fieldName, assetId, AssetType::ANIM_CONTROLLER, isHovered))
|
||||||
{
|
{
|
||||||
*managedValPtr = AnimationControllerAsset(assetId);
|
*managedValPtr = AnimationControllerAsset(assetId);
|
||||||
return true;
|
return true;
|
||||||
|
@ -270,7 +270,7 @@ namespace SHADE
|
||||||
bool Editor::renderFieldEditorInternal<AssetID, AnimationRigAsset>(const std::string& fieldName, interior_ptr<AnimationRigAsset> managedValPtr, EditorFieldFunc<uint32_t>, bool* isHovered, RangeAttribute^)
|
bool Editor::renderFieldEditorInternal<AssetID, AnimationRigAsset>(const std::string& fieldName, interior_ptr<AnimationRigAsset> managedValPtr, EditorFieldFunc<uint32_t>, bool* isHovered, RangeAttribute^)
|
||||||
{
|
{
|
||||||
uint32_t assetId = managedValPtr->NativeAssetID;
|
uint32_t assetId = managedValPtr->NativeAssetID;
|
||||||
if (SHEditorUI::InputAssetField(fieldName, assetId, AssetType::MATERIAL, isHovered))
|
if (SHEditorUI::InputAssetField(fieldName, assetId, AssetType::MODEL, isHovered))
|
||||||
{
|
{
|
||||||
*managedValPtr = AnimationRigAsset(assetId);
|
*managedValPtr = AnimationRigAsset(assetId);
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in New Issue