fr.jeanf.questsystem 0.0.29 → 0.0.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Runtime/Quests/Quest_StethoscopeCheck.prefab +2 -1
- package/Runtime/Quests/Quest_VisitAllPlaces.prefab +2 -1
- package/Runtime/Quests/Quest_VisitPlaces.prefab +2 -1
- package/Runtime/Scripts/Core/Editor/QuestInfoSO_Editor.cs +2 -2
- package/Runtime/Scripts/Core/Quest.cs +25 -64
- package/Runtime/Scripts/Core/QuestData.cs +14 -0
- package/Runtime/Scripts/Core/QuestItem.cs +146 -92
- package/Runtime/Scripts/Core/QuestManager.cs +48 -76
- package/Runtime/Scripts/Core/QuestSO.cs +75 -0
- package/Runtime/Scripts/Core/{QuestInfoSO.cs.meta → QuestSO.cs.meta} +1 -1
- package/Runtime/Scripts/Core/QuestStep.cs +84 -45
- package/Runtime/Scripts/Events/QuestEvents.cs +10 -21
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/Comparison.cs +39 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/Comparison.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/ConditionalLink.cs +4 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/ConditionalLink.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/ConditionalNode.cs +72 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/ConditionalNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/ConditionalProcessor.cs +200 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/ConditionalProcessor.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/Editor/ComparisonView.cs +49 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/Editor/ComparisonView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/Editor/ConditionalProcessorView.cs +53 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/Editor/ConditionalProcessorView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/Editor.meta +8 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/IConditionalNode.cs +12 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/IConditionalNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/RuntimeConditionalGraph.cs +19 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/RuntimeConditionalGraph.cs.meta +3 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/StartNode.cs +24 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph/StartNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/ConditionalGraph.meta +8 -0
- package/Runtime/Scripts/NodeGraph/CustomConvertions.cs +17 -0
- package/Runtime/Scripts/NodeGraph/CustomConvertions.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/AbstractNodeView.cs +17 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/AbstractNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/CircleRadiansView.cs +49 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/CircleRadiansView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/ColorNodeView.cs +18 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/ColorNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/FloatNodeView.cs +31 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/FloatNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/ForLoopNodeView.cs +23 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/ForLoopNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/IfNodeView.cs +22 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/IfNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/MessageNode2View.cs +16 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/MessageNode2View.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/MutliAddNodeView.cs +27 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/MutliAddNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/PrefabNodeView.cs +41 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/PrefabNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/PrintNodeView.cs +67 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/PrintNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/SettingsNodeView.cs +32 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/SettingsNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/StringNodeView.cs +28 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/StringNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/SwitchNodeView.cs +21 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/SwitchNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/TypeSwitchNodeView.cs +25 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor/TypeSwitchNodeView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Editor.meta +8 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/AbstractNode.cs +26 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/AbstractNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/CircleRadians.cs +28 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/CircleRadians.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/ColorNode.cs +14 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/ColorNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/ConsoleLogNode.cs +41 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/ConsoleLogNode.cs.meta +3 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/CustomPortDataNode.cs +52 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/CustomPortDataNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/CustomPortsNode.cs +64 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/CustomPortsNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/DrawerFieldTestNode.cs +56 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/DrawerFieldTestNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/FieldTestNode.cs +28 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/FieldTestNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/FloatNode.cs +18 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/FloatNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/ForLoopNode.cs +42 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/ForLoopNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/GameObjectNode.cs +20 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/GameObjectNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/IfNode.cs +33 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/IfNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/Inheritance1.cs +24 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/Inheritance1.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/Inheritance2.cs +24 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/Inheritance2.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/InheritanceBase.cs +24 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/InheritanceBase.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/InspectorNode.cs +27 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/InspectorNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/ListNode.cs +24 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/ListNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/MessageNode.cs +27 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/MessageNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/MessageNode2.cs +22 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/MessageNode2.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/MultiAddNode.cs +40 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/MultiAddNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/OutputNode.cs +21 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/OutputNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/PortConnectionTests.cs +47 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/PortConnectionTests.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/PrefabNode.cs +14 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/PrefabNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/PrintNode.cs +23 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/PrintNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/RenamableNode.cs +18 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/RenamableNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/SettingsNode.cs +27 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/SettingsNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/StringNode.cs +14 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/StringNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/SubNode.cs +24 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/SubNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/SwitchNode.cs +22 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/SwitchNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/TextNode.cs +14 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/TextNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/TypeSwitchNode.cs +32 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/TypeSwitchNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/UnityEventNode.cs +22 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/UnityEventNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/VectorNode.cs +22 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/VectorNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/VerticalNode.cs +23 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/VerticalNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/VerticalNode2.cs +25 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/VerticalNode2.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/VisibleIfAttributeNode.cs +49 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/VisibleIfAttributeNode.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/WaitFrameNode.cs +48 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/WaitFrameNode.cs.meta +3 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/WaitNode.cs +48 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes/WaitNode.cs.meta +3 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes/Nodes.meta +8 -0
- package/Runtime/Scripts/NodeGraph/DefaultNodes.meta +8 -0
- package/Runtime/Scripts/NodeGraph/Editor/01_DefaultGraph/DefaultGraphWindow.cs +41 -0
- package/Runtime/Scripts/NodeGraph/Editor/01_DefaultGraph/DefaultGraphWindow.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/01_DefaultGraph.meta +8 -0
- package/Runtime/Scripts/NodeGraph/Editor/02_CustomContextMenu/CustomContextMenuGraphView.cs +34 -0
- package/Runtime/Scripts/NodeGraph/Editor/02_CustomContextMenu/CustomContextMenuGraphView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/02_CustomContextMenu/CustomContextMenuGraphWindow.cs +44 -0
- package/Runtime/Scripts/NodeGraph/Editor/02_CustomContextMenu/CustomContextMenuGraphWindow.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/02_CustomContextMenu.meta +8 -0
- package/Runtime/Scripts/NodeGraph/Editor/03_CustomToolbar/CustomToolbarGraphView.cs +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/03_CustomToolbar/CustomToolbarGraphView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/03_CustomToolbar/CustomToolbarGraphWindow.cs +44 -0
- package/Runtime/Scripts/NodeGraph/Editor/03_CustomToolbar/CustomToolbarGraphWindow.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/03_CustomToolbar/CustomToolbarView.cs +23 -0
- package/Runtime/Scripts/NodeGraph/Editor/03_CustomToolbar/CustomToolbarView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/03_CustomToolbar.meta +8 -0
- package/Runtime/Scripts/NodeGraph/Editor/04_ExposedProperties/ExposedPropertiesGraph.cs +10 -0
- package/Runtime/Scripts/NodeGraph/Editor/04_ExposedProperties/ExposedPropertiesGraph.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/04_ExposedProperties/ExposedPropertiesGraphView.cs +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/04_ExposedProperties/ExposedPropertiesGraphView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/04_ExposedProperties/ExposedPropertiesGraphWindow.cs +46 -0
- package/Runtime/Scripts/NodeGraph/Editor/04_ExposedProperties/ExposedPropertiesGraphWindow.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/04_ExposedProperties.meta +8 -0
- package/Runtime/Scripts/NodeGraph/Editor/05_All/AllGraphView.cs +28 -0
- package/Runtime/Scripts/NodeGraph/Editor/05_All/AllGraphView.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/05_All/AllGraphWindow.cs +52 -0
- package/Runtime/Scripts/NodeGraph/Editor/05_All/AllGraphWindow.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/05_All.meta +8 -0
- package/Runtime/Scripts/NodeGraph/Editor/GraphAssetCallbacks.cs +30 -0
- package/Runtime/Scripts/NodeGraph/Editor/GraphAssetCallbacks.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/GraphAssetInspector.cs +36 -0
- package/Runtime/Scripts/NodeGraph/Editor/GraphAssetInspector.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/GraphBehaviourEditor.cs +35 -0
- package/Runtime/Scripts/NodeGraph/Editor/GraphBehaviourEditor.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor/GraphProcessorMenuItems.cs +13 -0
- package/Runtime/Scripts/NodeGraph/Editor/GraphProcessorMenuItems.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/Editor.meta +8 -0
- package/Runtime/Scripts/NodeGraph/GraphBehaviour.cs +16 -0
- package/Runtime/Scripts/NodeGraph/GraphBehaviour.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/RuntimeGraph/RuntimeGraph.cs +31 -0
- package/Runtime/Scripts/NodeGraph/RuntimeGraph/RuntimeGraph.cs.meta +11 -0
- package/Runtime/Scripts/NodeGraph/RuntimeGraph.meta +8 -0
- package/Runtime/Scripts/NodeGraph.meta +8 -0
- package/Runtime/Scripts/Nodes/EndNode.cs +14 -0
- package/Runtime/Scripts/Nodes/EndNode.cs.meta +11 -0
- package/Runtime/Scripts/Nodes/QuestFinished.asset +16 -0
- package/Runtime/Scripts/Nodes/QuestFinished.asset.meta +8 -0
- package/Runtime/Scripts/Nodes/QuestStarted.asset +16 -0
- package/Runtime/Scripts/Nodes/QuestStarted.asset.meta +8 -0
- package/Runtime/Scripts/Nodes/QuestStepNode.cs +64 -0
- package/Runtime/Scripts/Nodes/QuestStepNode.cs.meta +11 -0
- package/Runtime/Scripts/Nodes/QuestTree.asset +153 -0
- package/Runtime/Scripts/Nodes/QuestTree.asset.meta +8 -0
- package/Runtime/Scripts/Nodes/StepStarted.asset +16 -0
- package/Runtime/Scripts/Nodes/StepStarted.asset.meta +8 -0
- package/Runtime/Scripts/Nodes.meta +8 -0
- package/Runtime/Scripts/jeanf.QuestSystem.asmdef +3 -1
- package/Runtime/Scripts/quests/Quest_StethoscopeCheck.prefab +10 -478
- package/Runtime/Scripts/quests/Quest_VisitAllPlaces.prefab +10 -478
- package/package.json +1 -1
- package/Runtime/Scripts/Core/QuestInfoSO.cs +0 -43
|
@@ -167,10 +167,11 @@ MonoBehaviour:
|
|
|
167
167
|
m_EditorClassIdentifier:
|
|
168
168
|
_isDebug: 1
|
|
169
169
|
_startQuestOnEnable: 0
|
|
170
|
-
|
|
170
|
+
questSO: {fileID: 11400000, guid: b7b6381ae7b9c2244862b31a1ce5b2f5, type: 2}
|
|
171
171
|
progress: 0
|
|
172
172
|
clearToStart: 0
|
|
173
173
|
QuestProgress: {fileID: 11400000, guid: d6b05e1957994c8449fb72e849a2a3d6, type: 2}
|
|
174
174
|
StartQuestEventChannel: {fileID: 11400000, guid: c510c1e4d26428740b3e329cca98e5d1,
|
|
175
175
|
type: 2}
|
|
176
|
+
QuestInitialCheck: {fileID: 11400000, guid: 4f5235d1ff779064cabee9ca65296d7f, type: 2}
|
|
176
177
|
requirementCheck: {fileID: 11400000, guid: a4dae407f780f974abbf43c280515876, type: 2}
|
|
@@ -167,10 +167,11 @@ MonoBehaviour:
|
|
|
167
167
|
m_EditorClassIdentifier:
|
|
168
168
|
_isDebug: 1
|
|
169
169
|
_startQuestOnEnable: 0
|
|
170
|
-
|
|
170
|
+
questSO: {fileID: 11400000, guid: ee924c4edf671a44b8585cc39cc20e7a, type: 2}
|
|
171
171
|
progress: 0
|
|
172
172
|
clearToStart: 0
|
|
173
173
|
QuestProgress: {fileID: 11400000, guid: d6b05e1957994c8449fb72e849a2a3d6, type: 2}
|
|
174
174
|
StartQuestEventChannel: {fileID: 11400000, guid: c510c1e4d26428740b3e329cca98e5d1,
|
|
175
175
|
type: 2}
|
|
176
|
+
QuestInitialCheck: {fileID: 11400000, guid: 4f5235d1ff779064cabee9ca65296d7f, type: 2}
|
|
176
177
|
requirementCheck: {fileID: 11400000, guid: a4dae407f780f974abbf43c280515876, type: 2}
|
|
@@ -167,10 +167,11 @@ MonoBehaviour:
|
|
|
167
167
|
m_EditorClassIdentifier:
|
|
168
168
|
_isDebug: 1
|
|
169
169
|
_startQuestOnEnable: 0
|
|
170
|
-
|
|
170
|
+
questSO: {fileID: 11400000, guid: a249a914e47bba041b17cb82c0fd3105, type: 2}
|
|
171
171
|
progress: 0
|
|
172
172
|
clearToStart: 0
|
|
173
173
|
QuestProgress: {fileID: 11400000, guid: d6b05e1957994c8449fb72e849a2a3d6, type: 2}
|
|
174
174
|
StartQuestEventChannel: {fileID: 11400000, guid: c510c1e4d26428740b3e329cca98e5d1,
|
|
175
175
|
type: 2}
|
|
176
|
+
QuestInitialCheck: {fileID: 11400000, guid: 4f5235d1ff779064cabee9ca65296d7f, type: 2}
|
|
176
177
|
requirementCheck: {fileID: 11400000, guid: a4dae407f780f974abbf43c280515876, type: 2}
|
|
@@ -6,11 +6,11 @@ using UnityEngine;
|
|
|
6
6
|
|
|
7
7
|
public class QuestInfoSO_Editor : Editor
|
|
8
8
|
{
|
|
9
|
-
[CustomEditor(typeof(
|
|
9
|
+
[CustomEditor(typeof(QuestSO))]
|
|
10
10
|
public class BoolEventOnClickEditor : Editor {
|
|
11
11
|
override public void OnInspectorGUI () {
|
|
12
12
|
GUILayout.Space(10);
|
|
13
|
-
var eventToSend = (
|
|
13
|
+
var eventToSend = (QuestSO)target;
|
|
14
14
|
if(GUILayout.Button("Regenerate quest id", GUILayout.Height(20))) {
|
|
15
15
|
eventToSend.GenerateId(); // how do i call this?
|
|
16
16
|
}
|
|
@@ -1,105 +1,65 @@
|
|
|
1
|
+
using System;
|
|
1
2
|
using System.Collections;
|
|
2
3
|
using System.Collections.Generic;
|
|
4
|
+
using GraphProcessor;
|
|
3
5
|
using jeanf.EventSystem;
|
|
4
6
|
using jeanf.propertyDrawer;
|
|
5
7
|
using UnityEngine;
|
|
8
|
+
using Object = UnityEngine.Object;
|
|
6
9
|
|
|
7
10
|
namespace jeanf.questsystem
|
|
8
11
|
{
|
|
9
12
|
public class Quest
|
|
10
13
|
{
|
|
11
14
|
// static info
|
|
12
|
-
public
|
|
15
|
+
public QuestSO questSO;
|
|
13
16
|
|
|
14
17
|
// state info
|
|
15
18
|
public QuestState state;
|
|
16
|
-
private int currentQuestStepIndex;
|
|
17
|
-
public int currentStep;
|
|
18
19
|
private QuestStepState[] questStepStates;
|
|
19
20
|
public StringEventChannelSO messageChannel;
|
|
20
21
|
public bool sendMessageOnInitialization = false;
|
|
21
22
|
public string messageToSendOnInit = "";
|
|
22
23
|
public bool sendMessageOnFinish = false;
|
|
23
24
|
public string messageToSendOnFinish = "";
|
|
24
|
-
|
|
25
|
+
|
|
26
|
+
public Quest(QuestSO questSO)
|
|
25
27
|
{
|
|
26
|
-
this.
|
|
28
|
+
this.questSO = questSO;
|
|
27
29
|
this.state = QuestState.REQUIREMENTS_NOT_MET;
|
|
28
|
-
this.
|
|
29
|
-
this.
|
|
30
|
-
this.messageChannel = questInfo.messageChannel;
|
|
30
|
+
this.questStepStates = new QuestStepState[this.questSO.questSteps.Length];
|
|
31
|
+
this.messageChannel = questSO.messageChannel;
|
|
31
32
|
//init
|
|
32
|
-
this.sendMessageOnInitialization =
|
|
33
|
-
this.messageToSendOnInit =
|
|
33
|
+
this.sendMessageOnInitialization = questSO.sendMessageOnInitialization;
|
|
34
|
+
this.messageToSendOnInit = questSO.messageToSendOnInitialization;
|
|
34
35
|
//finish
|
|
35
|
-
this.sendMessageOnFinish =
|
|
36
|
-
this.messageToSendOnFinish =
|
|
36
|
+
this.sendMessageOnFinish = questSO.sendMessageOnFinish;
|
|
37
|
+
this.messageToSendOnFinish = questSO.messageToSendOnFinish;
|
|
37
38
|
for (int i = 0; i < questStepStates.Length; i++)
|
|
38
39
|
{
|
|
39
40
|
questStepStates[i] = new QuestStepState();
|
|
40
41
|
}
|
|
41
42
|
}
|
|
42
43
|
|
|
43
|
-
public Quest(
|
|
44
|
+
public Quest(QuestSO questQuestSo, QuestState questState, int currentQuestStepIndex,
|
|
44
45
|
QuestStepState[] questStepStates)
|
|
45
46
|
{
|
|
46
|
-
this.
|
|
47
|
+
this.questSO = questQuestSo;
|
|
47
48
|
this.state = questState;
|
|
48
|
-
this.currentQuestStepIndex = currentQuestStepIndex;
|
|
49
|
-
currentStep = this.currentQuestStepIndex;
|
|
50
49
|
this.questStepStates = questStepStates;
|
|
51
50
|
|
|
52
|
-
//
|
|
53
|
-
//
|
|
54
|
-
if (this.questStepStates.Length != this.
|
|
51
|
+
//if the quest step states and prefabs are different lengths,
|
|
52
|
+
//something has changed during development and the saved data is out of sync.
|
|
53
|
+
if (this.questStepStates.Length != this.questSO.questSteps.Length)
|
|
55
54
|
{
|
|
56
55
|
Debug.LogWarning("Quest Step Prefabs and Quest Step States are "
|
|
57
56
|
+ "of different lengths. This indicates something changed "
|
|
58
57
|
+ "with the QuestInfo and the saved data is now out of sync. "
|
|
59
|
-
+ "Reset your data - as this might cause issues. QuestId: " + this.
|
|
58
|
+
+ "Reset your data - as this might cause issues. QuestId: " + this.questSO.id);
|
|
60
59
|
}
|
|
61
60
|
}
|
|
62
61
|
|
|
63
62
|
|
|
64
|
-
public void MoveToNextStep()
|
|
65
|
-
{
|
|
66
|
-
currentQuestStepIndex++;
|
|
67
|
-
currentStep = currentQuestStepIndex;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
public bool CurrentStepExists()
|
|
71
|
-
{
|
|
72
|
-
return (currentQuestStepIndex < info.questStepPrefabs.Length);
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
public void InstantiateCurrentQuestStep(Transform parentTransform)
|
|
76
|
-
{
|
|
77
|
-
GameObject questStepPrefab = GetCurrentQuestStepPrefab();
|
|
78
|
-
if (questStepPrefab != null)
|
|
79
|
-
{
|
|
80
|
-
QuestStep questStep = Object.Instantiate<GameObject>(questStepPrefab, parentTransform)
|
|
81
|
-
.GetComponent<QuestStep>();
|
|
82
|
-
questStep.InitializeQuestStep(info.id, currentQuestStepIndex,
|
|
83
|
-
questStepStates[currentQuestStepIndex].state);
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
private GameObject GetCurrentQuestStepPrefab()
|
|
88
|
-
{
|
|
89
|
-
GameObject questStepPrefab = null;
|
|
90
|
-
if (CurrentStepExists())
|
|
91
|
-
{
|
|
92
|
-
questStepPrefab = info.questStepPrefabs[currentQuestStepIndex];
|
|
93
|
-
}
|
|
94
|
-
else
|
|
95
|
-
{
|
|
96
|
-
Debug.LogWarning("Tried to get quest step prefab, but stepIndex was out of range indicating that "
|
|
97
|
-
+ "there's no current step: QuestId=" + info.id + ", stepIndex=" +
|
|
98
|
-
currentQuestStepIndex);
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
return questStepPrefab;
|
|
102
|
-
}
|
|
103
63
|
|
|
104
64
|
public void StoreQuestStepState(QuestStepState questStepState, int stepIndex)
|
|
105
65
|
{
|
|
@@ -110,13 +70,14 @@ namespace jeanf.questsystem
|
|
|
110
70
|
else
|
|
111
71
|
{
|
|
112
72
|
Debug.LogWarning("Tried to access quest step data, but stepIndex was out of range: "
|
|
113
|
-
+ "Quest Id = " +
|
|
73
|
+
+ "Quest Id = " + questSO.id + ", Step Index = " + stepIndex);
|
|
114
74
|
}
|
|
115
75
|
}
|
|
116
76
|
|
|
117
|
-
public QuestData GetQuestData()
|
|
118
|
-
{
|
|
119
|
-
|
|
120
|
-
}
|
|
77
|
+
//public QuestData GetQuestData()
|
|
78
|
+
//{
|
|
79
|
+
// return new QuestData(state, currentQuestStepIndex, questStepStates);
|
|
80
|
+
//}
|
|
81
|
+
|
|
121
82
|
}
|
|
122
83
|
}
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
using System.Collections;
|
|
2
2
|
using System.Collections.Generic;
|
|
3
|
+
using GraphProcessor;
|
|
3
4
|
using UnityEngine;
|
|
4
5
|
|
|
5
6
|
namespace jeanf.questsystem
|
|
6
7
|
{
|
|
8
|
+
// this is the information needed to save the quest
|
|
7
9
|
[System.Serializable]
|
|
8
10
|
public class QuestData
|
|
9
11
|
{
|
|
12
|
+
// old constructor (linear structure)
|
|
10
13
|
public QuestState state;
|
|
11
14
|
public int questStepIndex;
|
|
12
15
|
public QuestStepState[] questStepStates;
|
|
@@ -17,5 +20,16 @@ namespace jeanf.questsystem
|
|
|
17
20
|
this.questStepIndex = questStepIndex;
|
|
18
21
|
this.questStepStates = questStepStates;
|
|
19
22
|
}
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
// new constructor (tree structure)
|
|
26
|
+
public BaseGraph QuestTree;
|
|
27
|
+
public Dictionary<string, QuestStep> QuestStepDictionary;
|
|
28
|
+
|
|
29
|
+
public QuestData(BaseGraph QuestTree, Dictionary<string, QuestStep> QuestStepDictionary)
|
|
30
|
+
{
|
|
31
|
+
this.QuestTree = QuestTree;
|
|
32
|
+
this.QuestStepDictionary = QuestStepDictionary;
|
|
33
|
+
}
|
|
20
34
|
}
|
|
21
35
|
}
|
|
@@ -5,6 +5,7 @@ using UnityEngine;
|
|
|
5
5
|
using jeanf.propertyDrawer;
|
|
6
6
|
using jeanf.validationTools;
|
|
7
7
|
|
|
8
|
+
|
|
8
9
|
namespace jeanf.questsystem
|
|
9
10
|
{
|
|
10
11
|
public class QuestItem : MonoBehaviour, IDebugBehaviour, IValidatable
|
|
@@ -20,7 +21,10 @@ namespace jeanf.questsystem
|
|
|
20
21
|
[SerializeField] private bool _startQuestOnEnable = false;
|
|
21
22
|
|
|
22
23
|
[Tooltip("Visual feedback for the quest state")] [Header("Quest")] [SerializeField]
|
|
23
|
-
private
|
|
24
|
+
private QuestSO questSO;
|
|
25
|
+
private Dictionary<string, QuestStep> stepMap = new Dictionary<string, QuestStep>();
|
|
26
|
+
private Dictionary<string, QuestStep> activeSteps = new Dictionary<string, QuestStep>();
|
|
27
|
+
|
|
24
28
|
|
|
25
29
|
[ReadOnly] [Range(0, 1)] [SerializeField]
|
|
26
30
|
private float progress = 0.0f;
|
|
@@ -41,114 +45,34 @@ namespace jeanf.questsystem
|
|
|
41
45
|
[Header("Broadcasting on:")] [SerializeField] [Validation("A reference to the QuestRequirementCheck SO is required")]
|
|
42
46
|
private StringEventChannelSO requirementCheck;
|
|
43
47
|
|
|
48
|
+
#region Awake/Enable/Disable
|
|
44
49
|
private void Awake()
|
|
45
50
|
{
|
|
46
|
-
questId =
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
#if UNITY_EDITOR
|
|
50
|
-
public void OnValidate()
|
|
51
|
-
{
|
|
52
|
-
ValidityCheck();
|
|
53
|
-
}
|
|
54
|
-
#endif
|
|
55
|
-
|
|
56
|
-
private void ValidityCheck()
|
|
57
|
-
{
|
|
58
|
-
const string searching = "attempting to find";
|
|
59
|
-
const string _ = "Quests/Channels"; // search target
|
|
60
|
-
const string searchLocation = "the resources folder";
|
|
61
|
-
const string readInstructions = "please read the package instruction for further help";
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
var validityCheck = true;
|
|
65
|
-
var invalidObjects = new List<object>();
|
|
66
|
-
var errorMessages = new List<string>();
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
if (QuestInitialCheck == null)
|
|
70
|
-
{
|
|
71
|
-
if (isDebug) Debug.Log($"{searching} {_}/QuestInitialCheck in {searchLocation} ", this);
|
|
72
|
-
QuestInitialCheck = Resources.Load<StringEventChannelSO>($"{_}/QuestInitialCheck");
|
|
73
|
-
if (QuestProgress == null)
|
|
74
|
-
{
|
|
75
|
-
errorMessages.Add($"{_}/QuestInitialCheck is not in {searchLocation} {readInstructions}");
|
|
76
|
-
validityCheck = false;
|
|
77
|
-
invalidObjects.Add(QuestProgress);
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
if (QuestProgress == null)
|
|
83
|
-
{
|
|
84
|
-
if (isDebug) Debug.Log($"{searching} {_}/QuestsProgressChannel in {searchLocation} ", this);
|
|
85
|
-
QuestProgress = Resources.Load<StringFloatEventChannelSO>($"{_}/QuestsProgressChannel");
|
|
86
|
-
if (QuestProgress == null)
|
|
87
|
-
{
|
|
88
|
-
errorMessages.Add($"{_}/QuestsProgressChannel is not in {searchLocation} {readInstructions}");
|
|
89
|
-
validityCheck = false;
|
|
90
|
-
invalidObjects.Add(QuestProgress);
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
if (StartQuestEventChannel == null)
|
|
51
|
+
questId = questSO.id;
|
|
52
|
+
for (int i = 0; i < questSO.questSteps.Length; i++)
|
|
96
53
|
{
|
|
97
|
-
if (
|
|
98
|
-
StartQuestEventChannel = Resources.Load<StringEventChannelSO>($"{_}/StartQuestEventChannel");
|
|
99
|
-
if (StartQuestEventChannel == null)
|
|
54
|
+
if (!stepMap.ContainsKey(questSO.questSteps[i].StepId))
|
|
100
55
|
{
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
invalidObjects.Add(StartQuestEventChannel);
|
|
56
|
+
Debug.Log($"id on awake {questSO.questSteps[i].StepId}, added to {this.name}'s dictionary", this);
|
|
57
|
+
stepMap.Add(questSO.questSteps[i].StepId, questSO.questSteps[i]);
|
|
104
58
|
}
|
|
105
59
|
}
|
|
106
60
|
|
|
107
|
-
|
|
108
|
-
if (requirementCheck == null)
|
|
61
|
+
foreach (QuestStep step in stepMap.Values)
|
|
109
62
|
{
|
|
110
|
-
if (
|
|
111
|
-
requirementCheck = Resources.Load<StringEventChannelSO>($"{_}/QuestRequirementCheck");
|
|
112
|
-
if (requirementCheck == null)
|
|
63
|
+
if (step.isRootStep)
|
|
113
64
|
{
|
|
114
|
-
|
|
115
|
-
validityCheck = false;
|
|
116
|
-
invalidObjects.Add(requirementCheck);
|
|
65
|
+
InstantiateQuestStep(step.StepId);
|
|
117
66
|
}
|
|
118
67
|
}
|
|
119
|
-
|
|
120
|
-
IsValid = validityCheck;
|
|
121
|
-
|
|
122
|
-
if(!IsValid) return;
|
|
123
|
-
if (IsValid && !Application.isPlaying) return;
|
|
124
|
-
|
|
125
|
-
for(var i = 0 ; i < invalidObjects.Count ; i++)
|
|
126
|
-
{
|
|
127
|
-
Debug.LogError($"Error: {errorMessages[i]} " , this.gameObject);
|
|
128
|
-
}
|
|
129
68
|
}
|
|
130
69
|
|
|
131
70
|
private void OnEnable()
|
|
132
71
|
{
|
|
133
72
|
Subscribe();
|
|
134
|
-
|
|
135
|
-
Init(questId);
|
|
136
|
-
}
|
|
137
73
|
|
|
138
|
-
|
|
139
|
-
{
|
|
140
|
-
|
|
141
|
-
Debug.Log($"Quest [{id}]: _startQuestOnEnable value is: [{_startQuestOnEnable}]");
|
|
142
|
-
if (!_startQuestOnEnable) return;
|
|
143
|
-
RequestQuestStart(id);
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
private void InitialCheckFromQuestManager( string id)
|
|
147
|
-
{
|
|
148
|
-
Debug.Log($"Initial check for quest with id: [{id}], it is in the following state: [{currentQuestState}]");
|
|
149
|
-
Init(id);
|
|
74
|
+
Init(questId);
|
|
150
75
|
}
|
|
151
|
-
|
|
152
76
|
private void OnDisable() => Unsubscribe();
|
|
153
77
|
private void OnDestroy() => Unsubscribe();
|
|
154
78
|
|
|
@@ -159,6 +83,9 @@ namespace jeanf.questsystem
|
|
|
159
83
|
QuestProgress.OnEventRaised += UpdateProgress;
|
|
160
84
|
GameEventsManager.instance.questEvents.onQuestStateChange += QuestStateChange;
|
|
161
85
|
GameEventsManager.instance.inputEvents.onSubmitPressed += UpdateState;
|
|
86
|
+
QuestStep.sendNextStepId += InstantiateQuestStep;
|
|
87
|
+
QuestStep.stepCompleted += DestroyQuestStep;
|
|
88
|
+
|
|
162
89
|
}
|
|
163
90
|
|
|
164
91
|
private void Unsubscribe()
|
|
@@ -168,8 +95,50 @@ namespace jeanf.questsystem
|
|
|
168
95
|
QuestProgress.OnEventRaised -= UpdateProgress;
|
|
169
96
|
GameEventsManager.instance.questEvents.onQuestStateChange -= QuestStateChange;
|
|
170
97
|
GameEventsManager.instance.inputEvents.onSubmitPressed -= UpdateState;
|
|
98
|
+
QuestStep.sendNextStepId -= InstantiateQuestStep;
|
|
99
|
+
QuestStep.stepCompleted -= DestroyQuestStep;
|
|
100
|
+
|
|
101
|
+
}
|
|
102
|
+
#endregion
|
|
103
|
+
|
|
104
|
+
#region Step Instantiation & Destroy
|
|
105
|
+
public void InstantiateQuestStep(string id)
|
|
106
|
+
{
|
|
107
|
+
|
|
108
|
+
if (stepMap.ContainsKey(id))
|
|
109
|
+
{
|
|
110
|
+
activeSteps.Add(id, Instantiate(stepMap[id]));
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
public void DestroyQuestStep(string id)
|
|
115
|
+
{
|
|
116
|
+
if (activeSteps.ContainsKey(id))
|
|
117
|
+
{
|
|
118
|
+
Destroy(activeSteps[id].gameObject);
|
|
119
|
+
activeSteps.Remove(id);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
#endregion
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
#region quest process
|
|
126
|
+
private void Init(string id)
|
|
127
|
+
{
|
|
128
|
+
|
|
129
|
+
Debug.Log($"Quest [{id}]: _startQuestOnEnable value is: [{_startQuestOnEnable}]");
|
|
130
|
+
if (!_startQuestOnEnable) return;
|
|
131
|
+
RequestQuestStart(id);
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
private void InitialCheckFromQuestManager( string id)
|
|
135
|
+
{
|
|
136
|
+
Debug.Log($"Initial check for quest with id: [{id}], it is in the following state: [{currentQuestState}]");
|
|
137
|
+
Init(id);
|
|
171
138
|
}
|
|
172
139
|
|
|
140
|
+
|
|
141
|
+
|
|
173
142
|
private void UpdateState()
|
|
174
143
|
{
|
|
175
144
|
if (isDebug) Debug.Log($"Updating State...");
|
|
@@ -216,7 +185,7 @@ namespace jeanf.questsystem
|
|
|
216
185
|
private void QuestStateChange(Quest quest)
|
|
217
186
|
{
|
|
218
187
|
// only update the quest state if this point has the corresponding quest
|
|
219
|
-
if (quest.
|
|
188
|
+
if (quest.questSO.id.Equals(questId))
|
|
220
189
|
{
|
|
221
190
|
currentQuestState = quest.state;
|
|
222
191
|
UpdateState();
|
|
@@ -240,6 +209,91 @@ namespace jeanf.questsystem
|
|
|
240
209
|
AllClear(true);
|
|
241
210
|
if(isDebug) Debug.Log($"Quest start was requested for quest {id}.", this);
|
|
242
211
|
}
|
|
212
|
+
#endregion
|
|
213
|
+
|
|
214
|
+
#region validation tools
|
|
215
|
+
|
|
216
|
+
#if UNITY_EDITOR
|
|
217
|
+
public void OnValidate()
|
|
218
|
+
{
|
|
219
|
+
ValidityCheck();
|
|
220
|
+
}
|
|
221
|
+
#endif
|
|
222
|
+
|
|
223
|
+
private void ValidityCheck()
|
|
224
|
+
{
|
|
225
|
+
const string searching = "attempting to find";
|
|
226
|
+
const string _ = "Quests/Channels"; // search target
|
|
227
|
+
const string searchLocation = "the resources folder";
|
|
228
|
+
const string readInstructions = "please read the package instruction for further help";
|
|
229
|
+
|
|
230
|
+
|
|
231
|
+
var validityCheck = true;
|
|
232
|
+
var invalidObjects = new List<object>();
|
|
233
|
+
var errorMessages = new List<string>();
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
if (QuestInitialCheck == null)
|
|
237
|
+
{
|
|
238
|
+
if (isDebug) Debug.Log($"{searching} {_}/QuestInitialCheck in {searchLocation} ", this);
|
|
239
|
+
QuestInitialCheck = Resources.Load<StringEventChannelSO>($"{_}/QuestInitialCheck");
|
|
240
|
+
if (QuestProgress == null)
|
|
241
|
+
{
|
|
242
|
+
errorMessages.Add($"{_}/QuestInitialCheck is not in {searchLocation} {readInstructions}");
|
|
243
|
+
validityCheck = false;
|
|
244
|
+
invalidObjects.Add(QuestProgress);
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
if (QuestProgress == null)
|
|
250
|
+
{
|
|
251
|
+
if (isDebug) Debug.Log($"{searching} {_}/QuestsProgressChannel in {searchLocation} ", this);
|
|
252
|
+
QuestProgress = Resources.Load<StringFloatEventChannelSO>($"{_}/QuestsProgressChannel");
|
|
253
|
+
if (QuestProgress == null)
|
|
254
|
+
{
|
|
255
|
+
errorMessages.Add($"{_}/QuestsProgressChannel is not in {searchLocation} {readInstructions}");
|
|
256
|
+
validityCheck = false;
|
|
257
|
+
invalidObjects.Add(QuestProgress);
|
|
258
|
+
}
|
|
259
|
+
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
if (StartQuestEventChannel == null)
|
|
263
|
+
{
|
|
264
|
+
if (isDebug) Debug.Log($"{searching} {_}/StartQuestEventChannel in {searchLocation}", this);
|
|
265
|
+
StartQuestEventChannel = Resources.Load<StringEventChannelSO>($"{_}/StartQuestEventChannel");
|
|
266
|
+
if (StartQuestEventChannel == null)
|
|
267
|
+
{
|
|
268
|
+
errorMessages.Add($"{_}/StartQuestEventChannel is not {searchLocation} {readInstructions}");
|
|
269
|
+
validityCheck = false;
|
|
270
|
+
invalidObjects.Add(StartQuestEventChannel);
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
|
|
275
|
+
if (requirementCheck == null)
|
|
276
|
+
{
|
|
277
|
+
if (isDebug) Debug.Log($"{searching} {_}/QuestRequirementCheck in {searchLocation}", this);
|
|
278
|
+
requirementCheck = Resources.Load<StringEventChannelSO>($"{_}/QuestRequirementCheck");
|
|
279
|
+
if (requirementCheck == null)
|
|
280
|
+
{
|
|
281
|
+
errorMessages.Add($"{_}/QuestRequirementCheck is not {searchLocation} {readInstructions}");
|
|
282
|
+
validityCheck = false;
|
|
283
|
+
invalidObjects.Add(requirementCheck);
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
IsValid = validityCheck;
|
|
288
|
+
|
|
289
|
+
if (!IsValid) return;
|
|
290
|
+
if (IsValid && !Application.isPlaying) return;
|
|
243
291
|
|
|
292
|
+
for (var i = 0; i < invalidObjects.Count; i++)
|
|
293
|
+
{
|
|
294
|
+
Debug.LogError($"Error: {errorMessages[i]} ", this.gameObject);
|
|
295
|
+
}
|
|
296
|
+
}
|
|
297
|
+
#endregion
|
|
244
298
|
}
|
|
245
299
|
}
|