summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsnowleo <schneeleo@gmail.com>2011-09-18 03:34:05 +0200
committersnowleo <schneeleo@gmail.com>2011-09-18 03:34:05 +0200
commitb6a2d7397d2246951d47d818184692f3e3cdd73f (patch)
tree3b59c610763ca2a3f515f802dbae31eacd4214a6
parent455c0034408ffb1f8f31a52187ce87cd4952cbbf (diff)
downloadEssentials-b6a2d7397d2246951d47d818184692f3e3cdd73f.tar
Essentials-b6a2d7397d2246951d47d818184692f3e3cdd73f.tar.gz
Essentials-b6a2d7397d2246951d47d818184692f3e3cdd73f.tar.lz
Essentials-b6a2d7397d2246951d47d818184692f3e3cdd73f.tar.xz
Essentials-b6a2d7397d2246951d47d818184692f3e3cdd73f.zip
Allow yaw & pitch in /tppos
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandtppos.java6
-rw-r--r--Essentials/src/plugin.yml2
2 files changed, 7 insertions, 1 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtppos.java b/Essentials/src/com/earth2me/essentials/commands/Commandtppos.java
index 0786f9cb9..ce7c369e4 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandtppos.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandtppos.java
@@ -26,6 +26,12 @@ public class Commandtppos extends EssentialsCommand
int y = Integer.parseInt(args[1]);
int z = Integer.parseInt(args[2]);
Location l = new Location(user.getWorld(), x, y, z);
+ if (args.length > 3) {
+ l.setYaw(Float.parseFloat(args[3]));
+ }
+ if (args.length > 4) {
+ l.setPitch(Float.parseFloat(args[4]));
+ }
Trade charge = new Trade(this.getName(), ess);
charge.isAffordableFor(user);
user.sendMessage(Util.i18n("teleporting"));
diff --git a/Essentials/src/plugin.yml b/Essentials/src/plugin.yml
index 2090e8484..24049354c 100644
--- a/Essentials/src/plugin.yml
+++ b/Essentials/src/plugin.yml
@@ -330,7 +330,7 @@ commands:
usage: /<command> <player>
tppos:
description: Teleport to coordinates.
- usage: /<command> <x> <y> <z>
+ usage: /<command> <x> <y> <z> [yaw] [pitch]
tptoggle:
description: Blocks all forms of teleportation.
usage: /<command>