@Override
    public void applyScores(Map<String, Integer> scores) {
        Objects.requireNonNull(scores, "scores");

        Set<String> toRemove = new HashSet<>(getScores().keySet());
        for (Map.Entry<String, Integer> score : scores.entrySet()) {
            toRemove.remove(trimScore(Text.colorize(score.getKey())));
        }
        for (String name : toRemove) {
            removeScore(name);
        }
        for (Map.Entry<String, Integer> score : scores.entrySet()) {
            setScore(score.getKey(), score.getValue());
        }
    }
Creates a new scoreboard objective

@param id the id of this objective
@param displayName the initial display name
@param displaySlot the initial display slot
helper/src/main/java/me/lucko/helper/scoreboard/PacketScoreboardObjective.java