KLingo Project Documentation 1.0.0
Unreal Engine 5.6 C++ Project Documentation
로딩중...
검색중...
일치하는것 없음
AHolder.h
이 파일의 문서화 페이지로 가기
1// Copyright (c) 2025 Doppleddiggong. All rights reserved. Unauthorized copying, modification, or distribution of this file, via any medium is strictly prohibited. Proprietary and confidential.
2
3#pragma once
4
5#include "CoreMinimal.h"
6#include "GameFramework/Actor.h"
7#include "AHolder.generated.h"
8
9UCLASS()
10class ONEPIECE_API AHolder : public AActor
11{
12 GENERATED_BODY()
13
14public:
15 AHolder();
16
17protected:
18 virtual void BeginPlay() override;
19 virtual void Tick(float DeltaTime) override;
20 virtual void GetLifetimeReplicatedProps(TArray<class FLifetimeProperty>& OutLifetimeProps) const override;
21
22public:
23 void SetAnswerData(const int32 InAnswerColorIdx, const int32 InAnswerPatternIdx);
24
25 // Events
26 UFUNCTION(BlueprintImplementableEvent, Category = "Holder")
27 void OnActivate(bool bSuccess);
28
29private:
30 UFUNCTION()
31 void OnRep_IsActivated();
32
33 UFUNCTION()
34 void OnRep_CurTarget();
35
36 UFUNCTION()
37 void OnBoxOverlapBegin(
38 UPrimitiveComponent* OverlappedComponent,
39 AActor* OtherActor,
40 UPrimitiveComponent* OtherComp,
41 int32 OtherBodyIndex,
42 bool bFromSweep,
43 const FHitResult& SweepResult);
44
45 bool CheckLuggage(class Aluggage* TargetLuggage);
46
47protected:
48 void UpdateActivateState(bool State);
49
50public:
51 // Components
52 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Components")
53 TObjectPtr<class UBoxComponent> BoxCollision;
54
55 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Components")
56 TObjectPtr<class USkeletalMeshComponent> MeshComponent;
57
58 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Spawning")
59 TObjectPtr<class USceneComponent> HoldPos;
60
61protected:
62 // 현재 올라가 있는 액터
63 UPROPERTY(ReplicatedUsing=OnRep_CurTarget)
64 TObjectPtr<class AActor> CurTarget;
65
66 // State
67 UPROPERTY(ReplicatedUsing=OnRep_IsActivated, VisibleAnywhere, BlueprintReadOnly, Category = "State")
68 bool bIsActivated = false;
69
70 // Visual Settings
71 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Visual")
72 float ActivatedHeightOffset = 50.0f;
73
74 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Visual")
75 float RotationSpeed = 90.0f;
76
77 // Answer Settings
78 int32 AnswerColorIdx = -1;
79 int32 AnswerPatternIdx = -1;
80};
상호작용 가능한 수하물 액터
Definition luggage.h:15