diff options
author | chai <chaifix@163.com> | 2022-03-10 14:07:40 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2022-03-10 14:07:40 +0800 |
commit | 22891bf59032ba88262824255a706d652031384b (patch) | |
tree | 7595439ba9966c9402d37e37cee5e8cf098757d5 /Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent | |
parent | 8b04ea73e540067f83870b61d89db4868fea5e8a (diff) |
* move folder
Diffstat (limited to 'Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent')
28 files changed, 0 insertions, 787 deletions
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAcceleration.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAcceleration.cs deleted file mode 100644 index 050f35e4..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAcceleration.cs +++ /dev/null @@ -1,49 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Gets the maximum acceleration of an agent as it follows a path, given in units / sec^2.. Returns Success.")]
- public class GetAcceleration : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [SharedRequired]
- [Tooltip("The NavMeshAgent acceleration")]
- public SharedFloat storeValue;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- storeValue.Value = navMeshAgent.acceleration;
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- storeValue = 0;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAcceleration.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAcceleration.cs.meta deleted file mode 100644 index 8640a76e..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAcceleration.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: 7e00211632663cc43bc88ab068ab5d44
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAngularSpeed.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAngularSpeed.cs deleted file mode 100644 index f5378f2d..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAngularSpeed.cs +++ /dev/null @@ -1,49 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Gets the maximum turning speed in (deg/s) while following a path.. Returns Success.")]
- public class GetAngularSpeed : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [SharedRequired]
- [Tooltip("The NavMeshAgent angular speed")]
- public SharedFloat storeValue;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- storeValue.Value = navMeshAgent.angularSpeed;
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- storeValue = 0;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAngularSpeed.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAngularSpeed.cs.meta deleted file mode 100644 index 6fd470cc..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetAngularSpeed.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: 110bcd7b4d1baae4096b5da6737c1e16
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetDestination.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetDestination.cs deleted file mode 100644 index c85ef613..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetDestination.cs +++ /dev/null @@ -1,49 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Gets the destination of the agent in world-space units. Returns Success.")]
- public class GetDestination : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [SharedRequired]
- [Tooltip("The NavMeshAgent destination")]
- public SharedVector3 storeValue;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- storeValue.Value = navMeshAgent.destination;
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- storeValue = Vector3.zero;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetDestination.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetDestination.cs.meta deleted file mode 100644 index e6090098..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetDestination.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: 4368ae3e22d36604697d420dff004cbe
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetRemainingDistance.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetRemainingDistance.cs deleted file mode 100644 index e2f49731..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetRemainingDistance.cs +++ /dev/null @@ -1,49 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Gets the distance between the agent's position and the destination on the current path. Returns Success.")]
- public class GetRemainingDistance : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [SharedRequired]
- [Tooltip("The remaining distance")]
- public SharedFloat storeValue;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- storeValue.Value = navMeshAgent.remainingDistance;
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- storeValue = 0;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetRemainingDistance.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetRemainingDistance.cs.meta deleted file mode 100644 index 8ac9d355..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetRemainingDistance.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: ab046b37543b6744aa440cd708a93b81
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetSpeed.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetSpeed.cs deleted file mode 100644 index 1969545f..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetSpeed.cs +++ /dev/null @@ -1,49 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Gets the maximum movement speed when following a path. Returns Success.")]
- public class GetSpeed : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [SharedRequired]
- [Tooltip("The NavMeshAgent speed")]
- public SharedFloat storeValue;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- storeValue.Value = navMeshAgent.speed;
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- storeValue = 0;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetSpeed.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetSpeed.cs.meta deleted file mode 100644 index d395eea4..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/GetSpeed.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: b6397854a3aea4b44a5ab4ccf98d082d
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Move.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Move.cs deleted file mode 100644 index c3ad27fb..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Move.cs +++ /dev/null @@ -1,48 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Apply relative movement to the current position. Returns Success.")]
- public class Move : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [Tooltip("The relative movement vector")]
- public SharedVector3 offset;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- navMeshAgent.Move(offset.Value);
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- offset = Vector3.zero;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Move.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Move.cs.meta deleted file mode 100644 index 4217e2de..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Move.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: 55ea16e678f6fae47a46affd3d22b883
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/ResetPath.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/ResetPath.cs deleted file mode 100644 index 3aa1a4bc..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/ResetPath.cs +++ /dev/null @@ -1,45 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Clears the current path. Returns Success.")]
- public class ResetPath : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- navMeshAgent.ResetPath();
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/ResetPath.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/ResetPath.cs.meta deleted file mode 100644 index 2e95416c..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/ResetPath.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: e90973887b9e7d04aafc5d13ecdfc8b9
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Resume.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Resume.cs deleted file mode 100644 index bf62cb97..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Resume.cs +++ /dev/null @@ -1,49 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Resumes the movement along the current path after a pause. Returns Success.")]
- public class Resume : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
-#if UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4 || UNITY_5_5
- navMeshAgent.Resume();
-#else
- navMeshAgent.isStopped = false;
-#endif
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Resume.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Resume.cs.meta deleted file mode 100644 index 16e07057..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Resume.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: 2c87e343e0ec23041b0cf7d8090d4814
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAcceleration.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAcceleration.cs deleted file mode 100644 index 9473466d..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAcceleration.cs +++ /dev/null @@ -1,48 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Sets the maximum acceleration of an agent as it follows a path, given in units / sec^2. Returns Success.")]
- public class SetAcceleration : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [Tooltip("The NavMeshAgent acceleration")]
- public SharedFloat acceleration;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- navMeshAgent.acceleration = acceleration.Value;
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- acceleration = 0;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAcceleration.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAcceleration.cs.meta deleted file mode 100644 index e3090bce..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAcceleration.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: a8357209bccc16442b549c580872bb05
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAngularSpeed.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAngularSpeed.cs deleted file mode 100644 index 3c7c7721..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAngularSpeed.cs +++ /dev/null @@ -1,48 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Sets the maximum turning speed in (deg/s) while following a path. Returns Success.")]
- public class SetAngularSpeed : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [Tooltip("The NavMeshAgent angular speed")]
- public SharedFloat angularSpeed;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- navMeshAgent.angularSpeed = angularSpeed.Value;
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- angularSpeed = 0;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAngularSpeed.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAngularSpeed.cs.meta deleted file mode 100644 index 0b1d44a5..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetAngularSpeed.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: 0d8e213aa17540848b83b17ba1609c74
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetDestination.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetDestination.cs deleted file mode 100644 index 0efa0dba..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetDestination.cs +++ /dev/null @@ -1,47 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Sets the destination of the agent in world-space units. Returns Success if the destination is valid.")]
- public class SetDestination: Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [SharedRequired]
- [Tooltip("The NavMeshAgent destination")]
- public SharedVector3 destination;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- return navMeshAgent.SetDestination(destination.Value) ? TaskStatus.Success : TaskStatus.Failure;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- destination = Vector3.zero;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetDestination.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetDestination.cs.meta deleted file mode 100644 index d5f1bde8..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetDestination.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: 55d9c2d20e895104181ae1b484868ead
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetSpeed.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetSpeed.cs deleted file mode 100644 index a1a4a51b..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetSpeed.cs +++ /dev/null @@ -1,48 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Sets the maximum movement speed when following a path. Returns Success.")]
- public class SetSpeed : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [Tooltip("The NavMeshAgent speed")]
- public SharedFloat speed;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- navMeshAgent.speed = speed.Value;
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- speed = 0;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetSpeed.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetSpeed.cs.meta deleted file mode 100644 index 79a97d26..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/SetSpeed.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: 34372b45870504b419f34165fb1fa4fb
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Stop.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Stop.cs deleted file mode 100644 index 0af7d480..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Stop.cs +++ /dev/null @@ -1,49 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Stop movement of this agent along its current path. Returns Success.")]
- public class Stop : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
-#if UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4 || UNITY_5_5
- navMeshAgent.Stop();
-#else
- navMeshAgent.isStopped = true;
-#endif
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Stop.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Stop.cs.meta deleted file mode 100644 index 7a6ada0c..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Stop.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: b20958b8b92e47f40ba3178c99576182
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Warp.cs b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Warp.cs deleted file mode 100644 index d8107173..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Warp.cs +++ /dev/null @@ -1,48 +0,0 @@ -using UnityEngine;
-#if !(UNITY_5_1 || UNITY_5_2 || UNITY_5_3 || UNITY_5_4)
-using UnityEngine.AI;
-#endif
-
-namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityNavMeshAgent
-{
- [TaskCategory("Basic/NavMeshAgent")]
- [TaskDescription("Warps agent to the provided position. Returns Success.")]
- public class Warp : Action
- {
- [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")]
- public SharedGameObject targetGameObject;
- [Tooltip("The position to warp to")]
- public SharedVector3 newPosition;
-
- // cache the navmeshagent component
- private NavMeshAgent navMeshAgent;
- private GameObject prevGameObject;
-
- public override void OnStart()
- {
- var currentGameObject = GetDefaultGameObject(targetGameObject.Value);
- if (currentGameObject != prevGameObject) {
- navMeshAgent = currentGameObject.GetComponent<NavMeshAgent>();
- prevGameObject = currentGameObject;
- }
- }
-
- public override TaskStatus OnUpdate()
- {
- if (navMeshAgent == null) {
- Debug.LogWarning("NavMeshAgent is null");
- return TaskStatus.Failure;
- }
-
- navMeshAgent.Warp(newPosition.Value);
-
- return TaskStatus.Success;
- }
-
- public override void OnReset()
- {
- targetGameObject = null;
- newPosition = Vector3.zero;
- }
- }
-}
\ No newline at end of file diff --git a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Warp.cs.meta b/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Warp.cs.meta deleted file mode 100644 index 8a6d4812..00000000 --- a/Assets/ThirdParty/Behavior Designer/Runtime/Basic Tasks/NavMeshAgent/Warp.cs.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2
-guid: 9d2356bfaf0a64b4d9d65d32708630db
-MonoImporter:
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
|