diff options
Diffstat (limited to 'Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/String/GetSubstring.cs')
-rw-r--r-- | Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/String/GetSubstring.cs | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/String/GetSubstring.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/String/GetSubstring.cs deleted file mode 100644 index 6ede171f..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/String/GetSubstring.cs +++ /dev/null @@ -1,35 +0,0 @@ -namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityString
-{
- [TaskCategory("Basic/String")]
- [TaskDescription("Stores a substring of the target string")]
- public class GetSubstring : Action
- {
- [Tooltip("The target string")]
- public SharedString targetString;
- [Tooltip("The start substring index")]
- public SharedInt startIndex = 0;
- [Tooltip("The length of the substring. Don't use if -1")]
- public SharedInt length = -1;
- [Tooltip("The stored result")]
- [RequiredField]
- public SharedString storeResult;
-
- public override TaskStatus OnUpdate()
- {
- if (length.Value != -1) {
- storeResult.Value = targetString.Value.Substring(startIndex.Value, length.Value);
- } else {
- storeResult.Value = targetString.Value.Substring(startIndex.Value);
- }
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetString = "";
- startIndex = 0;
- length = -1;
- storeResult = "";
- }
- }
-}
\ No newline at end of file |