Payback 0.0.1
CK Graduation Project
로딩중...
검색중...
일치하는것 없음
HpBarUserWidget.h
이 파일의 문서화 페이지로 가기
1// Fill out your copyright notice in the Description page of Project Settings.
2
3#pragma once
4
5#include "CoreMinimal.h"
6#include "UI/UserWidgetBase.h"
7#include "GameplayEffectTypes.h"
8#include "HpBarUserWidget.generated.h"
9
13UCLASS()
14class CK_UE_API UHpBarUserWidget : public UUserWidgetBase
15{
16 GENERATED_BODY()
17
18public:
19 virtual void SetAbilitySystemComponent(AActor* InOwner) override;
20
21protected:
22 virtual void NativeDestruct() override;
23
24 virtual void OnHealthChanged(const FOnAttributeChangeData& ChangeData);
25 virtual void OnMaxHealthChanged(const FOnAttributeChangeData& ChangeData);
26 void UpdateHpBar();
27
28
29protected:
30 UPROPERTY(meta = (BindWidget))
31 TObjectPtr<class UProgressBar> HpBar;
32
33 float CurrentHealth = 0.0f;
34 float CurrentMaxHealth = 1.0f;
35
36private:
37 FDelegateHandle HealthChangedDelegateHandle;
38 FDelegateHandle MaxHealthChangedDelegateHandle;
39};
Definition HpBarUserWidget.h:15
Definition UserWidgetBase.h:15