Hi. A problem happened when the player charactor was exiting the portal.
Failed to create agent because it is not close enough to the NavMesh
UnityEngine.StackTraceUtility:ExtractStackTrace ()
RPG.Movement.Move
any solution to advise?
r:RestoreState (object) (at Assets/Scripts/Movement/Mover.cs:94),
Here is the methord code in the Mover class.
public void RestoreState(object state)
{
Dictionary<string, object> data = (Dictionary<string, object>)state;
navMeshAgent.enabled = false;
transform.position = ((SerializableVector3)data["position"]).ToVector();
transform.eulerAngles = ((SerializableVector3)data["rotation"]).ToVector();
navMeshAgent.Warp(transform.position);
navMeshAgent.enabled = true;
}