function checkForDeath(defenderHP) {
    if (defenderHP <= 0) {
      return false;
    } else { return true }
  }
// Checks whether the defender lost all their health points
Checks whether the defender lost all their health points
Checks whether the defender lost all their health points
function checkForDeath(defenderHP) {
    if (defenderHP <= 0) {
      return false;
    } else { return true }
  }
function checkForDeath ( defenderHP ) { if ( defenderHP <= 0 ) { return false ; } else { return true } }
Checks whether the defender lost all their health points
Checks whether the defender lost all their health points