Skip to content

Commit

Permalink
fix error with sidebars, fixes #1478
Browse files Browse the repository at this point in the history
  • Loading branch information
mcmonkey4eva committed Oct 2, 2016
1 parent 13557fc commit fbd13ec
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,15 @@ public Sidebar_v1_10_R1(Player player) {
super(player);
this.obj1 = new ScoreboardObjective(dummyScoreboard, "dummy_1", dummyCriteria);
this.obj2 = new ScoreboardObjective(dummyScoreboard, "dummy_2", dummyCriteria);
setDisplayName(title);
}

@Override
protected void setDisplayName(String title) {
this.obj1.setDisplayName(title);
this.obj2.setDisplayName(title);
if (this.obj1 != null) {
this.obj1.setDisplayName(title);
this.obj2.setDisplayName(title);
}
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,15 @@ public Sidebar_v1_8_R3(Player player) {
super(player);
this.obj1 = new ScoreboardObjective(dummyScoreboard, "dummy_1", dummyCriteria);
this.obj2 = new ScoreboardObjective(dummyScoreboard, "dummy_2", dummyCriteria);
setDisplayName(title);
}

@Override
protected void setDisplayName(String title) {
this.obj1.setDisplayName(title);
this.obj2.setDisplayName(title);
if (this.obj1 != null) {
this.obj1.setDisplayName(title);
this.obj2.setDisplayName(title);
}
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,15 @@ public Sidebar_v1_9_R2(Player player) {
super(player);
this.obj1 = new ScoreboardObjective(dummyScoreboard, "dummy_1", dummyCriteria);
this.obj2 = new ScoreboardObjective(dummyScoreboard, "dummy_2", dummyCriteria);
setDisplayName(title);
}

@Override
protected void setDisplayName(String title) {
this.obj1.setDisplayName(title);
this.obj2.setDisplayName(title);
if (this.obj1 != null) {
this.obj1.setDisplayName(title);
this.obj2.setDisplayName(title);
}
}

@Override
Expand Down

0 comments on commit fbd13ec

Please sign in to comment.