You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// This code is part of the Fungus library (https://github.com/snozbot/fungus)
2
+
// It is released for free under the MIT open source license (https://github.com/snozbot/fungus/blob/master/LICENSE)
3
+
4
+
usingUnityEngine;
5
+
usingUnityEngine.UI;
6
+
usingSystem.Collections;
7
+
8
+
namespaceFungus
9
+
{
10
+
/// <summary>
11
+
/// Loads a saved value and stores it in a Boolean, Integer, Float or String variable. If the key is not found then the variable is not modified.
12
+
/// </summary>
13
+
[CommandInfo("Variable",
14
+
"Standalone Character's Point System",
15
+
"Point/affinity system like in HP, MP or point systems for characters in visual novel. IMPORTANT: Use On-Update only when this command works as a standalone/in disconnected block ")]
16
+
[AddComponentMenu("")]
17
+
publicclassStandAloneCharacterPointSystem:Command
18
+
{
19
+
[HideInInspector]protectedstringkey="";
20
+
[Tooltip("Variable to store the value in.")]
21
+
[VariableProperty(typeof(IntegerVariable),
22
+
typeof(FloatVariable))]
23
+
[SerializeField]protectedVariablevariable;
24
+
[SerializeField]protectedfloatmaxValueOf;
25
+
[SerializeField]protectedSliderslider;
26
+
[SerializeField]protectedbooluseTextUI=false;
27
+
[Tooltip("If Text component is used, Slider component will be ignored")]
28
+
[SerializeField]protectedTexttextComponent;
29
+
[Header("Realtime Update. MUST be standalone/disconnected block")]
30
+
[Tooltip("Use this only when this command works as a standalone(separate block/disconnected block)")]
0 commit comments