// Start is called before the first frame update void Start() { rb = gameObject.GetComponent <Rigidbody2D>(); cd = couldownAction; stats = gameObject.GetComponent <enemies_stats>(); }
// Start is called before the first frame update void Start() { rb = gameObject.GetComponent <Rigidbody2D>(); rb.velocity = new Vector2(speed, rb.velocity.y); stats = gameObject.GetComponent <enemies_stats>(); }