Examples of teleportTo()


Examples of net.canarymod.api.entity.living.humanoid.Player.teleportTo()

        if (player.hasPermission("canary.command.teleport.home.other")) {
            Player target = Canary.getServer().matchPlayer(args[1]);

            if (target != null) {
                if (target.hasHome()) {
                    target.teleportTo(target.getHome());
                }
                else {
                    player.notice(Translator.translateAndFormat("no home set other", target.getName()));
                }
            }
View Full Code Here

Examples of net.canarymod.api.entity.living.humanoid.Player.teleportTo()

        Player target = Canary.getServer().matchPlayer(args[1]);

        if (target != null) {
            Location l = block.getBlock().getLocation();
            l.setY(l.getY()+1);
            target.teleportTo(l, TeleportHook.TeleportCause.COMMAND);
            block.message(Colors.YELLOW + Translator.translateAndFormat("tphere success", target.getName()));
        }
        else {
            block.notice(Translator.translateAndFormat("unknown player", args[1]));
        }
View Full Code Here

Examples of net.canarymod.api.entity.living.humanoid.Player.teleportTo()

    private void player(Player player, String[] args) {
        Player target = Canary.getServer().matchPlayer(args[1]);

        if (target != null) {
            target.teleportTo(player.getLocation(), TeleportHook.TeleportCause.COMMAND);
            player.message(Colors.YELLOW + Translator.translateAndFormat("tphere success", target.getName()));
        }
        else {
            player.notice(Translator.translateAndFormat("unknown player", args[1]));
        }
View Full Code Here

Examples of net.canarymod.api.entity.living.humanoid.Player.teleportTo()

        else {
            Player player = Canary.getServer().matchPlayer(args[2]);
            World w = Canary.getServer().getWorld(args[1]);

            if (player != null && w != null) {
                player.teleportTo(w.getSpawnLocation());
                caller.notice(Translator.translateAndFormat("spawn success other", player.getName()));
            }
            else {
                caller.notice(Translator.translate("spawn failed console"));
            }
View Full Code Here

Examples of net.canarymod.api.entity.living.humanoid.Player.teleportTo()

        else {
            World w = Canary.getServer().getWorld(args[1]);
            Player target = Canary.getServer().matchPlayer(args[2]);

            if (target != null && w != null) {
                target.teleportTo(w.getSpawnLocation());
                player.message(Colors.YELLOW + Translator.translateAndFormat("spawn success other", player.getName()));
            }
        }
    }
View Full Code Here

Examples of org.bukkit.entity.Player.teleportTo()

      {
        if(ezp.getCurrentLocation() == null){ezp.setCurrentLocation(event.getFrom());}
        if(!PlayerWithinZoneLogic(player, ezp, playerHeight, playerPoint))
        {
          ezp.setIsTeleporting(true);
          player.teleportTo(ezp.getCurrentLocation());
          ezp.setIsTeleporting(false);
          event.setTo(ezp.getCurrentLocation());
          event.setCancelled(true);
        }
        else
View Full Code Here

Examples of org.bukkit.entity.Player.teleportTo()

        if(ezp.getEntityID() != player.getEntityId()){ezp.setEntityID(player.getEntityId());}
        if(ezp.getCurrentLocation() == null){ezp.setCurrentLocation(event.getFrom());}
        if(!PlayerWithinZoneLogic(player, ezp, playerHeight, playerPoint))
        {
          ezp.setIsTeleporting(true);
          player.teleportTo(ezp.getCurrentLocation());
          ezp.setIsTeleporting(false);
          event.setTo(ezp.getCurrentLocation());
          event.setCancelled(true);
        }
        {
View Full Code Here

Examples of org.bukkit.entity.Player.teleportTo()

        Player player = (Player)op;
       
        Location dest = groupHomes.getGroupHome(DEFAULT_SPAWN);
      if (dest != null) {
        ensureDest(dest);
        player.teleportTo(dest);
          return true;
      }
     
      dest = player.getWorld().getSpawnLocation();
     
View Full Code Here

Examples of org.bukkit.entity.Player.teleportTo()

      }
     
      dest = player.getWorld().getSpawnLocation();
     
      ensureDest(dest);
        player.teleportTo(dest);
        return true;
      }
  }

  private class SetSpawnCommand implements CommandHandler {
View Full Code Here

Examples of org.bukkit.entity.Player.teleportTo()

      {
        if(ezp.getCurrentLocation() == null){ezp.setCurrentLocation(event.getFrom());}
        if(!PlayerWithinZoneLogic(player, ezp, playerHeight, playerPoint))
        {
          ezp.setIsTeleporting(true);
          player.teleportTo(ezp.getCurrentLocation());
          ezp.setIsTeleporting(false);
          event.setTo(ezp.getCurrentLocation());
          event.setCancelled(true);
        }
        else
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.