Exemple #1
0
    void Start()
    {
        cacheImagesProd = new Image[prodSlots.Count];
        cacheImages     = new Image[prodSlots.Count];
        cacheButtons    = new Button[prodSlots.Count];
        for (int i = 0; i < prodSlots.Count; i++)
        {
            cacheImagesProd[i] = prodSlots[i].gameObject.transform.FindChild("ant_prod_query_status_slot_progressbar").GetComponent <Image>();
            cacheImages[i]     = prodSlots[i].GetComponent <Image>();
            cacheButtons[i]    = prodSlots[i].GetComponent <Button>();
        }
        base_manager_cache      = GameObject.Find(vars.base_name).GetComponent <base_manager>();
        unit_group_chache_cache = GameObject.Find(vars.base_name).GetComponent <UnitGroupCache>();
        upgrade_manager_cache   = GameObject.Find(vars.upgrade_manager_name).GetComponent <upgrade_manager>();
        this.name      = vars.ui_manager_name;
        Time.timeScale = 1.0f;
        //	refresh_ressource_ui();
        //	pem_btn_text.GetComponent<Text>().text = "ENTER PATHEDITMODE";
        vars.is_in_patheditmode = false;
        uirc = 0;

        curr_sel_type = selected_ant_type.nothing;
        clear_base_ui_values();
        pause_menu_holder.SetActive(false);
        is_in_menu = false;
    }
Exemple #2
0
 // Update is called once per frame
 void Awake()
 {
     script_cache.base_manager_cache      = GameObject.Find(vars.base_name).GetComponent <base_manager>();
     script_cache.unit_group_chache_cache = GameObject.Find(vars.base_name).GetComponent <UnitGroupCache>();
     script_cache.upgrade_manager_cache   = GameObject.Find(vars.upgrade_manager_name).GetComponent <upgrade_manager>();
     script_cache.main_canvas             = GameObject.Find(vars.main_canvas_name).GetComponent <Canvas>();
 }
    void Start()
    {
        cacheImagesProd = new Image[prodSlots.Count];
        cacheImages = new Image[prodSlots.Count];
        cacheButtons = new Button[prodSlots.Count];
        for(int i = 0; i < prodSlots.Count; i++) {
            cacheImagesProd[i] = prodSlots[i].gameObject.transform.FindChild("ant_prod_query_status_slot_progressbar").GetComponent<Image>();
            cacheImages[i] = prodSlots[i].GetComponent<Image>();
            cacheButtons[i] = prodSlots[i].GetComponent<Button>();
        }
        base_manager_cache = GameObject.Find(vars.base_name).GetComponent<base_manager>();
        unit_group_chache_cache = GameObject.Find(vars.base_name).GetComponent<UnitGroupCache>();
        upgrade_manager_cache = GameObject.Find(vars.upgrade_manager_name).GetComponent<upgrade_manager>();
        this.name = vars.ui_manager_name;
        Time.timeScale = 1.0f;
        //	refresh_ressource_ui();
        //	pem_btn_text.GetComponent<Text>().text = "ENTER PATHEDITMODE";
        vars.is_in_patheditmode = false;
        uirc = 0;

        curr_sel_type = selected_ant_type.nothing;
        clear_base_ui_values();
        pause_menu_holder.SetActive(false);
        is_in_menu = false;
    }
Exemple #4
0
 // Update is called once per frame
 void Awake()
 {
     script_cache.base_manager_cache = GameObject.Find(vars.base_name).GetComponent<base_manager>();
     script_cache.unit_group_chache_cache = GameObject.Find(vars.base_name).GetComponent<UnitGroupCache>();
     script_cache.upgrade_manager_cache = GameObject.Find(vars.upgrade_manager_name).GetComponent<upgrade_manager>();
 }