2014-12-07 19:09:38 -05:00
|
|
|
// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved.
|
2014-07-08 09:43:39 -04:00
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
2015-06-30 22:25:56 -04:00
|
|
|
class IDetailCategoryBuilder;
|
|
|
|
|
class IPropertyHandle;
|
|
|
|
|
|
2014-07-08 09:43:39 -04:00
|
|
|
#include "AnimGraphNode_SkeletalControlBase.h"
|
2015-06-10 10:57:15 -04:00
|
|
|
#include "BoneControllers/AnimNode_BoneDrivenController.h"
|
2014-09-04 11:25:05 -04:00
|
|
|
#include "EdGraph/EdGraphNodeUtils.h" // for FNodeTitleTextTable
|
2014-07-08 09:43:39 -04:00
|
|
|
#include "AnimGraphNode_BoneDrivenController.generated.h"
|
|
|
|
|
|
2015-06-10 22:12:25 -04:00
|
|
|
/**
|
2015-06-17 18:54:05 -04:00
|
|
|
* This is the 'source version' of a bone driven controller, which maps part of the state from one bone to another (e.g., 2 * source.x -> target.z)
|
2015-06-10 22:12:25 -04:00
|
|
|
*/
|
|
|
|
|
UCLASS()
|
|
|
|
|
class ANIMGRAPH_API UAnimGraphNode_BoneDrivenController : public UAnimGraphNode_SkeletalControlBase
|
2014-07-08 09:43:39 -04:00
|
|
|
{
|
2015-03-17 05:38:32 -04:00
|
|
|
GENERATED_UCLASS_BODY()
|
2014-07-08 09:43:39 -04:00
|
|
|
|
|
|
|
|
UPROPERTY(EditAnywhere, Category = Settings)
|
|
|
|
|
FAnimNode_BoneDrivenController Node;
|
|
|
|
|
|
|
|
|
|
public:
|
2015-06-30 22:25:56 -04:00
|
|
|
// UObject interface
|
|
|
|
|
virtual void Serialize(FArchive& Ar) override;
|
|
|
|
|
// End of UObject interface
|
2014-07-08 09:43:39 -04:00
|
|
|
|
|
|
|
|
// UEdGraphNode interface
|
|
|
|
|
virtual FText GetNodeTitle(ENodeTitleType::Type TitleType) const override;
|
2014-09-03 18:14:09 -04:00
|
|
|
virtual FText GetTooltipText() const override;
|
2015-06-10 22:12:25 -04:00
|
|
|
// End of UEdGraphNode interface
|
2014-07-08 09:43:39 -04:00
|
|
|
|
2015-06-17 18:54:05 -04:00
|
|
|
// UAnimGraphNode_Base interface
|
|
|
|
|
virtual void ValidateAnimNodeDuringCompilation(USkeleton* ForSkeleton, FCompilerResultsLog& MessageLog) override;
|
|
|
|
|
virtual void CustomizeDetails(IDetailLayoutBuilder& DetailBuilder) override;
|
|
|
|
|
// End of UAnimGraphNode_Base interface
|
|
|
|
|
|
2014-07-08 09:43:39 -04:00
|
|
|
// UAnimGraphNode_SkeletalControlBase interface
|
2015-06-10 22:12:25 -04:00
|
|
|
virtual void Draw(FPrimitiveDrawInterface* PDI, USkeletalMeshComponent* SkelMeshComp) const override;
|
|
|
|
|
// End of UAnimGraphNode_SkeletalControlBase interface
|
2014-07-08 09:43:39 -04:00
|
|
|
|
|
|
|
|
protected:
|
|
|
|
|
|
2015-06-10 22:12:25 -04:00
|
|
|
// UAnimGraphNode_SkeletalControlBase protected interface
|
2014-07-08 09:43:39 -04:00
|
|
|
virtual FText GetControllerDescription() const override;
|
2015-06-10 22:12:25 -04:00
|
|
|
// End of UAnimGraphNode_SkeletalControlBase protected interface
|
2014-09-04 11:25:05 -04:00
|
|
|
|
2015-07-13 19:53:41 -04:00
|
|
|
// Should non-curve mapping values be shown (multiplier, range)?
|
2015-06-17 18:54:05 -04:00
|
|
|
EVisibility AreNonCurveMappingValuesVisible() const;
|
2015-07-13 19:53:41 -04:00
|
|
|
EVisibility AreRemappingValuesVisible() const;
|
2015-06-17 18:54:05 -04:00
|
|
|
|
2015-06-30 22:25:56 -04:00
|
|
|
static void AddTripletPropertyRow(const FText& Name, const FText& Tooltip, IDetailCategoryBuilder& Category, TSharedRef<IPropertyHandle> PropertyHandle, const FName XPropertyName, const FName YPropertyName, const FName ZPropertyName);
|
2015-07-13 19:53:41 -04:00
|
|
|
static void AddRangePropertyRow(const FText& Name, const FText& Tooltip, IDetailCategoryBuilder& Category, TSharedRef<IPropertyHandle> PropertyHandle, const FName MinPropertyName, const FName MaxPropertyName, TAttribute<EVisibility> VisibilityAttribute);
|
2015-06-30 22:25:56 -04:00
|
|
|
static FText ComponentTypeToText(EComponentType::Type Component);
|
2015-06-17 18:54:05 -04:00
|
|
|
};
|