Exemplo n.º 1
0
  private void teleportToCharacter(Player activeChar, GameObject target) {
    if (target == null) return;

    activeChar.getAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE);
    activeChar.teleToLocation(target.getLoc(), target.getReflectionId());

    activeChar.sendMessage("You have teleported to " + target);
  }
Exemplo n.º 2
0
  private void teleportTo(Player activeChar, Player target, Location loc, int ref) {
    if (!target.equals(activeChar)) target.sendMessage("Admin is teleporting you.");

    target.getAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE);
    target.teleToLocation(loc, ref);

    if (target.equals(activeChar))
      activeChar.sendMessage("You have been teleported to " + loc + ", reflection id: " + ref);
  }