mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2025-06-27 19:24:44 +02:00
Changed kraken default behavior
It will no longer broadcast chat messages globally by default, as well as strike lightning on it's target. Instead it will spawn explosion effects.
This commit is contained in:
@ -103,31 +103,31 @@ public class FishingManager extends SkillManager {
|
||||
|
||||
player.teleport(player.getTargetBlock(null, 100).getLocation(), TeleportCause.PLUGIN);
|
||||
|
||||
Location location = player.getLocation();
|
||||
|
||||
world.strikeLightningEffect(location);
|
||||
world.strikeLightningEffect(location);
|
||||
world.strikeLightningEffect(location);
|
||||
|
||||
String unleashMessage = AdvancedConfig.getInstance().getPlayerUnleashMessage();
|
||||
|
||||
if (!unleashMessage.isEmpty()) {
|
||||
player.sendMessage(unleashMessage);
|
||||
}
|
||||
|
||||
if (AdvancedConfig.getInstance().getKrakenGlobalSoundsEnabled()) {
|
||||
Location location = player.getLocation();
|
||||
boolean globalEffectsEnabled = AdvancedConfig.getInstance().getKrakenGlobalEffectsEnabled();
|
||||
|
||||
if (globalEffectsEnabled) {
|
||||
world.strikeLightningEffect(location);
|
||||
world.strikeLightningEffect(location);
|
||||
world.strikeLightningEffect(location);
|
||||
|
||||
world.playSound(location, Sound.GHAST_SCREAM, Misc.GHAST_VOLUME, Misc.getGhastPitch());
|
||||
mcMMO.p.getServer().broadcastMessage(ChatColor.RED + AdvancedConfig.getInstance().getServerUnleashMessage().replace("(PLAYER)", player.getDisplayName()));
|
||||
}
|
||||
else {
|
||||
world.createExplosion(location.getX(), location.getY(), location.getZ(), 0F, false, false);
|
||||
world.createExplosion(location.getX(), location.getY(), location.getZ(), 0F, false, false);
|
||||
world.createExplosion(location.getX(), location.getY(), location.getZ(), 0F, false, false);
|
||||
|
||||
player.playSound(location, Sound.GHAST_SCREAM, Misc.GHAST_VOLUME, Misc.getGhastPitch());
|
||||
}
|
||||
|
||||
String globalMessage = AdvancedConfig.getInstance().getServerUnleashMessage();
|
||||
|
||||
if (!globalMessage.isEmpty()) {
|
||||
mcMMO.p.getServer().broadcastMessage(ChatColor.RED + AdvancedConfig.getInstance().getServerUnleashMessage().replace("(PLAYER)", player.getDisplayName()));
|
||||
}
|
||||
|
||||
if (player.getItemInHand().getType() == Material.FISHING_ROD) {
|
||||
player.setItemInHand(null);
|
||||
}
|
||||
|
Reference in New Issue
Block a user