summaryrefslogtreecommitdiffstats
path: root/Essentials/src/com/earth2me/essentials/commands/Commandtpo.java
diff options
context:
space:
mode:
Diffstat (limited to 'Essentials/src/com/earth2me/essentials/commands/Commandtpo.java')
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandtpo.java34
1 files changed, 34 insertions, 0 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtpo.java b/Essentials/src/com/earth2me/essentials/commands/Commandtpo.java
new file mode 100644
index 000000000..f3fa6900c
--- /dev/null
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandtpo.java
@@ -0,0 +1,34 @@
+package com.earth2me.essentials.commands;
+
+import org.bukkit.Server;
+import com.earth2me.essentials.Essentials;
+import com.earth2me.essentials.User;
+import com.earth2me.essentials.commands.EssentialsCommand;
+
+
+public class Commandtpo extends EssentialsCommand
+{
+ public Commandtpo()
+ {
+ super("tpo");
+ }
+
+ @Override
+ public void run(Server server, Essentials parent, User user, String commandLabel, String[] args) throws Exception
+ {
+ if (args.length < 1)
+ {
+ user.sendMessage("§c Usage: /tpo [playername]");
+ }
+ else
+ {
+ //Just basically the old tp command
+ User p = getPlayer(server, args, 0);
+ user.teleportCooldown();
+ user.charge(this);
+ user.teleportToNow(p);
+ user.sendMessage("§7Teleporting...");
+ }
+
+ }
+}