diff options
author | Bryson Steck <steck.bryson@gmail.com> | 2021-06-15 20:23:28 -0600 |
---|---|---|
committer | Bryson Steck <steck.bryson@gmail.com> | 2021-06-15 20:23:28 -0600 |
commit | 55fe6d900138477d3cd63b0d36b2219761546724 (patch) | |
tree | d90ff509243680f043f180074ff25a77a5beb3d5 /src/net/brysonsteck/Resurrection/commands/CommandResurrect.java | |
parent | a49057361f0e37f90de5f50f7172f04b0a2d389e (diff) | |
download | resurrection-55fe6d900138477d3cd63b0d36b2219761546724.tar resurrection-55fe6d900138477d3cd63b0d36b2219761546724.tar.gz resurrection-55fe6d900138477d3cd63b0d36b2219761546724.tar.bz2 |
added sounds to resurrection event
Diffstat (limited to 'src/net/brysonsteck/Resurrection/commands/CommandResurrect.java')
-rw-r--r-- | src/net/brysonsteck/Resurrection/commands/CommandResurrect.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/net/brysonsteck/Resurrection/commands/CommandResurrect.java b/src/net/brysonsteck/Resurrection/commands/CommandResurrect.java index 5e902e0..732221a 100644 --- a/src/net/brysonsteck/Resurrection/commands/CommandResurrect.java +++ b/src/net/brysonsteck/Resurrection/commands/CommandResurrect.java @@ -3,6 +3,7 @@ package net.brysonsteck.Resurrection.commands; import org.bukkit.Bukkit; import org.bukkit.ChatColor; import org.bukkit.GameMode; +import org.bukkit.Sound; import org.bukkit.command.Command; import org.bukkit.command.CommandExecutor; import org.bukkit.command.CommandSender; @@ -26,6 +27,9 @@ public class CommandResurrect implements CommandExecutor { for (PotionEffect effect : resurrectPlayer.getActivePotionEffects()) resurrectPlayer.removePotionEffect(effect.getType()); resurrectPlayer.setGameMode(GameMode.SURVIVAL); + for(Player player : Bukkit.getOnlinePlayers()){ + player.playSound(player.getLocation(), Sound.ENTITY_ENDER_DRAGON_GROWL, 1, 0); + } Bukkit.broadcastMessage(ChatColor.YELLOW +""+ ChatColor.BOLD + strings[0] + " has been resurrected manually by an admin!"); return true; } else { @@ -48,6 +52,9 @@ public class CommandResurrect implements CommandExecutor { for (PotionEffect effect : resurrectPlayer.getActivePotionEffects()) resurrectPlayer.removePotionEffect(effect.getType()); resurrectPlayer.setGameMode(GameMode.SURVIVAL); + for(Player player : Bukkit.getOnlinePlayers()){ + player.playSound(player.getLocation(), Sound.ENTITY_ENDER_DRAGON_GROWL, 1, 0); + } Bukkit.broadcastMessage(strings[0] + " has been resurrected manually by an admin!"); return true; } else { |