Examples of ExAutoSoulShot


Examples of lineage2.gameserver.network.serverpackets.ExAutoSoulShot

    }
    Set<Integer> activeSoulShots = player.getAutoSoulShot();
    for (int itemId : activeSoulShots)
    {
      player.removeAutoSoulShot(itemId);
      player.sendPacket(new ExAutoSoulShot(itemId, false));
    }
    ItemInstance weapon = player.getActiveWeaponInstance();
    if (weapon != null)
    {
      weapon.setChargedSpiritshot(ItemInstance.CHARGED_NONE);
View Full Code Here

Examples of lineage2.gameserver.network.serverpackets.ExAutoSoulShot

    if (old.getType() == ShortCut.TYPE_SKILL)
    {
      player.sendPacket(new ShortCutInit(player));
      for (int shotId : player.getAutoSoulShot())
      {
        player.sendPacket(new ExAutoSoulShot(shotId, true));
      }
    }
  }
View Full Code Here

Examples of lineage2.gameserver.network.serverpackets.ExAutoSoulShot

    player.sendPacket(new InventoryUpdate().addRemovedItem(item));
    item.setItemId(itemId);
    player.sendPacket(new ShortCutInit(player));
    for (int shotId : player.getAutoSoulShot())
    {
      player.sendPacket(new ExAutoSoulShot(shotId, true));
    }
    player.sendPacket(new InventoryUpdate().addNewItem(item));
    player.sendPacket(new SystemMessage2(SystemMsg.YOU_HAVE_EQUIPPED_YOUR_S1).addItemNameWithAugmentation(item));
    player.getInventory().equipItem(item);
  }
View Full Code Here

Examples of lineage2.gameserver.network.serverpackets.ExAutoSoulShot

    if (soulShotConsumption == 0)
    {
      if (isAutoSoulShot)
      {
        player.removeAutoSoulShot(SoulshotId);
        player.sendPacket(new ExAutoSoulShot(SoulshotId, false), new SystemMessage(SystemMessage.THE_AUTOMATIC_USE_OF_S1_WILL_NOW_BE_CANCELLED).addItemName(SoulshotId));
        return false;
      }
      player.sendPacket(Msg.CANNOT_USE_SOULSHOTS);
      return false;
    }
View Full Code Here

Examples of lineage2.gameserver.network.serverpackets.ExAutoSoulShot

    if (item.getCount() < 1)
    {
      if (isAutoSoulShot)
      {
        player.removeAutoSoulShot(FishshotId);
        player.sendPacket(new ExAutoSoulShot(FishshotId, false), new SystemMessage(SystemMessage.THE_AUTOMATIC_USE_OF_S1_WILL_NOW_BE_CANCELLED).addString(item.getName()));
        return false;
      }
      player.sendPacket(Msg.NOT_ENOUGH_SPIRITSHOTS);
      return false;
    }
View Full Code Here

Examples of lineage2.gameserver.network.serverpackets.ExAutoSoulShot

    if (blessedsoulSpiritConsumption == 0)
    {
      if (isAutoSoulShot)
      {
        player.removeAutoSoulShot(SoulshotId);
        player.sendPacket(new ExAutoSoulShot(SoulshotId, false), new SystemMessage(SystemMessage.THE_AUTOMATIC_USE_OF_S1_WILL_NOW_BE_CANCELLED).addItemName(spiritshotId));
        return false;
      }
      player.sendPacket(Msg.CANNOT_USE_SPIRITSHOTS);
      return false;
    }
    if (((grade == 0) && (spiritshotId != 3947)) || ((grade == 1) && (spiritshotId != 3948) && (spiritshotId != 22072)) || ((grade == 2) && (spiritshotId != 3949) && (spiritshotId != 22073)) || ((grade == 3) && (spiritshotId != 3950) && (spiritshotId != 22074)) || ((grade == 4) && (spiritshotId != 3951) && (spiritshotId != 22075)) || ((grade == 5) && (spiritshotId != 3952) && (spiritshotId != 22076)) || ((grade == 6) && (spiritshotId != 19442)))
    {
      if (isAutoSoulShot)
      {
        return false;
      }
      player.sendPacket(Msg.SPIRITSHOT_DOES_NOT_MATCH_WEAPON_GRADE);
      return false;
    }
    if (!player.getInventory().destroyItem(item, blessedsoulSpiritConsumption))
    {
      if (isAutoSoulShot)
      {
        player.removeAutoSoulShot(SoulshotId);
        player.sendPacket(new ExAutoSoulShot(SoulshotId, false), new SystemMessage(SystemMessage.THE_AUTOMATIC_USE_OF_S1_WILL_NOW_BE_CANCELLED).addItemName(spiritshotId));
        return false;
      }
      player.sendPacket(Msg.NOT_ENOUGH_SPIRITSHOTS);
      return false;
    }
View Full Code Here

Examples of lineage2.gameserver.network.serverpackets.ExAutoSoulShot

    if (soulSpiritConsumption == 0)
    {
      if (isAutoSoulShot)
      {
        player.removeAutoSoulShot(SoulshotId);
        player.sendPacket(new ExAutoSoulShot(SoulshotId, false), new SystemMessage(SystemMessage.THE_AUTOMATIC_USE_OF_S1_WILL_NOW_BE_CANCELLED).addItemName(SoulshotId));
        return false;
      }
      player.sendPacket(Msg.CANNOT_USE_SPIRITSHOTS);
      return false;
    }
    if (((grade == 0) && (SpiritshotId != 5790) && (SpiritshotId != 2509)) || ((grade == 1) && (SpiritshotId != 2510) && (SpiritshotId != 22077)) || ((grade == 2) && (SpiritshotId != 2511) && (SpiritshotId != 22078)) || ((grade == 3) && (SpiritshotId != 2512) && (SpiritshotId != 22079)) || ((grade == 4) && (SpiritshotId != 2513) && (SpiritshotId != 22080)) || ((grade == 5) && (SpiritshotId != 2514) && (SpiritshotId != 22081)) || ((grade == 6) && (SpiritshotId != 19441) && (SpiritshotId != 33787)))
    {
      if (isAutoSoulShot)
      {
        return false;
      }
      player.sendPacket(Msg.SPIRITSHOT_DOES_NOT_MATCH_WEAPON_GRADE);
      return false;
    }
    if (count < soulSpiritConsumption)
    {
      if (isAutoSoulShot)
      {
        player.removeAutoSoulShot(SoulshotId);
        player.sendPacket(new ExAutoSoulShot(SoulshotId, false), new SystemMessage(SystemMessage.THE_AUTOMATIC_USE_OF_S1_WILL_NOW_BE_CANCELLED).addItemName(SoulshotId));
        return false;
      }
      player.sendPacket(Msg.NOT_ENOUGH_SPIRITSHOTS);
      return false;
    }
View Full Code Here

Examples of lineage2.gameserver.network.serverpackets.ExAutoSoulShot

      setCurrentCp(newActiveSub.getCp());
      _shortCuts.restore();
      sendPacket(new ShortCutInit(this));
      for (int shotId : getAutoSoulShot())
      {
        sendPacket(new ExAutoSoulShot(shotId, true));
      }
      sendPacket(new SkillCoolTime(this));
      sendPacket(new ExSubjobInfo(this, false));
      broadcastPacket(new SocialAction(getObjectId(), SocialAction.LEVEL_UP));
      getDeathPenalty().restore(this);
View Full Code Here

Examples of lineage2.gameserver.network.serverpackets.ExAutoSoulShot

    sendPacket(new ExBasicActionList(this));
    sendSkillList();
    sendPacket(new ShortCutInit(this));
    for (int shotId : getAutoSoulShot())
    {
      sendPacket(new ExAutoSoulShot(shotId, true));
    }
    if(transformationId == 0)
    {
      if(isAwaking())
      {
View Full Code Here

Examples of net.sf.l2j.gameserver.serverpackets.ExAutoSoulShot

                  if (_itemId < 6535 || _itemId > 6540) {
                      // Attempt to charge first shot on activation
                      if (_itemId == 6645 || _itemId == 6646 || _itemId == 6647)
                      {
                          activeChar.addAutoSoulShot(_itemId);
                          ExAutoSoulShot atk = new ExAutoSoulShot(_itemId, _type);
                          activeChar.sendPacket(atk);

                          //start the auto soulshot use
                          SystemMessage sm = new SystemMessage(SystemMessageId.USE_OF_S1_WILL_BE_AUTO);
                          sm.addString(item.getItemName());
                          activeChar.sendPacket(sm);
                          sm = null;

                          activeChar.rechargeAutoSoulShot(true, true, true);
                      }
                      else {
                        if (activeChar.getActiveWeaponItem() != activeChar.getFistsWeaponItem()
                            && item.getItem().getCrystalType() == activeChar.getActiveWeaponItem().getCrystalType())
                        {
                          if (_itemId>=3947 && _itemId<=3952 && activeChar.isInOlympiadMode()){
                            SystemMessage sm = new SystemMessage(SystemMessageId.THIS_ITEM_IS_NOT_AVAILABLE_FOR_THE_OLYMPIAD_EVENT);
                            sm.addString(item.getItemName());
                            activeChar.sendPacket(sm);
                            sm = null;
                          }else{
                            activeChar.addAutoSoulShot(_itemId);
                            ExAutoSoulShot atk = new ExAutoSoulShot(_itemId, _type);
                            activeChar.sendPacket(atk);

                            // start the auto soulshot use
                            SystemMessage sm = new SystemMessage(SystemMessageId.USE_OF_S1_WILL_BE_AUTO);
                            sm.addString(item.getItemName());
                            activeChar.sendPacket(sm);
                            sm = null;

                            activeChar.rechargeAutoSoulShot(true, true, false);
                          }
                        }
                        else {
                          if ((_itemId >= 2509 && _itemId <= 2514) || (_itemId >= 3947 && _itemId <= 3952) || _itemId == 5790)
                            activeChar.sendPacket(new SystemMessage(SystemMessageId.SPIRITSHOTS_GRADE_MISMATCH));
                          else
                            activeChar.sendPacket(new SystemMessage(SystemMessageId.SOULSHOTS_GRADE_MISMATCH));
                        }
                      }
                    }
                }
                else if (_type == 0)
                {
                    activeChar.removeAutoSoulShot(_itemId);
                    ExAutoSoulShot atk = new ExAutoSoulShot(_itemId, _type);
                    activeChar.sendPacket(atk);

                    //cancel the auto soulshot use
                    SystemMessage sm = new SystemMessage(SystemMessageId.AUTO_USE_OF_S1_CANCELLED);
                    sm.addString(item.getItemName());
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.