net.dreditor.dialoguemechanics 0.1.6 → 0.1.8

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 (105) hide show
  1. package/.attestation.p7m +0 -0
  2. package/CheckMenuAccess.cs +80 -80
  3. package/CheckMenuAccess.cs.meta +11 -11
  4. package/ClickIconLineHandler.cs +63 -63
  5. package/ClickIconLineHandler.cs.meta +11 -11
  6. package/DREditor.DialogueMechanics.asmdef +28 -28
  7. package/DREditor.DialogueMechanics.asmdef.meta +7 -7
  8. package/FastForwardMechanic.cs +222 -222
  9. package/FastForwardMechanic.cs.meta +11 -11
  10. package/InspectorGoToLineDebugger.cs +94 -94
  11. package/InspectorGoToLineDebugger.cs.meta +11 -11
  12. package/LoadToLineLastingItemImage.cs +30 -30
  13. package/LoadToLineLastingItemImage.cs.meta +11 -11
  14. package/OnDialogueFinishEvent.cs +34 -34
  15. package/OnDialogueFinishEvent.cs.meta +11 -11
  16. package/OnDialogueResolveEvent.cs +46 -46
  17. package/OnDialogueResolveEvent.cs.meta +11 -11
  18. package/PrepareCapturedFrame.cs +64 -64
  19. package/PrepareCapturedFrame.cs.meta +11 -11
  20. package/PrepareFastForwardLoadedLine.cs +71 -71
  21. package/PrepareFastForwardLoadedLine.cs.meta +11 -11
  22. package/ProtagHandler.cs +81 -81
  23. package/ProtagHandler.cs.meta +11 -11
  24. package/ProtagUILoadEndResolver.cs +42 -42
  25. package/ProtagUILoadEndResolver.cs.meta +11 -11
  26. package/ResolveBoolWithEvent.cs +53 -53
  27. package/ResolveBoolWithEvent.cs.meta +11 -11
  28. package/ResolveCapturedFrame.cs +76 -76
  29. package/ResolveCapturedFrame.cs.meta +11 -11
  30. package/{Samples → Samples~}/Animations/Auto Icon/Auto Icon.controller +214 -214
  31. package/{Samples → Samples~}/Animations/Auto Icon/Auto Icon.controller.meta +8 -8
  32. package/{Samples → Samples~}/Animations/Auto Icon/ShowAuto.anim +116 -116
  33. package/{Samples → Samples~}/Animations/Auto Icon/ShowAuto.anim.meta +8 -8
  34. package/{Samples → Samples~}/Animations/Auto Icon.meta +8 -8
  35. package/{Samples → Samples~}/Animations/Mouse Icon/Mouse Icon.controller +372 -372
  36. package/{Samples → Samples~}/Animations/Mouse Icon/Mouse Icon.controller.meta +8 -8
  37. package/{Samples → Samples~}/Animations/Mouse Icon/MouseFade.anim +134 -134
  38. package/{Samples → Samples~}/Animations/Mouse Icon/MouseFade.anim.meta +8 -8
  39. package/{Samples → Samples~}/Animations/Mouse Icon/MouseStart.anim +116 -116
  40. package/{Samples → Samples~}/Animations/Mouse Icon/MouseStart.anim.meta +8 -8
  41. package/{Samples → Samples~}/Animations/Mouse Icon.meta +8 -8
  42. package/{Samples → Samples~}/Animations.meta +8 -8
  43. package/{Samples → Samples~}/Check_Focus_On_Resolve.prefab +48 -48
  44. package/{Samples → Samples~}/Check_Focus_On_Resolve.prefab.meta +7 -7
  45. package/{Samples → Samples~}/Check_Menu_Access.prefab +51 -51
  46. package/{Samples → Samples~}/Check_Menu_Access.prefab.meta +7 -7
  47. package/{Samples → Samples~}/ClickIconVisible.asset +20 -20
  48. package/{Samples → Samples~}/ClickIconVisible.asset.meta +8 -8
  49. package/{Samples → Samples~}/Click_Icon_Line_Handler.prefab +48 -48
  50. package/{Samples → Samples~}/Click_Icon_Line_Handler.prefab.meta +7 -7
  51. package/{Samples → Samples~}/Dialogue_Auto_Icon_ETemplate.prefab +200 -200
  52. package/{Samples → Samples~}/Dialogue_Auto_Icon_ETemplate.prefab.meta +7 -7
  53. package/{Samples → Samples~}/Dialogue_Click_Icon_Shell.prefab +209 -209
  54. package/{Samples → Samples~}/Dialogue_Click_Icon_Shell.prefab.meta +7 -7
  55. package/{Samples → Samples~}/Dialogue_Mouse_Icon_ETemplate.prefab +172 -172
  56. package/{Samples → Samples~}/Dialogue_Mouse_Icon_ETemplate.prefab.meta +7 -7
  57. package/{Samples → Samples~}/FastForwardSpeed.asset +21 -21
  58. package/{Samples → Samples~}/FastForwardSpeed.asset.meta +8 -8
  59. package/{Samples → Samples~}/Fast_Forward_Mechanic.prefab +58 -58
  60. package/{Samples → Samples~}/Fast_Forward_Mechanic.prefab.meta +7 -7
  61. package/{Samples → Samples~}/Load_To_Line_Lasting_Item_Image.prefab +46 -46
  62. package/{Samples → Samples~}/Load_To_Line_Lasting_Item_Image.prefab.meta +7 -7
  63. package/{Samples → Samples~}/Prepare_Captured_Frame.prefab +48 -48
  64. package/{Samples → Samples~}/Prepare_Captured_Frame.prefab.meta +7 -7
  65. package/{Samples → Samples~}/Prepare_Fast_Forward_Loaded_Line.prefab +49 -49
  66. package/{Samples → Samples~}/Prepare_Fast_Forward_Loaded_Line.prefab.meta +7 -7
  67. package/{Samples → Samples~}/Protag_Handler.prefab +50 -50
  68. package/{Samples → Samples~}/Protag_Handler.prefab.meta +7 -7
  69. package/{Samples → Samples~}/Protag_UI_Load_End_Resolver.prefab +48 -48
  70. package/{Samples → Samples~}/Protag_UI_Load_End_Resolver.prefab.meta +7 -7
  71. package/{Samples → Samples~}/Protag_UI_Resolver.prefab +82 -82
  72. package/{Samples → Samples~}/Protag_UI_Resolver.prefab.meta +7 -7
  73. package/{Samples → Samples~}/Resolve_3D_UI_Visibility.prefab +87 -87
  74. package/{Samples → Samples~}/Resolve_3D_UI_Visibility.prefab.meta +7 -7
  75. package/{Samples → Samples~}/Resolve_Bool_With_Event.prefab +49 -49
  76. package/{Samples → Samples~}/Resolve_Bool_With_Event.prefab.meta +7 -7
  77. package/{Samples → Samples~}/Resolve_Captured_Frame.prefab +52 -52
  78. package/{Samples → Samples~}/Resolve_Captured_Frame.prefab.meta +7 -7
  79. package/{Samples → Samples~}/Swap_Cameras_On_Dialogue_End.prefab +50 -50
  80. package/{Samples → Samples~}/Swap_Cameras_On_Dialogue_End.prefab.meta +7 -7
  81. package/{Samples → Samples~}/Toggle_UI_Mechanic.prefab +50 -50
  82. package/{Samples → Samples~}/Toggle_UI_Mechanic.prefab.meta +7 -7
  83. package/{Samples → Samples~}/Trial_Dialogue_Auto_Icon_ETemplate.prefab +122 -122
  84. package/{Samples → Samples~}/Trial_Dialogue_Auto_Icon_ETemplate.prefab.meta +7 -7
  85. package/{Samples → Samples~}/Trial_Dialogue_Mouse_Icon_ETemplate.prefab +122 -122
  86. package/{Samples → Samples~}/Trial_Dialogue_Mouse_Icon_ETemplate.prefab.meta +7 -7
  87. package/{Samples → Samples~}/Wait_For_Automatic_Line_Handler.prefab +47 -47
  88. package/{Samples → Samples~}/Wait_For_Automatic_Line_Handler.prefab.meta +7 -7
  89. package/{Samples → Samples~}/Wait_For_Dialogue_Click.prefab +147 -147
  90. package/{Samples → Samples~}/Wait_For_Dialogue_Click.prefab.meta +7 -7
  91. package/SwapCamerasOnDialogueEnd.cs +71 -71
  92. package/SwapCamerasOnDialogueEnd.cs.meta +11 -11
  93. package/ToggleUIListener.cs +53 -53
  94. package/ToggleUIListener.cs.meta +11 -11
  95. package/ToggleUIMechanic.cs +100 -100
  96. package/ToggleUIMechanic.cs.meta +11 -11
  97. package/TriggerCustomDialogueEventDuringLine.cs +62 -62
  98. package/TriggerCustomDialogueEventDuringLine.cs.meta +11 -11
  99. package/WaitForAutomaticLineHandler.cs +36 -36
  100. package/WaitForAutomaticLineHandler.cs.meta +11 -11
  101. package/WaitForDialogueClick.cs +179 -179
  102. package/WaitForDialogueClick.cs.meta +11 -11
  103. package/package.json +48 -43
  104. package/package.json.meta +7 -7
  105. package/Samples.meta +0 -8
Binary file
@@ -1,81 +1,81 @@
1
- //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
- using DREditor.Dialogues;
3
- using DREditor.Dialogues.LineReading;
4
- using DREditor.EventObjects;
5
- using System;
6
- using System.Collections;
7
- using UnityEngine;
8
-
9
- namespace DREditor.DialogueMechanics
10
- {
11
- /// <summary>
12
- ///
13
- /// </summary>
14
- [ClassHeader(nameof(DialogueComponent) + ", " + nameof(ILineWaitForClick) +
15
- "\n\n")]
16
- public class CheckMenuAccess : DialogueComponent, ILineWaitForClick
17
- {
18
- /// <summary>
19
- ///
20
- /// </summary>
21
- [Tooltip("")]
22
- [SerializeField] protected BoolWithEvent inFastForwardMode = null;
23
-
24
- /// <summary>
25
- ///
26
- /// </summary>
27
- [Tooltip("")]
28
- [SerializeField] protected BoolWithEvent inInstant = null;
29
-
30
- /// <summary>
31
- ///
32
- /// </summary>
33
- [Tooltip("")]
34
- [SerializeField] protected BoolWithEvent hasMenuAccess = null;
35
-
36
- /// <summary>
37
- ///
38
- /// </summary>
39
- [Tooltip("")]
40
- [SerializeField] protected BoolWithEvent inDebate = null;
41
-
42
- /// <summary>
43
- ///
44
- /// </summary>
45
- [Tooltip("")]
46
- [SerializeField] protected BoolWithEvent trialMistake = null;
47
-
48
-
49
- public virtual bool SkipOnFastForward => true;
50
-
51
-
52
- /// <inheritdoc/>
53
- public IEnumerator LineWaitForClick<T>(DialogueBase<T> currentDialogue, Line currentLine, Action exitParentCallback = null)
54
- where T : Line
55
- {
56
- if ((inDebate == null || !inDebate.Value) && (trialMistake == null || !trialMistake.Value))
57
- EvaluateMenuAccess(currentDialogue, currentLine);
58
-
59
- yield break;
60
- }
61
-
62
- /// <summary>
63
- ///
64
- /// </summary>
65
- /// <typeparam name="T"></typeparam>
66
- /// <param name="currentDialogue"></param>
67
- /// <param name="currentLine"></param>
68
- protected virtual void EvaluateMenuAccess<T>(DialogueBase<T> currentDialogue, Line currentLine)
69
- where T : Line
70
- {
71
- bool OnLastLine = currentDialogue.Lines.IndexOf((T)currentLine) == currentDialogue.Lines.Count - 1;
72
-
73
- bool hasChoices = OnLastLine && currentDialogue is Dialogue dialogue && dialogue.Choices.Count != 0;
74
-
75
- bool notFastForwardInRegularDialogue = !inInstant.Value && !inFastForwardMode.Value;
76
-
77
- if (!hasChoices && (inInstant.Value || notFastForwardInRegularDialogue))
78
- hasMenuAccess.SetValue(true);
79
- }
80
- }
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
2
+ using DREditor.Dialogues;
3
+ using DREditor.Dialogues.LineReading;
4
+ using DREditor.EventObjects;
5
+ using System;
6
+ using System.Collections;
7
+ using UnityEngine;
8
+
9
+ namespace DREditor.DialogueMechanics
10
+ {
11
+ /// <summary>
12
+ ///
13
+ /// </summary>
14
+ [ClassHeader(nameof(DialogueComponent) + ", " + nameof(ILineWaitForClick) +
15
+ "\n\n")]
16
+ public class CheckMenuAccess : DialogueComponent, ILineWaitForClick
17
+ {
18
+ /// <summary>
19
+ ///
20
+ /// </summary>
21
+ [Tooltip("")]
22
+ [SerializeField] protected BoolWithEvent inFastForwardMode = null;
23
+
24
+ /// <summary>
25
+ ///
26
+ /// </summary>
27
+ [Tooltip("")]
28
+ [SerializeField] protected BoolWithEvent inInstant = null;
29
+
30
+ /// <summary>
31
+ ///
32
+ /// </summary>
33
+ [Tooltip("")]
34
+ [SerializeField] protected BoolWithEvent hasMenuAccess = null;
35
+
36
+ /// <summary>
37
+ ///
38
+ /// </summary>
39
+ [Tooltip("")]
40
+ [SerializeField] protected BoolWithEvent inDebate = null;
41
+
42
+ /// <summary>
43
+ ///
44
+ /// </summary>
45
+ [Tooltip("")]
46
+ [SerializeField] protected BoolWithEvent trialMistake = null;
47
+
48
+
49
+ public virtual bool SkipOnFastForward => true;
50
+
51
+
52
+ /// <inheritdoc/>
53
+ public IEnumerator LineWaitForClick<T>(DialogueBase<T> currentDialogue, Line currentLine, Action exitParentCallback = null)
54
+ where T : Line
55
+ {
56
+ if ((inDebate == null || !inDebate.Value) && (trialMistake == null || !trialMistake.Value))
57
+ EvaluateMenuAccess(currentDialogue, currentLine);
58
+
59
+ yield break;
60
+ }
61
+
62
+ /// <summary>
63
+ ///
64
+ /// </summary>
65
+ /// <typeparam name="T"></typeparam>
66
+ /// <param name="currentDialogue"></param>
67
+ /// <param name="currentLine"></param>
68
+ protected virtual void EvaluateMenuAccess<T>(DialogueBase<T> currentDialogue, Line currentLine)
69
+ where T : Line
70
+ {
71
+ bool OnLastLine = currentDialogue.Lines.IndexOf((T)currentLine) == currentDialogue.Lines.Count - 1;
72
+
73
+ bool hasChoices = OnLastLine && currentDialogue is Dialogue dialogue && dialogue.Choices.Count != 0;
74
+
75
+ bool notFastForwardInRegularDialogue = !inInstant.Value && !inFastForwardMode.Value;
76
+
77
+ if (!hasChoices && (inInstant.Value || notFastForwardInRegularDialogue))
78
+ hasMenuAccess.SetValue(true);
79
+ }
80
+ }
81
81
  }
@@ -1,11 +1,11 @@
1
- fileFormatVersion: 2
2
- guid: ca3687eef1a572e4c9fca6e23f67731e
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: ca3687eef1a572e4c9fca6e23f67731e
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -1,64 +1,64 @@
1
- //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Gardenusing DREditor.Dialogues;
2
- using DREditor.Dialogues;
3
- using DREditor.Dialogues.LineReading;
4
- using DREditor.EventObjects;
5
- using DREditor.Services;
6
- using UnityEngine;
7
-
8
- namespace DREditor.DialogueMechanics
9
- {
10
- /// <summary>
11
- ///
12
- /// </summary>
13
- [ClassHeader(nameof(DialogueComponent) + ", " +
14
- nameof(ILinePostTextDisplay) + ", " + nameof(ILineEndProcess) + ", " + nameof(IToTitleScreen) +
15
- "\n\n")]
16
- public class ClickIconLineHandler : DialogueComponent, ILinePostTextDisplay, ILineEndProcess, IToTitleScreen
17
- {
18
- /// <summary>
19
- ///
20
- /// </summary>
21
- [Tooltip("")]
22
- [SerializeField] protected BoolWithEvent inAutoMode = null;
23
-
24
- /// <summary>
25
- ///
26
- /// </summary>
27
- [Tooltip("")]
28
- [SerializeField] protected BoolWithEvent clickIconVisible = null;
29
-
30
-
31
- /// <inheritdoc/>
32
- public virtual void LinePostTextProcess(Line currentLine)
33
- {
34
- if (!inAutoMode.Value)
35
- clickIconVisible.SetValue(true);
36
- }
37
-
38
- /// <inheritdoc/>
39
- public virtual void LineEndProcess(Line currentLine = null)
40
- {
41
- if (!inAutoMode.Value)
42
- clickIconVisible.SetValue(false);
43
- }
44
-
45
-
46
- protected virtual void OnEnable() => inAutoMode.AddListener(EnsureClickVisibilityOnStoppingAuto);
47
-
48
- protected virtual void OnDisable() => inAutoMode.RemoveListener(EnsureClickVisibilityOnStoppingAuto);
49
-
50
- /// <summary>
51
- ///
52
- /// </summary>
53
- /// <param name="inAuto"></param>
54
- protected virtual void EnsureClickVisibilityOnStoppingAuto(bool inAuto)
55
- {
56
- if (!inAuto && !clickIconVisible.Value)
57
- clickIconVisible.Invoke();
58
- }
59
-
60
-
61
- /// <inheritdoc/>
62
- public virtual void ToTitleScreen() => clickIconVisible.SetValue(false);
63
- }
1
+ //Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Gardenusing DREditor.Dialogues;
2
+ using DREditor.Dialogues;
3
+ using DREditor.Dialogues.LineReading;
4
+ using DREditor.EventObjects;
5
+ using DREditor.Services;
6
+ using UnityEngine;
7
+
8
+ namespace DREditor.DialogueMechanics
9
+ {
10
+ /// <summary>
11
+ ///
12
+ /// </summary>
13
+ [ClassHeader(nameof(DialogueComponent) + ", " +
14
+ nameof(ILinePostTextDisplay) + ", " + nameof(ILineEndProcess) + ", " + nameof(IToTitleScreen) +
15
+ "\n\n")]
16
+ public class ClickIconLineHandler : DialogueComponent, ILinePostTextDisplay, ILineEndProcess, IToTitleScreen
17
+ {
18
+ /// <summary>
19
+ ///
20
+ /// </summary>
21
+ [Tooltip("")]
22
+ [SerializeField] protected BoolWithEvent inAutoMode = null;
23
+
24
+ /// <summary>
25
+ ///
26
+ /// </summary>
27
+ [Tooltip("")]
28
+ [SerializeField] protected BoolWithEvent clickIconVisible = null;
29
+
30
+
31
+ /// <inheritdoc/>
32
+ public virtual void LinePostTextProcess(Line currentLine)
33
+ {
34
+ if (!inAutoMode.Value)
35
+ clickIconVisible.SetValue(true);
36
+ }
37
+
38
+ /// <inheritdoc/>
39
+ public virtual void LineEndProcess(Line currentLine = null)
40
+ {
41
+ if (!inAutoMode.Value)
42
+ clickIconVisible.SetValue(false);
43
+ }
44
+
45
+
46
+ protected virtual void OnEnable() => inAutoMode.AddListener(EnsureClickVisibilityOnStoppingAuto);
47
+
48
+ protected virtual void OnDisable() => inAutoMode.RemoveListener(EnsureClickVisibilityOnStoppingAuto);
49
+
50
+ /// <summary>
51
+ ///
52
+ /// </summary>
53
+ /// <param name="inAuto"></param>
54
+ protected virtual void EnsureClickVisibilityOnStoppingAuto(bool inAuto)
55
+ {
56
+ if (!inAuto && !clickIconVisible.Value)
57
+ clickIconVisible.Invoke();
58
+ }
59
+
60
+
61
+ /// <inheritdoc/>
62
+ public virtual void ToTitleScreen() => clickIconVisible.SetValue(false);
63
+ }
64
64
  }
@@ -1,11 +1,11 @@
1
- fileFormatVersion: 2
2
- guid: c68278f07b453994db447235f427f335
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: c68278f07b453994db447235f427f335
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -1,29 +1,29 @@
1
- {
2
- "name": "DREditor.DialogueMechanics",
3
- "rootNamespace": "",
4
- "references": [
5
- "DREditor",
6
- "FMODUnity",
7
- "Unity.InputSystem",
8
- "DREditor.Fading",
9
- "DREditor.TextDisplaying",
10
- "DREditor.Nameplates",
11
- "DREditor.LocalDialogues",
12
- "DG.Tweening",
13
- "Unity.TextMeshPro",
14
- "DREditor.Progressing.Handling",
15
- "DREditor.DialogueEventHandling",
16
- "DREditor.UIHandling",
17
- "DREditor.Controls",
18
- "DREditor.Editor"
19
- ],
20
- "includePlatforms": [],
21
- "excludePlatforms": [],
22
- "allowUnsafeCode": false,
23
- "overrideReferences": false,
24
- "precompiledReferences": [],
25
- "autoReferenced": true,
26
- "defineConstraints": [],
27
- "versionDefines": [],
28
- "noEngineReferences": false
1
+ {
2
+ "name": "DREditor.DialogueMechanics",
3
+ "rootNamespace": "",
4
+ "references": [
5
+ "DREditor",
6
+ "FMODUnity",
7
+ "Unity.InputSystem",
8
+ "DREditor.Fading",
9
+ "DREditor.TextDisplaying",
10
+ "DREditor.Nameplates",
11
+ "DREditor.LocalDialogues",
12
+ "DG.Tweening",
13
+ "Unity.TextMeshPro",
14
+ "DREditor.Progressing.Handling",
15
+ "DREditor.DialogueEventHandling",
16
+ "DREditor.UIHandling",
17
+ "DREditor.Controls",
18
+ "DREditor.Editor"
19
+ ],
20
+ "includePlatforms": [],
21
+ "excludePlatforms": [],
22
+ "allowUnsafeCode": false,
23
+ "overrideReferences": false,
24
+ "precompiledReferences": [],
25
+ "autoReferenced": true,
26
+ "defineConstraints": [],
27
+ "versionDefines": [],
28
+ "noEngineReferences": false
29
29
  }
@@ -1,7 +1,7 @@
1
- fileFormatVersion: 2
2
- guid: 1354b22a035c78f42a66c5fe6bff4bb2
3
- AssemblyDefinitionImporter:
4
- externalObjects: {}
5
- userData:
6
- assetBundleName:
7
- assetBundleVariant:
1
+ fileFormatVersion: 2
2
+ guid: 1354b22a035c78f42a66c5fe6bff4bb2
3
+ AssemblyDefinitionImporter:
4
+ externalObjects: {}
5
+ userData:
6
+ assetBundleName:
7
+ assetBundleVariant: