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); }
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)")); }
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(); }
// ================================= // Functions. // ================================= // ... void Start() { sp = GetComponent <SetParent>(); ps = GetComponentInChildren <ParticleSystems.ParticleSystems>(); }