Exemple #1
0
    public void StartCalculation()
    {
        CloseAllUis();
        statisticsUI.ClearStatistics();
        pathDisplayer.ClearAll();

        loadingPanel.GetComponentInChildren <TextMeshProUGUI>().text = "Berechnung läuft...";
        loadingPanel.SetActive(true);

        //Create node list and set the statics for waypoint count
        var nodes = NodeModel.CreateList(plannerPanel.GetShoppingList());

        statisticsUI.UpdateWaypointCnt(nodes.Count);


        Debug.Log("Posting shoppping list...");
        var hostUrl = schedulerIpField.text;

        SchedulerRestClient.Instance.StartCalculationForShoppinglist(nodes, hostUrl, ProcessIntermediateResult, ProcessCalculationResult);
        statisticsUI.ResetAndStartTimer();
    }