private void Attack() { if (Input.GetMouseButtonDown(0) && Time.time - lastAttackTime >= 100 / attackSpeed) { lastAttackTime = Time.time; GunBullet newBullet = Instantiate(bulletPrefab, bulletPoint.position, bulletPoint.rotation, bulletPoint.transform.parent); newBullet.SetDamage(ATK); newBullet.Fire(); } }