protected virtual void HitBloon(BloonController bloonToHit) { _bloonHitsRemaining--; if (_bloonHitsRemaining <= 0) { DestroyHazard(); } }
public static Vector3 First(IReadOnlyList <BloonController> bloons) { var furthestBloon = bloons[0]; for (var i = 1; i < bloons.Count; i++) { furthestBloon = BloonController.CompareGreaterPathProgress(furthestBloon, bloons[i]); } return(furthestBloon.transform.position); }
public static Vector3 Weakest(IReadOnlyList <BloonController> bloons) { var weakestBloon = bloons[0]; for (var i = 1; i < bloons.Count; i++) { weakestBloon = BloonController.CompareWeakest(weakestBloon, bloons[i]); } return(weakestBloon.transform.position); }
public static Vector3 Last(IReadOnlyList <BloonController> bloons) { var lastBloon = bloons[0]; for (var i = 1; i < bloons.Count; i++) { lastBloon = BloonController.CompareLeastPathProgress(lastBloon, bloons[i]); } return(lastBloon.transform.position); }
private void SetupBloonEvents(BloonController bloonController) { bloonController.OnBloonReachedEndOfPath += BloonEndOfPath; bloonController.OnBloonPopped += BloonPopped; }