Pathfinding.Path.WaitForPath C# (CSharp) Method

WaitForPath() public method

public WaitForPath ( ) : IEnumerator
return IEnumerator
		public IEnumerator WaitForPath () {
			if (GetState () == PathState.Created) throw new System.InvalidOperationException ("This path has not been started yet");

			while (GetState () != PathState.Returned) yield return null;
		}

Usage Example

 static int WaitForPath(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         Pathfinding.Path obj             = (Pathfinding.Path)ToLua.CheckObject <Pathfinding.Path>(L, 1);
         System.Collections.IEnumerator o = obj.WaitForPath();
         ToLua.Push(L, o);
         return(1);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
All Usage Examples Of Pathfinding.Path::WaitForPath