Пример #1
0
        protected override IParent CreateParent(int numberOfChildren)
        {
            var parent = new SetParent();

            for (var i = 0; i < numberOfChildren; i++)
            {
                parent.Children.Add(new Child {
                    Name = "child" + i
                });
            }
            return(parent);
        }
Пример #2
0
    void OnTriggerEnter(Collider col)
    {
        IsCollision = true;

        SetParent boss = col.GetComponent <SetParent>();

        if (boss != null)
        {
            IsAttackBoss = true;
            ColBossObj   = col.gameObject;
        }

        //オブジェクトを消す
        Destroy(gameObject, 0.2f);
        Destroy(GameObject.Find("Shadow(Clone)"));
    }
Пример #3
0
        public virtual void OnActiveInEditor()
        {
            if (isActiveOnEditor && textObj != null)
            {
                return;
            }

            textObj      = new GameObject();
            textObj.name = "FuntionInstruction";
            textObj.transform.position = this.transform.position;
            textObj.tag = "EditorItem";
            SetParent.SteadyScale(textObj, gameObject);
            var text = textObj.AddComponent <TextMeshPro>();

            text.fontSize    = 1f;
            text.alignment   = TextAlignmentOptions.Center;
            text.color       = _textColor;
            text.text        = discription;
            isActiveOnEditor = true;
            _PaintOutline(textObj);
        }
 public SetParentTest()
 {
     this.processor = new SetParent();
 }
Пример #5
0
                // =================================
                // Functions.
                // =================================

                // ...

                void Start()
                {
                    sp = GetComponent <SetParent>();
                    ps = GetComponentInChildren <ParticleSystems.ParticleSystems>();
                }