Add API for resetting a single score

It was only possible to reset all scores for a specific entry, instead of resetting only specific scores.
This commit is contained in:
booky10 2021-11-05 21:01:36 +01:00
parent 4e20ba8bf7
commit ef5b6401b3

View File

@ -66,4 +66,12 @@ final class CraftScore implements Score {
public CraftScoreboard getScoreboard() {
return this.objective.getScoreboard();
}
// Paper start
@Override
public void resetScore() {
Scoreboard board = this.objective.checkState().board;
board.resetSinglePlayerScore(entry, this.objective.getHandle());
}
// Paper end
}