[UE5] 블루프린트 변수 노출

ChangJin·2024년 3월 3일
0

Unreal Engine5

목록 보기
27/102
post-thumbnail

참고

https://docs.unrealengine.com/4.27/ko/ProgrammingAndScripting/Blueprints/UserGuide/Variables/


UPROPERTY 지정자

  • UPROPERTY 지정자로 원하는 곳에서 노출을 시키거나 편집할 수 있게 만들 수 있습니다
  • 해당 Blueprint를 월드에 드래그하여 놓으면 나오는 instance 창에서는 VisibleInstanceOnlyInt가 나오지만 Blueprint Details에서는 해당 변수가 보이지 않습니다

  • VisibleAnywhereInt는 ReadOnly이기 때문에 값을 변경할 수 없습니다
  • EditAnywhereInt는 어디서든 읽기, 쓰기가 가능합니다

public: 
	// Sets default values for this pawn's properties
	ABasePawn();

	UPROPERTY(VisibleAnywhere)
	int32 VisibleAnywhereInt = 32;

	UPROPERTY(EditAnywhere)
	int32 EditAnywhereInt = 32;

	UPROPERTY(VisibleInstanceOnly)
	int32 VisibleInstanceOnlyInt = 32;
profile
Unreal Engine 클라이언트 개발자

0개의 댓글