Hi,
When I use Can see Object (or the Conditionnal Evaluation with Can be See) the behavior tree disappear and throw me this error message:
UnityException: NameToLayer can only be called from the main thread.
Constructors and field initializers will be executed from the loading thread when loading a scene.
Don't use this function in the constructor or field initializers, instead move initialization code to the Awake or Start function.
BehaviorDesigner.Runtime.Tasks.Movement.CanSeeObject..ctor () (at Assets/Behavior Designer Movement/Scripts/Tasks/CanSeeObject.cs:24)
System.Reflection.MonoCMethod.InternalInvoke (System.Object obj, System.Object[] parameters) (at <437ba245d8404784b9fbab9b439ac908>:0)
Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
....
when I use the Can be see from tutoriel, everything work fine.
Can you help me on this one?
When I use Can see Object (or the Conditionnal Evaluation with Can be See) the behavior tree disappear and throw me this error message:
UnityException: NameToLayer can only be called from the main thread.
Constructors and field initializers will be executed from the loading thread when loading a scene.
Don't use this function in the constructor or field initializers, instead move initialization code to the Awake or Start function.
BehaviorDesigner.Runtime.Tasks.Movement.CanSeeObject..ctor () (at Assets/Behavior Designer Movement/Scripts/Tasks/CanSeeObject.cs:24)
System.Reflection.MonoCMethod.InternalInvoke (System.Object obj, System.Object[] parameters) (at <437ba245d8404784b9fbab9b439ac908>:0)
Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
....
when I use the Can be see from tutoriel, everything work fine.
Can you help me on this one?