This method runs every 60 seconds (Bukkit time) and checks how much match time remains.
The following line rounds this down to the nearest minute:
long minutesRemaining = match.getTimeRemaining() / 60L;
minutesRemaining is then checked, and if it equals 0, the match ends. This can result in a match ending up to 1 minute early. For example, if the method runs when there are 59 seconds to go.
This method runs every 60 seconds (Bukkit time) and checks how much match time remains.
The following line rounds this down to the nearest minute:
minutesRemaining
is then checked, and if it equals 0, the match ends. This can result in a match ending up to 1 minute early. For example, if the method runs when there are 59 seconds to go.