1
0
mirror of https://github.com/essentials/Essentials.git synced 2025-08-12 09:35:26 +02:00

[trunk] add optional playername param to home. Players with "essentials.homes.others" permission can teleport to other players homes.

git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1243 e251c2fe-e539-e718-e476-b85c1f46cddb
This commit is contained in:
ementalo
2011-04-19 10:49:17 +00:00
parent 7ad287d215
commit 4c7bd8c96a
2 changed files with 6 additions and 1 deletions

View File

@@ -16,6 +16,11 @@ public class Commandhome extends EssentialsCommand
{ {
user.canAfford(this); user.canAfford(this);
user.teleportCooldown(); user.teleportCooldown();
if(args.length > 1 && user.isAuthorized("essentials.home.others"))
{
user.teleportToHome(args[0]);
return;
}
user.teleportToHome(this.getName()); user.teleportToHome(this.getName());
} }
} }

View File

@@ -92,7 +92,7 @@ commands:
usage: /<command> [message] usage: /<command> [message]
home: home:
description: Teleport to your home. description: Teleport to your home.
usage: /<command> usage: /<command> <player>
info: info:
description: Shows information set by the server owner description: Shows information set by the server owner
usage: /<command> [chapter] [page] usage: /<command> [chapter] [page]