poprawki materialy unity 6, pajaki, podmiana katalogu FSM w AIControlerze, zmiana w Spider 2.0 Behaviours , skopane zycie bylo, ladowalo pajaka z zyciem 2.
This commit is contained in:
@@ -8,7 +8,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Detection/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/AICanSeeTargetDecision.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Health/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/AICheckHealth.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Behaviour/"; }
|
||||
}
|
||||
|
||||
public override string defaultName
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/AICheckState.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Detection/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/AICheckTargetDead.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Combat/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/AICheckTargetIsInCombatRange.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -8,7 +8,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Combat/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/AICombatting.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/Editor/AICheckStateEditor.cs
|
||||
uploadId: 601882
|
||||
|
||||
30
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/IsInShotAngleDecision.cs
vendored
Normal file
30
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/IsInShotAngleDecision.cs
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
#if UNITY_EDITOR
|
||||
[vFSMHelpbox("This is a IsInShotAngleDecision decision", UnityEditor.MessageType.Info)]
|
||||
#endif
|
||||
public class IsInShotAngleDecision : vStateDecision
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return "Combat/"; }
|
||||
}
|
||||
|
||||
public override string defaultName
|
||||
{
|
||||
get { return "IsInShotAngleDecision"; }
|
||||
}
|
||||
public override Type requiredType => typeof(vIControlAIShooter);
|
||||
public override bool Decide(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
if (fsmBehaviour.aiController is vIControlAIShooter)
|
||||
{
|
||||
return (fsmBehaviour.aiController as vIControlAIShooter).IsInShotAngle;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
18
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/IsInShotAngleDecision.cs.meta
vendored
Normal file
18
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/IsInShotAngleDecision.cs.meta
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 61eeca5d27f02df46a285da7490fbd2d
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/IsInShotAngleDecision.cs
|
||||
uploadId: 601882
|
||||
@@ -1,48 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
|
||||
#if UNITY_EDITOR
|
||||
[vFSMHelpbox("Verify if you can see the target based on the Detection Settings of the AI Controller and Check if the AI Controller has received any Damage or a specific DamageType", UnityEditor.MessageType.Info)]
|
||||
#endif
|
||||
public class vAICanSeeOrCheckDamageTargetDecision : vStateDecision
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
}
|
||||
|
||||
public override string defaultName
|
||||
{
|
||||
get { return "Can See Or Check Damage"; }
|
||||
}
|
||||
|
||||
public List<string> damageTypeToCheck;
|
||||
|
||||
public override bool Decide(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
var canSee = CanSeeTarget(fsmBehaviour);
|
||||
var hasDamage = (HasDamage(fsmBehaviour));
|
||||
|
||||
return canSee || hasDamage;
|
||||
}
|
||||
|
||||
protected virtual bool HasDamage(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
if (fsmBehaviour.aiController == null) return false;
|
||||
var hasDamage = (fsmBehaviour.aiController.receivedDamage.isValid) && (damageTypeToCheck.Count == 0 || damageTypeToCheck.Contains(fsmBehaviour.aiController.receivedDamage.lasType));
|
||||
|
||||
if (fsmBehaviour.debugMode)
|
||||
{
|
||||
fsmBehaviour.SendDebug(Name + " " + (fsmBehaviour.aiController.receivedDamage.isValid) + " " + fsmBehaviour.aiController.receivedDamage.lastSender, this);
|
||||
}
|
||||
return hasDamage;
|
||||
}
|
||||
|
||||
protected virtual bool CanSeeTarget(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
return fsmBehaviour.aiController.targetInLineOfSight;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 50c776c71e52e174f92161c33199fe22
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -1,43 +0,0 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public class vAICheckAnimatorParameterBool : vStateDecision
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return "Custom Example/"; }
|
||||
}
|
||||
|
||||
public override string defaultName
|
||||
{
|
||||
get { return "Check Animator Parameter Bool"; }
|
||||
}
|
||||
|
||||
protected enum CompareValueMethod
|
||||
{
|
||||
True, False
|
||||
}
|
||||
[SerializeField]
|
||||
protected CompareValueMethod compareMethod;
|
||||
public string parameterName = "Bool name";
|
||||
|
||||
public override bool Decide(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
bool boolvalue = fsmBehaviour.aiController.animator.GetBool(parameterName);
|
||||
return CompareBool(boolvalue);
|
||||
}
|
||||
|
||||
private bool CompareBool(bool value)
|
||||
{
|
||||
switch (compareMethod)
|
||||
{
|
||||
case CompareValueMethod.True:
|
||||
return value == true;
|
||||
case CompareValueMethod.False:
|
||||
return value == false;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1b249d9fa5c892b4dae8afc5c5aa099d
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -1,47 +0,0 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
|
||||
public class vAICheckAnimatorParameterFloat : vStateDecision
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return "Custom Example/"; }
|
||||
}
|
||||
|
||||
public override string defaultName
|
||||
{
|
||||
get { return "Check Animator Parameter Float"; }
|
||||
}
|
||||
|
||||
protected enum CompareValueMethod
|
||||
{
|
||||
Greater, Less, Equal
|
||||
}
|
||||
[SerializeField]
|
||||
protected CompareValueMethod compareMethod;
|
||||
public float value;
|
||||
public string parameterName = "TurnOnSpotDir";
|
||||
|
||||
public override bool Decide(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
float angle = fsmBehaviour.aiController.animator.GetFloat(parameterName);
|
||||
return CompareDistance(Mathf.Abs(angle), this.value);
|
||||
}
|
||||
|
||||
private bool CompareDistance(float distA, float distB)
|
||||
{
|
||||
switch (compareMethod)
|
||||
{
|
||||
case CompareValueMethod.Equal:
|
||||
return distA.Equals(distB);
|
||||
case CompareValueMethod.Greater:
|
||||
return distA > distB;
|
||||
case CompareValueMethod.Less:
|
||||
return distA < distB;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 10fc04bb9c3cd5a4798fe861edc9fca6
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -9,7 +9,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Health/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vAICheckDamage.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Health/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vAICheckMassiveDamage.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Detection/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vAICheckTargetTag.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Noise/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
@@ -26,7 +26,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
if (fsmBehaviour.aiController.HasComponent<vAINoiseListener>())
|
||||
{
|
||||
var noiseListener = fsmBehaviour.aiController.GetAIComponent<vAINoiseListener>();
|
||||
var noiseListener = fsmBehaviour.aiController.GetAIComponent<vAINoiseListener>();
|
||||
if (specific) return noiseListener.IsListeningSpecificNoises(noiseTypes);
|
||||
else return noiseListener.IsListeningNoise();
|
||||
}
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vAIHearNoise.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Movement/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vAIIsInDestination.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -10,7 +10,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Noise/"; }
|
||||
}
|
||||
|
||||
public override string defaultName
|
||||
@@ -44,7 +44,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
if (specificType) noise = noiseListener.GetNearNoiseByTypes(noiseTypes);
|
||||
else noise = noiseListener.GetNearNoise();
|
||||
}
|
||||
else noise = noiseListener.lastListenedNoise;
|
||||
else noise = noiseListener.LastListenedNoise;
|
||||
if (noise != null)
|
||||
{
|
||||
return CompareDistance(Vector3.Distance(fsmBehaviour.aiController.transform.position, noise.position), distance);
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vCheckForNoiseDistance.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Detection/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vCheckTargetDistance.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Companion/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vCompanionIsForceToFollow.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Detection/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vFindTargetDecision.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Detection/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vHasTarget.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Movement/"; }
|
||||
}
|
||||
|
||||
public override string defaultName
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vHasWayPointArea.cs
|
||||
uploadId: 601882
|
||||
|
||||
31
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/vIsClosestListenerToNoise.cs
vendored
Normal file
31
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/vIsClosestListenerToNoise.cs
vendored
Normal file
@@ -0,0 +1,31 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
#if UNITY_EDITOR
|
||||
[vFSMHelpbox("This is a vIsClosestListenerToNoise decision", UnityEditor.MessageType.Info)]
|
||||
#endif
|
||||
public class vIsClosestListenerToNoise : vStateDecision
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return "Noise/"; }
|
||||
}
|
||||
|
||||
public override string defaultName
|
||||
{
|
||||
get { return "IsClosestListenerToNoise?"; }
|
||||
}
|
||||
|
||||
public override bool Decide(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
var noiseListener = fsmBehaviour.aiController.GetAIComponent<vAINoiseListener>();
|
||||
if(noiseListener!=null)
|
||||
{
|
||||
if(noiseListener.LastListenedNoise!=null)
|
||||
return noiseListener.IsClosestListenerToNoise(noiseListener.LastListenedNoise);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
18
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/vIsClosestListenerToNoise.cs.meta
vendored
Normal file
18
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/vIsClosestListenerToNoise.cs.meta
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2ce64abf40e2db240ad2e4cb16613160
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vIsClosestListenerToNoise.cs
|
||||
uploadId: 601882
|
||||
28
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/vIsInTrigger.cs
vendored
Normal file
28
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/vIsInTrigger.cs
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
#if UNITY_EDITOR
|
||||
[vFSMHelpbox("This is a vIsInTrigger decision", UnityEditor.MessageType.Info)]
|
||||
#endif
|
||||
public class vIsInTrigger : vStateDecision
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return "Trigger/"; }
|
||||
}
|
||||
|
||||
public override string defaultName
|
||||
{
|
||||
get { return "vIsInTrigger"; }
|
||||
}
|
||||
[vToggleOption("Method","Compare tag","Compare name")]
|
||||
public bool useName = false;
|
||||
public string compareTrigger;
|
||||
public override bool Decide(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
|
||||
return useName? fsmBehaviour.aiController.IsInTriggerWithName(compareTrigger): fsmBehaviour.aiController.IsInTriggerWithTag(compareTrigger);
|
||||
}
|
||||
}
|
||||
}
|
||||
18
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/vIsInTrigger.cs.meta
vendored
Normal file
18
Assets/ThirdParty/Invector-AIController/FSM/Scripts/Decisions/vIsInTrigger.cs.meta
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 367914c5728d91f4abae18ba70c9c443
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vIsInTrigger.cs
|
||||
uploadId: 601882
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Combat/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vIsShooting.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Generic/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vRandomDecision.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Detection/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
@@ -16,8 +16,8 @@
|
||||
|
||||
public override bool Decide(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
if (fsmBehaviour.aiController == null || !fsmBehaviour.aiController.currentTarget.isFighter) return false;
|
||||
return fsmBehaviour.aiController.currentTarget.isAttacking;
|
||||
/// why we need that?
|
||||
throw new System.NotImplementedException("TODO");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vTargetIsAttacking.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Detection/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
@@ -16,8 +16,7 @@
|
||||
|
||||
public override bool Decide(vIFSMBehaviourController fsmBehaviour)
|
||||
{
|
||||
if (fsmBehaviour.aiController == null || !fsmBehaviour.aiController.currentTarget.isCharacter) return false;
|
||||
return fsmBehaviour.aiController.currentTarget.character.isCrouching;
|
||||
throw new System.NotImplementedException("TODO");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vTargetIsCrouching.cs
|
||||
uploadId: 601882
|
||||
|
||||
@@ -8,7 +8,7 @@ namespace Invector.vCharacterController.AI.FSMBehaviour
|
||||
{
|
||||
public override string categoryName
|
||||
{
|
||||
get { return ""; }
|
||||
get { return "Detection/"; }
|
||||
}
|
||||
public override string defaultName
|
||||
{
|
||||
|
||||
@@ -10,3 +10,10 @@ MonoImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 123618
|
||||
packageName: Invector FSM AI Template
|
||||
packageVersion: 1.1.9a
|
||||
assetPath: Assets/Invector-FSMAIController/FSM/Scripts/Decisions/vTargetLost.cs
|
||||
uploadId: 601882
|
||||
|
||||
Reference in New Issue
Block a user