Payback 0.0.1
CK Graduation Project
로딩중...
검색중...
일치하는것 없음
UConstellationBuffSlotWidget 클래스 참조

#include <ConstellationBuffSlotWidget.h>

UConstellationBuffSlotWidget에 대한 상속 다이어그램 :
Inheritance graph
UConstellationBuffSlotWidget에 대한 협력 다이어그램:
Collaboration graph

Public 멤버 함수

void SetupSlot (USituationBase *InSituation, UTexture2D *InIcon)
 
void UpdateRemaining (float NormalizedRemaining, float RemainingSeconds, bool bIsPermanent)
 
FORCEINLINE USituationBaseGetBoundSituation () const
 
- UUserWidgetBase(으)로부터 상속된 Public 멤버 함수
virtual void SetAbilitySystemComponent (AActor *InOwner)
 
virtual UAbilitySystemComponent * GetAbilitySystemComponent () const override
 
virtual void OnPushedToLayer ()
 
virtual void OnPoppedFromLayer ()
 
virtual void OnActivated ()
 
virtual void OnDeactivated ()
 
void Activate ()
 
void Deactivate ()
 
FORCEINLINE FGameplayTag GetLayerTag () const
 
FORCEINLINE void SetLayerTag (const FGameplayTag InTag)
 
FORCEINLINE bool IsPrimary () const
 
FORCEINLINE void SetPrimary (const bool InPrimary)
 
FORCEINLINE EWidgetState GetWidgetState () const
 
FORCEINLINE void SetWidgetState (const EWidgetState InState)
 
FORCEINLINE UWaitForWidgetActivationGetActivationHandle ()
 
FORCEINLINE bool HasAppearanceAnim () const
 
FORCEINLINE bool HasDisappearanceAnim () const
 

Protected 멤버 함수

void OnSlotSetup (USituationBase *InSituation)
 
void OnRemainingUpdated (float RemainingSeconds, bool bIsPermanent)
 
- UUserWidgetBase(으)로부터 상속된 Protected 멤버 함수
virtual void OnWidgetActivated ()
 
virtual void OnWidgetDeactivated ()
 
void OnPushedToLayer_Internal ()
 
void OnPoppedFromLayer_Internal ()
 
void OnActivated_Internal ()
 
void OnDeactivated_Internal ()
 

Protected 속성

FSlateBrush DurationProgressBrush
 
FName ProgressParameterName = TEXT("Progress")
 
TObjectPtr< UImage > BuffIcon
 
TObjectPtr< UImage > DurationProgressImage
 
TObjectPtr< UMaterialInstanceDynamic > DurationProgressMaterial
 
TWeakObjectPtr< USituationBaseBoundSituation
 
- UUserWidgetBase(으)로부터 상속된 Protected 속성
EWidgetState WidgetState
 
TObjectPtr< UAbilitySystemComponent > ASC
 
FGameplayTag LayerTag
 
bool bPrimary = false
 
TObjectPtr< UWidgetAnimation > AppearanceAnim
 
TObjectPtr< UWidgetAnimation > DisappearanceAnim
 

Private 속성

uint8 bDurationMaterialUnavailable: 1 = false
 

상세한 설명

활성 버프 하나를 나타내는 슬롯. 아이콘 위에 겹친 원형 프로그레스 머티리얼로 남은 시간을 시계방향으로 표시한다.

버프는 상황 카드가 소유하므로 슬롯 하나는 장착된 상황 하나에 묶인다.

멤버 함수 문서화

◆ GetBoundSituation()

FORCEINLINE USituationBase * UConstellationBuffSlotWidget::GetBoundSituation ( ) const
inline
34 {
35 return BoundSituation.Get();
36 }
TWeakObjectPtr< USituationBase > BoundSituation
Definition ConstellationBuffSlotWidget.h:68

◆ OnRemainingUpdated()

void UConstellationBuffSlotWidget::OnRemainingUpdated ( float  RemainingSeconds,
bool  bIsPermanent 
)
protected
이 함수를 호출하는 함수들에 대한 그래프입니다.:

◆ OnSlotSetup()

void UConstellationBuffSlotWidget::OnSlotSetup ( USituationBase InSituation)
protected
이 함수를 호출하는 함수들에 대한 그래프입니다.:

◆ SetupSlot()

void UConstellationBuffSlotWidget::SetupSlot ( USituationBase InSituation,
UTexture2D *  InIcon 
)
14{
15 BoundSituation = InSituation;
16
17 // 슬롯이 재사용될 수 있으므로 머티리얼 확보 상태를 되돌린다.
20
21 if (BuffIcon && InIcon)
22 {
23 BuffIcon->SetBrushFromTexture(InIcon);
24 }
25
26 OnSlotSetup(InSituation);
27}
uint8 bDurationMaterialUnavailable
Definition ConstellationBuffSlotWidget.h:72
TObjectPtr< UMaterialInstanceDynamic > DurationProgressMaterial
Definition ConstellationBuffSlotWidget.h:65
void OnSlotSetup(USituationBase *InSituation)
TObjectPtr< UImage > BuffIcon
Definition ConstellationBuffSlotWidget.h:58
이 함수 내부에서 호출하는 함수들에 대한 그래프입니다.:
이 함수를 호출하는 함수들에 대한 그래프입니다.:

◆ UpdateRemaining()

void UConstellationBuffSlotWidget::UpdateRemaining ( float  NormalizedRemaining,
float  RemainingSeconds,
bool  bIsPermanent 
)
31{
32 // 매 틱 호출되므로 실패한 뒤에는 다시 시도하지 않는다.
34 {
35 if (IsValid(DurationProgressImage))
36 {
37 // 브러시 리소스가 머티리얼이어야 GetDynamicMaterial 이 성공한다.
38 // 위젯에 지정한 브러시가 있으면 먼저 씌운다. (SkillSlotWidget 과 같은 방식)
39 if (DurationProgressBrush.GetResourceObject())
40 {
42 }
43
44 DurationProgressMaterial = DurationProgressImage->GetDynamicMaterial();
45 }
46
47 if (DurationProgressMaterial == nullptr)
48 {
50
51 LOG_WARNING(LogCK, "'%s' 의 DurationProgressImage 에서 다이나믹 머티리얼을 얻지 못해 남은 시간 게이지를 끕니다. 이미지 브러시나 DurationProgressBrush 에 Progress 파라미터를 가진 머티리얼을 지정하세요.", *GetClass()->GetName());
52 }
53 }
54
56 {
57 // 영구 버프는 줄어들 게 없으므로 게이지를 가득 채운 채 둔다.
58 const float Progress = bIsPermanent ? 1.0f : FMath::Clamp(NormalizedRemaining, 0.0f, 1.0f);
59
60 DurationProgressMaterial->SetScalarParameterValue(ProgressParameterName, Progress);
61 }
62
63 // 게이지가 없어도 남은 시간 텍스트 등은 계속 갱신되어야 한다.
64 OnRemainingUpdated(RemainingSeconds, bIsPermanent);
65}
#define LOG_WARNING(Category, Format,...)
Definition CK_UE.h:39
FSlateBrush DurationProgressBrush
Definition ConstellationBuffSlotWidget.h:51
void OnRemainingUpdated(float RemainingSeconds, bool bIsPermanent)
TObjectPtr< UImage > DurationProgressImage
Definition ConstellationBuffSlotWidget.h:62
FName ProgressParameterName
Definition ConstellationBuffSlotWidget.h:54
이 함수 내부에서 호출하는 함수들에 대한 그래프입니다.:

멤버 데이터 문서화

◆ bDurationMaterialUnavailable

uint8 UConstellationBuffSlotWidget::bDurationMaterialUnavailable
private

◆ BoundSituation

TWeakObjectPtr<USituationBase> UConstellationBuffSlotWidget::BoundSituation
protected

◆ BuffIcon

TObjectPtr<UImage> UConstellationBuffSlotWidget::BuffIcon
protected

◆ DurationProgressBrush

FSlateBrush UConstellationBuffSlotWidget::DurationProgressBrush
protected

◆ DurationProgressImage

TObjectPtr<UImage> UConstellationBuffSlotWidget::DurationProgressImage
protected

◆ DurationProgressMaterial

TObjectPtr<UMaterialInstanceDynamic> UConstellationBuffSlotWidget::DurationProgressMaterial
protected

◆ ProgressParameterName

FName UConstellationBuffSlotWidget::ProgressParameterName = TEXT("Progress")
protected

이 클래스에 대한 문서화 페이지는 다음의 파일들로부터 생성되었습니다.: