Add automatic restoring Anim Event tracks when reimporting animation asset
#2363
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "Engine/Core/Types/String.h"
|
||||
#include "Engine/Core/Types/Pair.h"
|
||||
#include "Engine/Core/Math/Transform.h"
|
||||
#include "Engine/Animations/Curve.h"
|
||||
|
||||
@@ -68,6 +69,16 @@ public:
|
||||
uint64 GetMemoryUsage() const;
|
||||
};
|
||||
|
||||
/// <summary>
|
||||
/// Single track with events.
|
||||
/// </summary>
|
||||
struct EventAnimationData
|
||||
{
|
||||
float Duration = 0.0f;
|
||||
StringAnsi TypeName;
|
||||
StringAnsi JsonData;
|
||||
};
|
||||
|
||||
/// <summary>
|
||||
/// Root Motion modes that can be applied by the animation. Used as flags for selective behavior.
|
||||
/// </summary>
|
||||
@@ -120,10 +131,15 @@ struct AnimationData
|
||||
String RootNodeName;
|
||||
|
||||
/// <summary>
|
||||
/// The per skeleton node animation channels.
|
||||
/// The per-skeleton node animation channels.
|
||||
/// </summary>
|
||||
Array<NodeAnimationData> Channels;
|
||||
|
||||
/// <summary>
|
||||
/// The animation event tracks.
|
||||
/// </summary>
|
||||
Array<Pair<String, StepCurve<EventAnimationData>>> Events;
|
||||
|
||||
public:
|
||||
/// <summary>
|
||||
/// Gets the length of the animation (in seconds).
|
||||
|
||||
Reference in New Issue
Block a user