You're breathtaking!

This commit is contained in:
Wojtek Figat
2020-12-07 23:40:54 +01:00
commit 6fb9eee74c
5143 changed files with 1153594 additions and 0 deletions

View File

@@ -0,0 +1,44 @@
// Copyright (c) 2012-2020 Wojciech Figat. All rights reserved.
using System;
using FlaxEditor.Windows;
using FlaxEditor.Windows.Assets;
using FlaxEngine;
namespace FlaxEditor.Content
{
/// <summary>
/// A <see cref="AnimationGraphFunction"/> asset proxy object.
/// </summary>
/// <seealso cref="FlaxEditor.Content.BinaryAssetProxy" />
public class AnimationGraphFunctionProxy : BinaryAssetProxy
{
/// <inheritdoc />
public override string Name => "Animation Graph Function";
/// <inheritdoc />
public override EditorWindow Open(Editor editor, ContentItem item)
{
return new AnimationGraphFunctionWindow(editor, item as AssetItem);
}
/// <inheritdoc />
public override Color AccentColor => Color.FromRGB(0x991597);
/// <inheritdoc />
public override Type AssetType => typeof(AnimationGraphFunction);
/// <inheritdoc />
public override bool CanCreate(ContentFolder targetLocation)
{
return targetLocation.CanHaveAssets;
}
/// <inheritdoc />
public override void Create(string outputPath, object arg)
{
if (Editor.CreateAsset(Editor.NewAssetType.AnimationGraphFunction, outputPath))
throw new Exception("Failed to create new asset.");
}
}
}