Example #1
0
    List <List <NPCLogic> > group = new List <List <NPCLogic> >();//For Groupping function can be replaced later

    private void Start()
    {
        for (int i = 0; i < 9; i++)//For Groupping function can be replaced later
        {
            group.Add(new List <NPCLogic>());
        }

        RTSSelector = GetComponent <RTSSelector>();

        /*   toggleRunButt.onClick.AddListener(() =>
         * {
         *     var selected = RTSSelector.GetSelectedAsNPCLogic();
         *     if (selected.Count >= 0)
         *         foreach (var npcLogic in selected) ToggleRunCommand(npcLogic);
         * });
         * dropItemButt.onClick.AddListener(() =>
         * {
         *     var selected = RTSSelector.GetSelectedAsNPCLogic();
         *     if (selected.Count >= 0)
         *         foreach (var npcLogic in selected) npcLogic.AddPriorityJob(new Job(Job.JobType.ITEM_DROP));
         * });
         * openInventoryButt.onClick.AddListener(() =>
         * {
         *
         * });*/
    }
Example #2
0
 // Start is called before the first frame update
 void Awake()
 {
     rtsSelector      = FindObjectOfType <RTSSelector>();
     canvas           = FindObjectOfType <Canvas>();
     spawnedNPCUIInfo = new List <NPCInfoUI>();
     anim             = GetComponent <Animation>();
     scrollRect       = GetComponentInChildren <ScrollRect>();
 }