net.dreditor.triggers 0.1.6 → 0.1.7

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.
Files changed (58) hide show
  1. package/.attestation.p7m +0 -0
  2. package/Actuator.cs +46 -46
  3. package/Actuator.cs.meta +11 -11
  4. package/ActuatorBehaviourBase.cs +61 -61
  5. package/ActuatorBehaviourBase.cs.meta +11 -11
  6. package/DREditor.Triggers.asmdef +17 -17
  7. package/DREditor.Triggers.asmdef.meta +7 -7
  8. package/DialogueSubsequent.cs +112 -112
  9. package/DialogueSubsequent.cs.meta +11 -11
  10. package/EventTrigger.cs +48 -48
  11. package/EventTrigger.cs.meta +11 -11
  12. package/FlagActuatorData.cs +59 -59
  13. package/FlagActuatorData.cs.meta +11 -11
  14. package/GenericActuator.cs +47 -47
  15. package/GenericActuator.cs.meta +11 -11
  16. package/GenericSubsequent.cs +23 -23
  17. package/GenericSubsequent.cs.meta +11 -11
  18. package/GenericTriggerBase.cs +52 -52
  19. package/GenericTriggerBase.cs.meta +11 -11
  20. package/HitboxActuator.cs +81 -81
  21. package/HitboxActuator.cs.meta +11 -11
  22. package/HitboxActuatorData.cs +45 -45
  23. package/HitboxActuatorData.cs.meta +11 -11
  24. package/IActuatorBehaviour.cs +20 -20
  25. package/IActuatorBehaviour.cs.meta +11 -11
  26. package/IActuatorConvert.cs +22 -22
  27. package/IActuatorConvert.cs.meta +11 -11
  28. package/IEventTriggerSaver.cs +21 -21
  29. package/IEventTriggerSaver.cs.meta +11 -11
  30. package/ISubsequentBehaviour.cs +14 -14
  31. package/ISubsequentBehaviour.cs.meta +11 -11
  32. package/ISubsequentConvert.cs +24 -24
  33. package/ISubsequentConvert.cs.meta +11 -11
  34. package/LDialogueSubsequent.cs +87 -87
  35. package/LDialogueSubsequent.cs.meta +11 -11
  36. package/LocalDialogueSubsequentData.cs +54 -54
  37. package/LocalDialogueSubsequentData.cs.meta +11 -11
  38. package/MovePlayerSubsequent.cs +141 -141
  39. package/MovePlayerSubsequent.cs.meta +11 -11
  40. package/OLFlagActuator.cs +66 -66
  41. package/OLFlagActuator.cs.meta +11 -11
  42. package/OnLoadActuator.cs +65 -65
  43. package/OnLoadActuator.cs.meta +11 -11
  44. package/PositionEventSubsequentData.cs +84 -84
  45. package/PositionEventSubsequentData.cs.meta +11 -11
  46. package/{Samples → Samples~}/Transition_Finished_Subscriber.prefab +137 -137
  47. package/{Samples → Samples~}/Transition_Finished_Subscriber.prefab.meta +7 -7
  48. package/ScriptableObjectsSubsequentData.cs +57 -57
  49. package/ScriptableObjectsSubsequentData.cs.meta +11 -11
  50. package/SimpleActuatorData.cs +28 -28
  51. package/SimpleActuatorData.cs.meta +11 -11
  52. package/Subsequent.cs +43 -43
  53. package/Subsequent.cs.meta +11 -11
  54. package/TransitionFinishedSubscriber.cs +39 -39
  55. package/TransitionFinishedSubscriber.cs.meta +11 -11
  56. package/package.json +41 -36
  57. package/package.json.meta +7 -7
  58. package/Samples.meta +0 -8
@@ -1,11 +1,11 @@
1
- fileFormatVersion: 2
2
- guid: e6c01400f67de7e4fa76660596340e4f
3
- MonoImporter:
4
- externalObjects: {}
5
- serializedVersion: 2
6
- defaultReferences: []
7
- executionOrder: 0
8
- icon: {instanceID: 0}
9
- userData:
10
- assetBundleName:
11
- assetBundleVariant:
1
+ fileFormatVersion: 2
2
+ guid: e6c01400f67de7e4fa76660596340e4f
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -1,46 +1,46 @@
1
- //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
- using System;
3
- using UnityEngine;
4
-
5
- namespace DREditor.Triggers
6
- {
7
- /// <summary>
8
- ///
9
- /// </summary>
10
- [Serializable]
11
- public class HitboxActuatorData : GenericActuator, IActuatorConvert
12
- {
13
- /// <summary>
14
- ///
15
- /// </summary>
16
- [Tooltip("")]
17
- public Vector3 HitboxSize;
18
-
19
-
20
- /// <summary>
21
- ///
22
- /// </summary>
23
- /// <param name="HitboxSize"></param>
24
- public virtual void SetHitboxSize(Vector3 HitboxSize) => this.HitboxSize = HitboxSize;
25
-
26
-
27
- /// <inheritdoc/>
28
- public virtual bool CanConvert(GenericActuator oldActuator) => ((Actuator)oldActuator).HitBoxSize != Vector3.zero;
29
-
30
- /// <inheritdoc/>
31
- public virtual void Convert(ref GenericActuator genericActuator, GenericActuator oldActuator)
32
- {
33
- var newData = new HitboxActuatorData(oldActuator.Type, oldActuator.Triggered, oldActuator.position)
34
- {
35
- HitboxSize = ((Actuator)oldActuator).HitBoxSize
36
- };
37
-
38
- genericActuator = newData;
39
- }
40
-
41
-
42
- public HitboxActuatorData() { }
43
-
44
- public HitboxActuatorData(string Type, bool Triggered, Vector3 position) : base(Type, Triggered, position) { }
45
- }
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+ using System;
3
+ using UnityEngine;
4
+
5
+ namespace DREditor.Triggers
6
+ {
7
+ /// <summary>
8
+ ///
9
+ /// </summary>
10
+ [Serializable]
11
+ public class HitboxActuatorData : GenericActuator, IActuatorConvert
12
+ {
13
+ /// <summary>
14
+ ///
15
+ /// </summary>
16
+ [Tooltip("")]
17
+ public Vector3 HitboxSize;
18
+
19
+
20
+ /// <summary>
21
+ ///
22
+ /// </summary>
23
+ /// <param name="HitboxSize"></param>
24
+ public virtual void SetHitboxSize(Vector3 HitboxSize) => this.HitboxSize = HitboxSize;
25
+
26
+
27
+ /// <inheritdoc/>
28
+ public virtual bool CanConvert(GenericActuator oldActuator) => ((Actuator)oldActuator).HitBoxSize != Vector3.zero;
29
+
30
+ /// <inheritdoc/>
31
+ public virtual void Convert(ref GenericActuator genericActuator, GenericActuator oldActuator)
32
+ {
33
+ var newData = new HitboxActuatorData(oldActuator.Type, oldActuator.Triggered, oldActuator.position)
34
+ {
35
+ HitboxSize = ((Actuator)oldActuator).HitBoxSize
36
+ };
37
+
38
+ genericActuator = newData;
39
+ }
40
+
41
+
42
+ public HitboxActuatorData() { }
43
+
44
+ public HitboxActuatorData(string Type, bool Triggered, Vector3 position) : base(Type, Triggered, position) { }
45
+ }
46
46
  }
@@ -1,11 +1,11 @@
1
- fileFormatVersion: 2
2
- guid: ba0dbea821ee8274e976dc7ae82ab74e
3
- MonoImporter:
4
- externalObjects: {}
5
- serializedVersion: 2
6
- defaultReferences: []
7
- executionOrder: 0
8
- icon: {instanceID: 0}
9
- userData:
10
- assetBundleName:
11
- assetBundleVariant:
1
+ fileFormatVersion: 2
2
+ guid: ba0dbea821ee8274e976dc7ae82ab74e
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -1,21 +1,21 @@
1
- //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
-
3
- namespace DREditor.Triggers
4
- {
5
- /// <summary>
6
- ///
7
- /// </summary>
8
- public interface IActuatorBehaviour : IEventTriggerSaver
9
- {
10
- /// <summary>
11
- ///
12
- /// </summary>
13
- void Call();
14
-
15
- /// <summary>
16
- ///
17
- /// </summary>
18
- /// <returns></returns>
19
- ISubsequentBehaviour[] GetSubsequents();
20
- }
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+
3
+ namespace DREditor.Triggers
4
+ {
5
+ /// <summary>
6
+ ///
7
+ /// </summary>
8
+ public interface IActuatorBehaviour : IEventTriggerSaver
9
+ {
10
+ /// <summary>
11
+ ///
12
+ /// </summary>
13
+ void Call();
14
+
15
+ /// <summary>
16
+ ///
17
+ /// </summary>
18
+ /// <returns></returns>
19
+ ISubsequentBehaviour[] GetSubsequents();
20
+ }
21
21
  }
@@ -1,11 +1,11 @@
1
- fileFormatVersion: 2
2
- guid: 7287bc795e5c545408a43d83e96f983b
3
- MonoImporter:
4
- externalObjects: {}
5
- serializedVersion: 2
6
- defaultReferences: []
7
- executionOrder: 0
8
- icon: {instanceID: 0}
9
- userData:
10
- assetBundleName:
11
- assetBundleVariant:
1
+ fileFormatVersion: 2
2
+ guid: 7287bc795e5c545408a43d83e96f983b
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -1,23 +1,23 @@
1
- //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
- namespace DREditor.Triggers
3
- {
4
- /// <summary>
5
- ///
6
- /// </summary>
7
- public interface IActuatorConvert
8
- {
9
- /// <summary>
10
- ///
11
- /// </summary>
12
- /// <param name="genericActuator"></param>
13
- /// <param name="oldActuator"></param>
14
- void Convert(ref GenericActuator genericActuator, GenericActuator oldActuator);
15
-
16
- /// <summary>
17
- ///
18
- /// </summary>
19
- /// <param name="genericActuator"></param>
20
- /// <returns></returns>
21
- bool CanConvert(GenericActuator genericActuator);
22
- }
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+ namespace DREditor.Triggers
3
+ {
4
+ /// <summary>
5
+ ///
6
+ /// </summary>
7
+ public interface IActuatorConvert
8
+ {
9
+ /// <summary>
10
+ ///
11
+ /// </summary>
12
+ /// <param name="genericActuator"></param>
13
+ /// <param name="oldActuator"></param>
14
+ void Convert(ref GenericActuator genericActuator, GenericActuator oldActuator);
15
+
16
+ /// <summary>
17
+ ///
18
+ /// </summary>
19
+ /// <param name="genericActuator"></param>
20
+ /// <returns></returns>
21
+ bool CanConvert(GenericActuator genericActuator);
22
+ }
23
23
  }
@@ -1,11 +1,11 @@
1
- fileFormatVersion: 2
2
- guid: 965b259e73e366c41b9cb36bab1c1099
3
- MonoImporter:
4
- externalObjects: {}
5
- serializedVersion: 2
6
- defaultReferences: []
7
- executionOrder: 0
8
- icon: {instanceID: 0}
9
- userData:
10
- assetBundleName:
11
- assetBundleVariant:
1
+ fileFormatVersion: 2
2
+ guid: 965b259e73e366c41b9cb36bab1c1099
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -1,22 +1,22 @@
1
- //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
-
3
- namespace DREditor.Triggers
4
- {
5
- /// <summary>
6
- ///
7
- /// </summary>
8
- public interface IEventTriggerSaver
9
- {
10
- /// <summary>
11
- ///
12
- /// </summary>
13
- /// <returns></returns>
14
- object Save();
15
-
16
- /// <summary>
17
- ///
18
- /// </summary>
19
- /// <param name="ob"></param>
20
- void Load(object ob);
21
- }
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+
3
+ namespace DREditor.Triggers
4
+ {
5
+ /// <summary>
6
+ ///
7
+ /// </summary>
8
+ public interface IEventTriggerSaver
9
+ {
10
+ /// <summary>
11
+ ///
12
+ /// </summary>
13
+ /// <returns></returns>
14
+ object Save();
15
+
16
+ /// <summary>
17
+ ///
18
+ /// </summary>
19
+ /// <param name="ob"></param>
20
+ void Load(object ob);
21
+ }
22
22
  }
@@ -1,11 +1,11 @@
1
- fileFormatVersion: 2
2
- guid: 3e8b300c4c5d37a489d60a714526f81e
3
- MonoImporter:
4
- externalObjects: {}
5
- serializedVersion: 2
6
- defaultReferences: []
7
- executionOrder: 0
8
- icon: {instanceID: 0}
9
- userData:
10
- assetBundleName:
11
- assetBundleVariant:
1
+ fileFormatVersion: 2
2
+ guid: 3e8b300c4c5d37a489d60a714526f81e
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -1,15 +1,15 @@
1
- //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
-
3
- namespace DREditor.Triggers
4
- {
5
- /// <summary>
6
- ///
7
- /// </summary>
8
- public interface ISubsequentBehaviour : IEventTriggerSaver
9
- {
10
- /// <summary>
11
- ///
12
- /// </summary>
13
- void Call();
14
- }
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+
3
+ namespace DREditor.Triggers
4
+ {
5
+ /// <summary>
6
+ ///
7
+ /// </summary>
8
+ public interface ISubsequentBehaviour : IEventTriggerSaver
9
+ {
10
+ /// <summary>
11
+ ///
12
+ /// </summary>
13
+ void Call();
14
+ }
15
15
  }
@@ -1,11 +1,11 @@
1
- fileFormatVersion: 2
2
- guid: 162923a1cb7a468499773e9bfecc005e
3
- MonoImporter:
4
- externalObjects: {}
5
- serializedVersion: 2
6
- defaultReferences: []
7
- executionOrder: 0
8
- icon: {instanceID: 0}
9
- userData:
10
- assetBundleName:
11
- assetBundleVariant:
1
+ fileFormatVersion: 2
2
+ guid: 162923a1cb7a468499773e9bfecc005e
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -1,25 +1,25 @@
1
- //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
- using System.Collections.Generic;
3
-
4
- namespace DREditor.Triggers
5
- {
6
- /// <summary>
7
- ///
8
- /// </summary>
9
- public interface ISubsequentConvert
10
- {
11
- /// <summary>
12
- ///
13
- /// </summary>
14
- /// <param name="genericSubsequents"></param>
15
- /// <param name="genericSubsequent"></param>
16
- void Convert(List<GenericSubsequent> genericSubsequents, GenericSubsequent genericSubsequent);
17
-
18
- /// <summary>
19
- ///
20
- /// </summary>
21
- /// <param name="genericSubsequent"></param>
22
- /// <returns></returns>
23
- bool CanConvert(GenericSubsequent genericSubsequent);
24
- }
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+ using System.Collections.Generic;
3
+
4
+ namespace DREditor.Triggers
5
+ {
6
+ /// <summary>
7
+ ///
8
+ /// </summary>
9
+ public interface ISubsequentConvert
10
+ {
11
+ /// <summary>
12
+ ///
13
+ /// </summary>
14
+ /// <param name="genericSubsequents"></param>
15
+ /// <param name="genericSubsequent"></param>
16
+ void Convert(List<GenericSubsequent> genericSubsequents, GenericSubsequent genericSubsequent);
17
+
18
+ /// <summary>
19
+ ///
20
+ /// </summary>
21
+ /// <param name="genericSubsequent"></param>
22
+ /// <returns></returns>
23
+ bool CanConvert(GenericSubsequent genericSubsequent);
24
+ }
25
25
  }
@@ -1,11 +1,11 @@
1
- fileFormatVersion: 2
2
- guid: afc708ca7e5e24e4baf798efac25a098
3
- MonoImporter:
4
- externalObjects: {}
5
- serializedVersion: 2
6
- defaultReferences: []
7
- executionOrder: 0
8
- icon: {instanceID: 0}
9
- userData:
10
- assetBundleName:
11
- assetBundleVariant:
1
+ fileFormatVersion: 2
2
+ guid: afc708ca7e5e24e4baf798efac25a098
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -1,88 +1,88 @@
1
- //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
- using DREditor.Dialogues;
3
- using DREditor.Dialogues.Loading;
4
- using DREditor.EventObjects;
5
- using DREditor.LocalDialogues;
6
- using DREditor.Services;
7
- using System;
8
- using System.Collections.Generic;
9
- using UnityEngine;
10
-
11
- namespace DREditor.Triggers
12
- {
13
- /// <summary>
14
- ///
15
- /// </summary>
16
- [ClassHeader(nameof(ISubsequentBehaviour) + ", " + nameof(IDialogueHolder) +
17
- "\n\n")]
18
- public class LDialogueSubsequent : MonoBehaviour, ISubsequentBehaviour, IDialogueHolder
19
- {
20
- /// <summary>
21
- ///
22
- /// </summary>
23
- [Tooltip("")]
24
- [SerializeField] protected LocalDialogue dialogue;
25
-
26
-
27
- /// <summary>
28
- ///
29
- /// </summary>
30
- protected LocalDialogueSubsequentData data = new();
31
-
32
-
33
- /// <inheritdoc/>
34
- public virtual void Call()
35
- {
36
- Dialogue[] dialogues = new Dialogue[1];
37
-
38
- dialogues[0] = ServiceLocator.GetService<LocalDialogueHandlerBase>().EvaluateDialogue(new List<LocalDialogue> { dialogue });
39
-
40
- if (dialogues[0] != null)
41
- {
42
- GameObject tryActor = GameObject.Find(dialogues[0].Lines[0].Speaker.FirstName);
43
-
44
- SelectableObject actor = null;
45
-
46
- if (tryActor)
47
- tryActor.GetComponentInChildren<SelectableObject>();
48
-
49
- if (ServiceLocator.HasService<IDialogueManager>())
50
- ServiceLocator.GetService<IDialogueManager>().StartDialogue(actor, dialogues);
51
- else
52
- UnityEngine.Debug.LogWarning($"ALERT: {typeof(IDialogueManager)} for Dialogue not found.");
53
- }
54
- else
55
- UnityEngine.Debug.LogWarning($"ALERT: The Evaluated Local Dialogue was null!");
56
- }
57
-
58
- /// <inheritdoc/>
59
- public virtual bool CheckIfSaveDialogue()
60
- => ServiceLocator.GetService<IDialogueManager>()
61
- .GetManagerComponent<DialogueLoadIdentifier>()
62
- .CheckDialogue<Line>(dialogue.dialogue)
63
- ||
64
- ServiceLocator.GetService<IDialogueManager>()
65
- .GetManagerComponent<DialogueLoadIdentifier>()
66
- .CheckDialogue<Line>(dialogue.dialogueIfFlagNotMet);
67
-
68
- /// <inheritdoc/>
69
- public virtual object Save()
70
- {
71
- LocalDialogueSubsequentData newData = (LocalDialogueSubsequentData)data.Clone();
72
-
73
- newData.SetType(GetType().Name);
74
-
75
- newData.SetLocalDialogue(dialogue);
76
-
77
- return newData;
78
- }
79
-
80
- /// <inheritdoc/>
81
- public virtual void Load(object ob)
82
- {
83
- data = (LocalDialogueSubsequentData)Convert.ChangeType(ob, typeof(LocalDialogueSubsequentData));
84
-
85
- dialogue = (LocalDialogue)data.localDialogue.Clone();
86
- }
87
- }
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+ using DREditor.Dialogues;
3
+ using DREditor.Dialogues.Loading;
4
+ using DREditor.EventObjects;
5
+ using DREditor.LocalDialogues;
6
+ using DREditor.Services;
7
+ using System;
8
+ using System.Collections.Generic;
9
+ using UnityEngine;
10
+
11
+ namespace DREditor.Triggers
12
+ {
13
+ /// <summary>
14
+ ///
15
+ /// </summary>
16
+ [ClassHeader(nameof(ISubsequentBehaviour) + ", " + nameof(IDialogueHolder) +
17
+ "\n\n")]
18
+ public class LDialogueSubsequent : MonoBehaviour, ISubsequentBehaviour, IDialogueHolder
19
+ {
20
+ /// <summary>
21
+ ///
22
+ /// </summary>
23
+ [Tooltip("")]
24
+ [SerializeField] protected LocalDialogue dialogue;
25
+
26
+
27
+ /// <summary>
28
+ ///
29
+ /// </summary>
30
+ protected LocalDialogueSubsequentData data = new();
31
+
32
+
33
+ /// <inheritdoc/>
34
+ public virtual void Call()
35
+ {
36
+ Dialogue[] dialogues = new Dialogue[1];
37
+
38
+ dialogues[0] = ServiceLocator.GetService<LocalDialogueHandlerBase>().EvaluateDialogue(new List<LocalDialogue> { dialogue });
39
+
40
+ if (dialogues[0] != null)
41
+ {
42
+ GameObject tryActor = GameObject.Find(dialogues[0].Lines[0].Speaker.FirstName);
43
+
44
+ SelectableObject actor = null;
45
+
46
+ if (tryActor)
47
+ tryActor.GetComponentInChildren<SelectableObject>();
48
+
49
+ if (ServiceLocator.HasService<IDialogueManager>())
50
+ ServiceLocator.GetService<IDialogueManager>().StartDialogue(actor, dialogues);
51
+ else
52
+ UnityEngine.Debug.LogWarning($"ALERT: {typeof(IDialogueManager)} for Dialogue not found.");
53
+ }
54
+ else
55
+ UnityEngine.Debug.LogWarning($"ALERT: The Evaluated Local Dialogue was null!");
56
+ }
57
+
58
+ /// <inheritdoc/>
59
+ public virtual bool CheckIfSaveDialogue()
60
+ => ServiceLocator.GetService<IDialogueManager>()
61
+ .GetManagerComponent<DialogueLoadIdentifier>()
62
+ .CheckDialogue<Line>(dialogue.dialogue)
63
+ ||
64
+ ServiceLocator.GetService<IDialogueManager>()
65
+ .GetManagerComponent<DialogueLoadIdentifier>()
66
+ .CheckDialogue<Line>(dialogue.dialogueIfFlagNotMet);
67
+
68
+ /// <inheritdoc/>
69
+ public virtual object Save()
70
+ {
71
+ LocalDialogueSubsequentData newData = (LocalDialogueSubsequentData)data.Clone();
72
+
73
+ newData.SetType(GetType().Name);
74
+
75
+ newData.SetLocalDialogue(dialogue);
76
+
77
+ return newData;
78
+ }
79
+
80
+ /// <inheritdoc/>
81
+ public virtual void Load(object ob)
82
+ {
83
+ data = (LocalDialogueSubsequentData)Convert.ChangeType(ob, typeof(LocalDialogueSubsequentData));
84
+
85
+ dialogue = (LocalDialogue)data.localDialogue.Clone();
86
+ }
87
+ }
88
88
  }