예제 #1
0
    private LabelListController ConfigureNewLabel(int i, GameObject newLabelList)
    {
        LabelListController labelListController = newLabelList.GetComponentInChildren <LabelListController>();
        string             currentObjectId      = currentObjectsList.objectsList[i];
        LabelConfiguration labelConfiguration   = new LabelConfiguration();

        labelConfiguration.labelText = "- " + currentObjectId;
        labelConfiguration.objectId  = currentObjectId;
        labelListController.ConfigureLabel(labelConfiguration);
        return(labelListController);
    }
예제 #2
0
    public void RemoveObject(SelectableObjectPack objectPack)
    {
        LabelListController labelListController = listReferences.Find(x => x.objectId == objectPack.id);

        if (labelListController != null)
        {
            listReferences.Remove(labelListController);
            Debug.Log("Trying to mark the flag");
            labelListController.ShowLabelFinishedFeedback();
        }
    }
예제 #3
0
 public void InstantiateLabels()
 {
     listReferences     = new List <LabelListController>();
     currentObjectsList = FindSystemManager.get.currentObjectsList;
     for (int i = 0; i < currentObjectsList.objectsList.Count; i++)
     {
         GameObject          newLabelList        = Instantiate(labelListPrefab, parentList);
         LabelListController labelListController = ConfigureNewLabel(i, newLabelList);
         listReferences.Add(labelListController);
     }
 }