public boolean undoAutoMoves(INode state){
  for (int i=autoMoves.size() - 1; i >= 0; i--) {
    IMove move=autoMoves.get(i);
    move.undo(state);
  }
  autoMoves.clear();
  return true;
}

public boolean undoAutoMoves ( INode state ) { for ( int i = autoMoves . size ( ) - 1 ; i >= 0 ; i -- ) { IMove move = autoMoves . get ( i ) ; move . undo ( state ) ; } autoMoves . clear ( ) ; return true ; }
undo moves in reverse order .
