Package l2p.gameserver.serverpackets

Examples of l2p.gameserver.serverpackets.MyTargetSelected


  }

  @Override
  public void onForcedAttack(L2Player player, boolean shift)
  {
    player.sendPacket(new MyTargetSelected(getObjectId(), player.getLevel() - getLevel()));
    if(!isAttackable(player) || player.isConfused() || player.isBlocked())
    {
      player.sendActionFailed();
      return;
    }
View Full Code Here


  public void onAction(L2Player player, boolean shift)
  {
    if(this != player.getTarget())
    {
      player.setTarget(this);
      player.sendPacket(new MyTargetSelected(getObjectId(), player.getLevel() - getLevel()), new ValidateLocation(this));
      if(isAutoAttackable(player))
      {
        player.sendPacket(makeStatusUpdate(StatusUpdate.CUR_HP, StatusUpdate.MAX_HP));
      }
      player.sendActionFailed();
      return;
    }
    player.sendPacket(new MyTargetSelected(getObjectId(), player.getLevel() - getLevel()));
    if(Events.onAction(player, this, shift))
    {
      return;
    }
    if(isAutoAttackable(player))
View Full Code Here

  public void onAction(L2Player player, boolean shift)
  {
    if(this != player.getTarget())
    {
      player.setTarget(this);
      player.sendPacket(new MyTargetSelected(getObjectId(), player.getLevel() - getLevel()), new ValidateLocation(this));
    }
    else
    {
      MyTargetSelected my = new MyTargetSelected(getObjectId(), player.getLevel() - getLevel());
      player.sendPacket(my);
      if(!isInRange(player, INTERACTION_DISTANCE))
      {
        player.getAI().setIntention(CtrlIntention.AI_INTENTION_INTERACT, this);
        player.sendActionFailed();
View Full Code Here

  public void onAction(L2Player player, boolean shift)
  {
    if(this != player.getTarget())
    {
      player.setTarget(this);
      player.sendPacket(new MyTargetSelected(getObjectId(), player.getLevel() - getLevel()), makeStatusUpdate(StatusUpdate.CUR_HP, StatusUpdate.MAX_HP), new ValidateLocation(this));
    }
    else
    {
      player.sendPacket(new MyTargetSelected(getObjectId(), player.getLevel() - getLevel()));
      if(isAutoAttackable(player))
      {
        player.getAI().Attack(this, false, shift);
      }
      else
View Full Code Here

  public void onAction(L2Player player, boolean shift)
  {
    if(player.getTarget() != this)
    {
      player.setTarget(this);
      player.sendPacket(new MyTargetSelected(getObjectId(), 0));
    }
    else if(isAutoAttackable(player))
    {
      player.getAI().Attack(this, false, shift);
    }
View Full Code Here

  public void onAction(L2Player player, boolean shift)
  {
    if(this != player.getTarget())
    {
      player.setTarget(this);
      player.sendPacket(new MyTargetSelected(getObjectId(), player.getLevel() - getLevel()));
      player.sendPacket(new ValidateLocation(this));
    }
    else
    {
      player.sendPacket(new MyTargetSelected(getObjectId(), player.getLevel() - getLevel()));
      if(!isInRange(player, INTERACTION_DISTANCE))
      {
        player.getAI().setIntention(CtrlIntention.AI_INTENTION_INTERACT, this);
        player.sendActionFailed();
      }
View Full Code Here

  public void onAction(L2Player player, boolean shift)
  {
    if(this != player.getTarget())
    {
      player.setTarget(this);
      MyTargetSelected my = new MyTargetSelected(getObjectId(), player.getLevel() - getLevel());
      player.sendPacket(my);
      player.sendPacket(new ValidateLocation(this));
    }
    else
    {
      MyTargetSelected my = new MyTargetSelected(getObjectId(), player.getLevel() - getLevel());
      player.sendPacket(my);
      if(!isInRange(player, INTERACTION_DISTANCE))
      {
        player.getAI().setIntention(CtrlIntention.AI_INTENTION_INTERACT, this);
      }
View Full Code Here

    if(player.getTarget() != this)
    {
      // Set the target of the player
      player.setTarget(this);
      // The color to display in the select window is White
      player.sendPacket(new MyTargetSelected(getObjectId(), 0), makeStatusUpdate(StatusUpdate.CUR_HP, StatusUpdate.MAX_HP));
    }
    else if(player == owner)
    {
      player.sendPacket(new PetInfo(this), new PetStatusShow(this), Msg.ActionFail);
    }
View Full Code Here

          }
          break;
      }
      if(actorStoredTarget != target)
      {
        actor.sendPacket(new MyTargetSelected(target.getObjectId(), 0));
      }
    }
  }
View Full Code Here

    @Override
    public void onAction(L2Player player, boolean shift) {
        if (player.getTarget() != this) {
            player.setTarget(this);
            if (player.getTarget() == this) {
                player.sendPacket(new MyTargetSelected(getObjectId(), player.getLevel() - getLevel()));
                if (isAutoAttackable(player)) {
                    player.sendPacket(makeStatusUpdate(StatusUpdate.CUR_HP, StatusUpdate.MAX_HP));
                }
            }
            player.sendPacket(new ValidateLocation(this), Msg.ActionFail);
View Full Code Here

TOP

Related Classes of l2p.gameserver.serverpackets.MyTargetSelected

Copyright © 2018 www.massapicom. 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.