I have a Section of code that is compiling with the error of
"Not all code paths Return a Value"
I have no idea how to fix this. Any Ideas? Here is my code.
bool EnemyIsAlive()
{
searchCountdown -= Time.deltaTime;
if (searchCountdown <= 0f)
{
searchCountdown = 1f;
if (GameObject.FindGameObjectWithTag("Enemy") == null)
{
return false;
}
return true;
}
}