From 659d602b5789fd999311e21a04455c120b9f31c8 Mon Sep 17 00:00:00 2001 From: GunfighterJ Date: Sun, 13 Jan 2013 17:02:46 -0600 Subject: Fixes /top command not carrying pitch and yaw --- Essentials/src/com/earth2me/essentials/commands/Commandtop.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtop.java b/Essentials/src/com/earth2me/essentials/commands/Commandtop.java index fe7690646..89c5c6f8f 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandtop.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandtop.java @@ -20,7 +20,9 @@ public class Commandtop extends EssentialsCommand { final int topX = user.getLocation().getBlockX(); final int topZ = user.getLocation().getBlockZ(); - final Location location = new Location(user.getWorld(), topX, user.getWorld().getMaxHeight(), topZ); + final float pitch = user.getLocation().getPitch(); + final float yaw = user.getLocation().getYaw(); + final Location location = new Location(user.getWorld(), topX, user.getWorld().getMaxHeight(), topZ, yaw, pitch); user.getTeleport().teleport(location, new Trade(this.getName(), ess), TeleportCause.COMMAND); user.sendMessage(_("teleportTop")); } -- cgit v1.2.3