コード例 #1
0
 private void replan(bool correct)
 {
     //TODO - make a new version for this
     correct = false;
     //if correct is true, it means the agent should try to first recover the previous plan
     //but it should also be careful not to repeat the same failures and should understand when it completed its plan
     if (correct && !pathPlan.checkIfConstantFail() && !checkPlanCompletion())
     {
         recoverPlan();
     }
     else
     {
         currentAction           = Moves.NO_ACTION;
         planRRT                 = true;
         newPlan                 = true;
         controller.slideReached = false;
         controller.morphReached = false;
         previousPlan            = pathPlan;
         pathPlan                = new PathPlan(cutplan, remaining.Count, utils);
     }
 }