Example #1
0
 public boolean isEndOfGame() {
   return (leftTeam.getScore() >= gameLength.getPoints()
           || rightTeam.getScore() >= gameLength.getPoints())
       && !isOvertime();
 }
Example #2
0
 public boolean isOvertime() {
   return (leftTeam.getScore() >= gameLength.getPoints()
           || rightTeam.getScore() >= gameLength.getPoints())
       && Math.abs(leftTeam.getScore() - rightTeam.getScore()) < 2;
 }