private void Attack() { m_projectileHandler.fireRateDelayRemaining -= Time.deltaTime; if (m_projectileHandler.fireRateDelayRemaining <= 0f) { m_projectileHandler.CreateProjectile(transform.position, m_player.position); m_projectileHandler.fireRateDelayRemaining = m_projectileHandler.GetFireRate(); } }
private void AerialAttack() { m_projectileHandler.fireRateDelayRemaining -= Time.deltaTime; // Is the enemy ready to fire? if (m_projectileHandler.fireRateDelayRemaining <= 0f) { m_projectileHandler.CreateProjectile(transform.position, m_player.position); m_projectileHandler.fireRateDelayRemaining = m_projectileHandler.GetFireRate(); // Reset delay } }