Exemple #1
0
        public void ShowTutor2(TutorItem conf)
        {
            busy = true;

            info_2_panel.SetActive(true);
            description2.text = TextManager.getText(conf.text_id);
        }
Exemple #2
0
        void ShowTutor()
        {
            busy = true;

            Time.timeScale = 0.2f;

            TutorItem conf = tutor_items[0];

            var mask = Instantiate(mask_prefub, parent.transform, false);

            mask.name = "mask_" + UnityEngine.Random.Range(1000, 9999).ToString();
            mask.transform.localScale = new Vector3(1, 1, 1);
            mask.SetActive(true);
            var mask_comp = mask.GetComponentInChildren <SpriteMaskController>();

            mask_comp.tutor_event_name = conf.name;
            mask_comp.count            = conf.clicks;
            mask_comp.tutor_aim        = conf.aim;

            mask.transform.position = ResourcesController.get_instance().GetPositionByIndexAndType(conf.aim, conf.position_index);

            //(3.6 - 0.75, 5.5)
            if (conf.aim == TutorAim.CUSTOMER)
            {
                mask.transform.position = new Vector3(mask.transform.position.x + 2.85f, mask.transform.position.y + 5.5f, -1);
            }
            else
            {
                mask.transform.position = new Vector3(mask.transform.position.x, mask.transform.position.y, -1);
            }

            if (tutor_items[0].text_id != string.Empty)
            {
                description.text = TextManager.getText(tutor_items[0].text_id);
                info_panel.SetActive(true);
            }

            tutor_items.RemoveAt(0);
        }