From 49441cfaf4419f890c38abec3a7f86c5a61946df Mon Sep 17 00:00:00 2001 From: Shaun Bennett Date: Fri, 1 Apr 2016 10:47:21 +1100 Subject: [PATCH] PC-63 and PC-64 --- .../src/mineplex/game/clans/tutorial/Tutorial.java | 2 -- .../mineplex/game/clans/tutorial/objective/Objective.java | 5 ++++- .../game/clans/tutorial/objective/ObjectiveGoal.java | 3 +++ 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/Tutorial.java b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/Tutorial.java index a998d2556..f8d78c6fc 100644 --- a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/Tutorial.java +++ b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/Tutorial.java @@ -152,13 +152,11 @@ public abstract class Tutorial implements Listener, ObjectiveListener @Override public void onObjectiveStart(Player player, Objective objective) { - player.playSound(player.getLocation(), Sound.NOTE_PLING, 1f, 1f); } @Override public void onObjectivePlayerUpdate(Player player, Objective objective) { - player.playSound(player.getLocation(), Sound.NOTE_PLING, 1f, 1f); } private void finish(Player player) diff --git a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/objective/Objective.java b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/objective/Objective.java index 839a92901..4305ae4ed 100644 --- a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/objective/Objective.java +++ b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/objective/Objective.java @@ -7,6 +7,7 @@ import java.util.Set; import java.util.UUID; import org.bukkit.Bukkit; +import org.bukkit.Sound; import org.bukkit.entity.Player; import org.bukkit.event.HandlerList; import org.bukkit.event.Listener; @@ -201,7 +202,9 @@ public abstract class Objective showFinishMessage(player), _finishMessageDelay); + Bukkit.getServer().getScheduler().runTaskLater(getJavaPlugin(), () -> showFinishMessage(player), _finishMessageDelay); + + player.playSound(player.getEyeLocation(), Sound.LEVEL_UP, 1f, 1f); customFinish(player); diff --git a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/objective/ObjectiveGoal.java b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/objective/ObjectiveGoal.java index 43bfad084..b1031c084 100644 --- a/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/objective/ObjectiveGoal.java +++ b/Plugins/Mineplex.Game.Clans/src/mineplex/game/clans/tutorial/objective/ObjectiveGoal.java @@ -5,6 +5,7 @@ import java.util.Set; import java.util.UUID; import org.bukkit.Bukkit; +import org.bukkit.Sound; import org.bukkit.entity.Player; import org.bukkit.event.Listener; @@ -122,6 +123,8 @@ public abstract class ObjectiveGoal implements Listener Bukkit.getServer().getScheduler().runTaskLater(_objective.getJavaPlugin(), () -> displayFinishMessage(player), _finishMessageDelay); } + player.playSound(player.getEyeLocation(), Sound.ORB_PICKUP, 1f, 1f); + customFinish(player); _objective.completeGoal(this, player);