Skip to content

Commit

Permalink
Use scheduleWithFixedDelay instead of scheduleAtFixedRate (#180)
Browse files Browse the repository at this point in the history
  • Loading branch information
OliverSchlueter authored Jan 5, 2025
1 parent 4d16195 commit 1a3aa80
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ void initializeTasks() {
}
}, 50, 1000, TimeUnit.MILLISECONDS);

hologramThread.scheduleAtFixedRate(() -> {
hologramThread.scheduleWithFixedDelay(() -> {
final var time = System.currentTimeMillis();

for (final var hologram : getHolograms()) {
Expand Down Expand Up @@ -303,7 +303,7 @@ public void syncHologramWithNpc(@NotNull final Hologram hologram) {

final var npcScale = npc.getData().getScale();

if(hologram.getData() instanceof DisplayHologramData displayData) {
if (hologram.getData() instanceof DisplayHologramData displayData) {
displayData.setScale(new Vector3f(npcScale));
}

Expand Down

0 comments on commit 1a3aa80

Please sign in to comment.