// *********************************************************************** // Assembly : Game // Author : Kimch // Created : 2020-09-02 // Description : // Last Modified By : // Last Modified On : // *********************************************************************** // // // *********************************************************************** using UnityEngine; namespace G { public class RiseAttack : MonoBehaviour { public float emitfinish_time; public float destroy_time; public float movespeed; private Collider _collider; private void Awake() { _collider = this.GetComponent(); } private void OnEnable() { Invoke(nameof(EmitFinish), emitfinish_time); Invoke(nameof(DestroyEmitter), destroy_time); _collider.enabled = true; //base.particleEmitter().emit = true; } public void EmitFinish() { //base.particleEmitter().emit = false; _collider.enabled = false; } public void DestroyEmitter() { this.gameObject.SetActive(false); } private void Update() { transform.position += transform.up * (Time.deltaTime * movespeed); } } }