Skip to content

Commit

Permalink
Merge pull request #6 from PhilippvK/issue2-fix-transitions
Browse files Browse the repository at this point in the history
fix track transistion bug (#2)
  • Loading branch information
PhilippvK authored Mar 25, 2020
2 parents 433cf02 + b7b1555 commit ace616c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions server/src/org/moparforia/server/game/gametypes/GolfGame.java
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ protected boolean checkRecord() {
}

Track track = tracks.get(currentTrack);
if (track.getFirstBestPlayer().equals("") || track.getBestPar() > getLeadingPar()) { // first ever record OR beat previous
if ("".equals(track.getFirstBestPlayer()) || track.getBestPar() > getLeadingPar()) { // first ever record OR beat previous
TrackManager.updateStats(track, getLeadingPlayer(), getLeadingPar(), true);
return true;
} else if (track.getBestPar() == getLeadingPar()) { // matched par, latest
Expand Down Expand Up @@ -307,4 +307,4 @@ public String getGameString() {
waterEvent, collision, trackScoring, trackScoringEnd, getPlayers().size());
}

}
}

0 comments on commit ace616c

Please sign in to comment.