Catch TeleportClause.COMMAND in the teleport listener.

Changed Teleport methods to pass a TeleportClause param
This commit is contained in:
ementalo 2011-12-07 01:12:36 +00:00
parent 854fc05c5b
commit 10597cec2f
19 changed files with 69 additions and 49 deletions

View file

@ -5,6 +5,7 @@ import com.earth2me.essentials.User;
import org.bukkit.Server;
import org.bukkit.command.CommandSender;
import org.bukkit.entity.Player;
import org.bukkit.event.player.PlayerTeleportEvent.TeleportCause;
public class Commandtpall extends EssentialsCommand
@ -43,7 +44,7 @@ public class Commandtpall extends EssentialsCommand
}
try
{
player.getTeleport().now(user, false);
player.getTeleport().now(user, false, TeleportCause.COMMAND);
}
catch (Exception ex)
{