fixed ssm enderman always facing south on teleport
This commit is contained in:
parent
61df87b446
commit
ed96c8e3b3
@ -13,10 +13,10 @@ import org.bukkit.event.player.PlayerQuitEvent;
|
||||
|
||||
import mineplex.core.common.util.C;
|
||||
import mineplex.core.common.util.UtilParticle;
|
||||
import mineplex.core.common.util.UtilServer;
|
||||
import mineplex.core.common.util.UtilTextMiddle;
|
||||
import mineplex.core.common.util.UtilParticle.ParticleType;
|
||||
import mineplex.core.common.util.UtilParticle.ViewDist;
|
||||
import mineplex.core.common.util.UtilServer;
|
||||
import mineplex.core.common.util.UtilTextMiddle;
|
||||
import mineplex.core.recharge.Recharge;
|
||||
import mineplex.core.updater.UpdateType;
|
||||
import mineplex.core.updater.event.UpdateEvent;
|
||||
@ -41,6 +41,9 @@ public class PerkEndermanTeleport extends SmashPerk
|
||||
if (event.getType() != UpdateType.TICK)
|
||||
return;
|
||||
|
||||
if(!Manager.GetGame().IsLive())
|
||||
return;
|
||||
|
||||
for (Player player : UtilServer.getPlayers())
|
||||
{
|
||||
if (!Kit.HasKit(player))
|
||||
@ -88,7 +91,7 @@ public class PerkEndermanTeleport extends SmashPerk
|
||||
}
|
||||
|
||||
player.playSound(player.getLocation(), Sound.ENDERMAN_TELEPORT, 1f, 0.5f);
|
||||
player.teleport(block.getLocation().add(0.5, 1, 0.5));
|
||||
player.teleport(block.getLocation().add(0.5, 1, 0.5).setDirection(player.getLocation().getDirection()));
|
||||
player.playSound(player.getLocation(), Sound.ENDERMAN_TELEPORT, 1f, 0.5f);
|
||||
|
||||
UtilParticle.PlayParticle(ParticleType.WITCH_MAGIC, player.getLocation().add(0, 1, 0), 1f, 1f, 1f, 0.1f, 100, ViewDist.LONG, UtilServer.getPlayers());
|
||||
|
Loading…
Reference in New Issue
Block a user