Space Plunder
Loading...
Searching...
No Matches
QuestGoalComponent.h
Go to the documentation of this file.
1// Fill out your copyright notice in the Description page of Project Settings.
2
3#pragma once
4
5#include "CoreMinimal.h"
6#include "Components/ActorComponent.h"
7#include "Data/QuestData.h"
9#include "QuestGoalComponent.generated.h"
10
11
12UCLASS(Blueprintable, BlueprintType, ClassGroup=(BucciGames), meta=(BlueprintSpawnableComponent))
13class QUESTSYSTEM_API UQuestGoalComponent : public UActorComponent
14{
15 GENERATED_BODY()
16
17public:
18 UQuestGoalComponent();
19
20
21 //@ TODO Should return if there's anything left for this to do.. so parents can know to destroy it
23 bool GetQuestGoalComplete();
24
25 bool GetShouldAddQuest(AActor* Caller) const;
26
27 //@ TODO
28 void SetUniqueID(const int32 ID){UniqueID = ID;};
29
30 USceneComponent* GetWaypointAttachPoint(FName& Socket) const;
31
32 UFUNCTION(BlueprintCallable, Category="Quest System", BlueprintPure=false)
33 bool SaveQuests() const;
34
35
36 UFUNCTION(BlueprintCallable, Category="Quest System")
37 bool AddQuest(AActor* Caller);
38
39 UFUNCTION(BlueprintCallable, Category="Quest System")
40 bool ReportQuestObjective();
41 UFUNCTION(BlueprintCallable, Category="Quest System")
42 bool ReportQuestObjectivePenalty();
43
44 UFUNCTION(BlueprintCallable, Category="Quest System")
45 bool ReportQuestObjectiveAmount(const int32 Amount);
46
47 UFUNCTION(BlueprintCallable, Category="Quest System")
48 bool ReportQuestObjectivePenaltyAmount(const int32 Amount);
49
50 UFUNCTION(BlueprintCallable, Category="Quest System")
51 void QuestGoalFailed();
52 // UFUNCTION(BlueprintCallable, Category="Quest System")
53 // void QuestFailed();
54
55 void RemoveQuestID();
56 void RemoveQuestID(const FString& QuestID);
57
58
59 UFUNCTION(BlueprintCallable, Category="Quest System")
60 FVector GetWaypointLocation() const;
61
62 //? Do i need, as it needs to be binded to Actor
63 UFUNCTION(BlueprintCallable, Category="Quest System")
64 void SetWaypointLocation(const FVector& Location){WaypointLocation = Location;};
65
66 // UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Quest System|Goal")
67 // FString QuestToAdd;
68
69 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Quest System|Goal")
70 TArray<FString> QuestsToAdd;
71
72 // UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Quest System|Goal")
73 // TArray<FQuestGoal> QuestGoals;
74
75
76 // UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Quest System|Goal")
77 // bool bQuestPenalty = false;
78 // UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Quest System|Goal")
79 // TArray<FQuestGoal> QuestPenalties;
80
81 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Quest System|Goal")
82 FQuestItemData QuestItemData;
83
84
85 UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category="Quest System|Goal")
86 TArray<AActor*> WaypointActors;
87 UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category="Quest System|Goal")
88 int32 ReporterID = -1;
89
90protected:
91 virtual void BeginPlay() override;
92
93 IQuestReporter* GetQuestReporter();
94
95 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Quest System|Goal")
96 bool bAddQuest = false;
97
98 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Quest System|Goal")
99 FName AttachSocket = NAME_None;
100
101
102 //- Change to AActor?
103 UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category="Quest System|Goal")
104 TSubclassOf<AActor> WaypointActorClass;
105 UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category="Quest System|Goal")
106 FVector WaypointLocation;
107
108 UPROPERTY(VisibleAnywhere, BlueprintReadOnly, Category="Quest System|Goal")
109 int32 UniqueID = -1;
110
111 // UPROPERTY(BlueprintReadOnly, Category="Quest System|Goal")
112 // USceneComponent* WaypointAttachPoint;
113 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category="Quest System|Goal")
114 bool bDebuggingMode = false;
115
116
117private:
118 class IQuestReporter* QuestReporter = nullptr;
119};
UCLASS(Blueprintable, BlueprintType, ClassGroup=(BucciGames), meta=(BlueprintSpawnableComponent)) class CHATSYSTEM_API UChatSystemComponent
Definition ChatSystemComponent.h:13
Definition QuestReporter.h:23
Definition QuestData.h:140