-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added %parkour_topfirstplaces_(position)% & %parkour_player_total_fir…
…stplaces% placeholders
- Loading branch information
Showing
8 changed files
with
154 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
src/main/java/io/github/a5h73y/parkour/database/FirstPlacesEntry.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package io.github.a5h73y.parkour.database; | ||
|
||
import io.github.a5h73y.parkour.utility.PlayerUtils; | ||
|
||
public class FirstPlacesEntry { | ||
|
||
private final String playerId; | ||
private final int total; | ||
|
||
private String playerName; | ||
|
||
public FirstPlacesEntry(String playerId, int total) { | ||
this.playerId = playerId; | ||
this.total = total; | ||
} | ||
|
||
public String getPlayerName() { | ||
if (playerName == null) { | ||
playerName = PlayerUtils.findPlayerName(this.playerId); | ||
} | ||
return playerName; | ||
} | ||
|
||
public String getPlayerId() { | ||
return playerId; | ||
} | ||
|
||
public int getTotal() { | ||
return total; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters