82 lines
2.3 KiB
C++
82 lines
2.3 KiB
C++
// Copyright 2025 https://yuewu.dev/en All Rights Reserved.
|
||
|
||
#pragma once
|
||
|
||
#include "CoreMinimal.h"
|
||
#include "GMS_AnimLayer.h"
|
||
#include "Settings/GMS_SettingObjectLibrary.h"
|
||
#include "GMS_AnimLayer_Overlay.generated.h"
|
||
|
||
|
||
#pragma region Blend Data Structures
|
||
|
||
USTRUCT()
|
||
struct GENERICMOVEMENTSYSTEM_API FGMS_AnimData_PoseBlendSetting
|
||
{
|
||
GENERATED_BODY()
|
||
virtual ~FGMS_AnimData_PoseBlendSetting() = default;
|
||
/**
|
||
* The overall adoption of the pose(0~1).
|
||
* 姿势的整体采用度(0~1),1是开启,0是关闭。
|
||
*/
|
||
UPROPERTY(EditAnywhere, Category="GMS", meta=(ClampMin=0, ClampMax=1, DisplayPriority=0))
|
||
float BlendAmount{1.0f};
|
||
};
|
||
|
||
USTRUCT()
|
||
struct GENERICMOVEMENTSYSTEM_API FGMS_AnimData_PoseBlendSetting_TwoParams : public FGMS_AnimData_PoseBlendSetting
|
||
{
|
||
GENERATED_BODY()
|
||
|
||
/**
|
||
* Overall adoption of Montage playing on this slot (0~1)
|
||
* 在此槽上播放的Montage的整体采用度(0~1)
|
||
*/
|
||
UPROPERTY(EditAnywhere, Category="GMS", meta=(ClampMin=0, ClampMax=1, DisplayPriority=2))
|
||
float SlotBlendAmount{1.0f};
|
||
};
|
||
|
||
USTRUCT()
|
||
struct GENERICMOVEMENTSYSTEM_API FGMS_AnimData_PoseBlendSetting_ThreeParams : public FGMS_AnimData_PoseBlendSetting_TwoParams
|
||
{
|
||
GENERATED_BODY()
|
||
|
||
/**
|
||
* How much to blend the overlay pose with the underlying motion.
|
||
* 叠加姿势与底层运动的混合程度。
|
||
*/
|
||
UPROPERTY(EditAnywhere, Category="GMS", meta=(ClampMin=0, ClampMax=1, DisplayPriority=1))
|
||
float AdditiveBlendAmount{0.0f};
|
||
};
|
||
|
||
USTRUCT()
|
||
struct GENERICMOVEMENTSYSTEM_API FGMS_AnimData_PoseBlendSetting_FourParams : public FGMS_AnimData_PoseBlendSetting_ThreeParams
|
||
{
|
||
GENERATED_BODY()
|
||
|
||
UPROPERTY(EditAnywhere, Category="GMS", meta=(ClampMin=0, ClampMax=1, DisplayPriority=3))
|
||
bool bMeshSpace{true};
|
||
};
|
||
|
||
#pragma endregion
|
||
|
||
|
||
/**
|
||
* Base class for overlay animation layer settings.
|
||
* 叠加动画层设置的基类。
|
||
*/
|
||
UCLASS(Abstract, Blueprintable)
|
||
class GENERICMOVEMENTSYSTEM_API UGMS_AnimLayerSetting_Overlay : public UGMS_AnimLayerSetting
|
||
{
|
||
GENERATED_BODY()
|
||
|
||
public:
|
||
/**
|
||
* Checks if the overlay mode is valid.
|
||
* 检查叠加模式是否有效。
|
||
* @param NewOverlayMode The overlay mode to check. 要检查的叠加模式。
|
||
* @return True if the overlay mode is valid, false otherwise. 如果叠加模式有效则返回true,否则返回false。
|
||
*/
|
||
virtual bool IsValidForOverlayMode(const FGameplayTag& NewOverlayMode) const { return true; };
|
||
};
|