private void OnDestroy()
 {
     if (isPolyNav == true)
     {
         _navMapRef.RemoveObstacle(_myObstacle);
     }
 }
Example #2
0
 static int RemoveObstacle(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 2);
         PolyNav2D       obj  = (PolyNav2D)ToLua.CheckObject <PolyNav2D>(L, 1);
         PolyNavObstacle arg0 = (PolyNavObstacle)ToLua.CheckObject <PolyNavObstacle>(L, 2);
         obj.RemoveObstacle(arg0);
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
Example #3
0
 /// <summary>
 /// Called when companion used to "remove" the obstacle.
 /// </summary>
 private void OnDestroy()
 {
     _navMapRef.RemoveObstacle(_myObstacle);
 }