About UPROPERTY()

REWELLGOM·2024년 5월 20일

Unreal5

목록 보기
2/26

UPROPERTY(EditAnywhere)

UPROPERTY(EditAnywhere)
float Health;

You can edit it anwhere! really any where!

UPROPERTY(EditDefaultsOnly)

UPROPERTY(EditDefaultsOnly)
float Health;

You can edit it only in Detail window which in Blue Print Editor

UPROPERTY(VisibleAnywhere)

UPROPERTY(EditInstanceOnly)
float Health;

You can only edit it in instance(UEeditor outliner)

UPROPERTY(VisibleAnywhere)

UPROPERTY(VisibleAnywhere)
float Health;

You can only read it anywhere but can't edit it

UPROPERTY(VisibleDefaultsOnly)

UPROPERTY(VisibleDefaultsOnly)
float Health;

You can only read it Detail window which in Blue Print Editor and also can't edit it

UPROPERTY(VisibleInstanceOnly)

UPROPERTY(VisibleInstanceOnly)
float Health;

You can only read it in instance(UEeditor outliner) and also can't edit it

UPORPERTY(BlueprintReadWrite)

UPROPERTY(EditAnywhere, BlueprintReadWrite)
float Health;

You can read and write in the Blue Print

UPORPERTY(EditAnywhere, BlueprintReadWrite)

UPROPERTY(EditAnywhere, BlueprintReadOnly)
float Health;

1.And also you can use it like this
2.This means you can edit anywher and also you can call it in Event Graph as variable

Caution: You must use it in protected

UPROPERTY(VisibleInstanceOnly, BlueprintReadOnly, meta = (AllowPrivateAccess = "true"))

UPROPERTY(VisibleInstanceOnly, BlueprintReadOnly, meta = (AllowPrivateAccess = "true"))
float RunningTime;

It makes we can access private variable type

profile
코테는 초딩한테 이해하기 쉽게 문제 해설해주는거다

0개의 댓글