summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandtpaccept.java5
-rw-r--r--Essentials/src/plugin.yml2
2 files changed, 6 insertions, 1 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtpaccept.java b/Essentials/src/com/earth2me/essentials/commands/Commandtpaccept.java
index 0cece3310..2e3e024a3 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandtpaccept.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandtpaccept.java
@@ -26,6 +26,11 @@ public class Commandtpaccept extends EssentialsCommand
{
throw new Exception(_("noPendingRequest"));
}
+
+ if (args.length > 0 && !target.getName().contains(args[0]))
+ {
+ throw new Exception(_("noPendingRequest"));
+ }
long timeout = ess.getSettings().getTpaAcceptCancellation();
if (timeout != 0 && (System.currentTimeMillis() - user.getTeleportRequestTime()) / 1000 > timeout)
diff --git a/Essentials/src/plugin.yml b/Essentials/src/plugin.yml
index 7d8db28bb..0ec1ee6d9 100644
--- a/Essentials/src/plugin.yml
+++ b/Essentials/src/plugin.yml
@@ -348,7 +348,7 @@ commands:
aliases: [etpaall]
tpaccept:
description: Accepts a teleport request.
- usage: /<command>
+ usage: /<command> [otherplayer]
aliases: [tpyes,etpaccept,etpyes]
tpahere:
description: Request that the specified player teleport to you.