Package net.sf.l2j.gameserver.model.actor.instance

Examples of net.sf.l2j.gameserver.model.actor.instance.L2PcInstance.sendPacket()


        // Charge Blessed Spiritshot
        weaponInst.setChargedSpiritshot(L2ItemInstance.CHARGED_BLESSED_SPIRITSHOT);

        // Send message to client
        activeChar.sendPacket(new SystemMessage(SystemMessageId.ENABLED_SPIRITSHOT));
        Broadcast.toSelfAndKnownPlayersInRadius(activeChar, new MagicSkillUser(activeChar, activeChar, SKILL_IDS[weaponGrade], 1, 0, 0), 360000/*600*/);
  }

  @Override
  public int[] getItemIds()
View Full Code Here


          player.sendPacket(sm);
          break;
        case 1:
          sm = new SystemMessage(SystemMessageId.S1S_REMAINING_MANA_IS_NOW_1);
          sm.addString(getItemName());
          player.sendPacket(sm);
          break;
      }

      if (_mana == 0) // The life time has expired
      {
View Full Code Here

      if (_mana == 0) // The life time has expired
      {
        sm = new SystemMessage(SystemMessageId.S1S_REMAINING_MANA_IS_NOW_0);
        sm.addString(getItemName());
        player.sendPacket(sm);

        // unequip
        if (isEquipped())
        {
          L2ItemInstance[] unequiped = player.getInventory().unEquipItemInSlotAndRecord(getEquipSlot());
View Full Code Here

          for (int i = 0; i < unequiped.length; i++)
          {
            player.checkSSMatch(null, unequiped[i]);
            iu.addModifiedItem(unequiped[i]);
          }
          player.sendPacket(iu);
        }

        if (getLocation() != ItemLocation.WAREHOUSE)
        {
          // destroy
View Full Code Here

          player.getInventory().destroyItem("L2ItemInstance", this, player, null);

          // send update
          InventoryUpdate iu = new InventoryUpdate();
          iu.addRemovedItem(this);
          player.sendPacket(iu);

          StatusUpdate su = new StatusUpdate(player.getObjectId());
          su.addAttribute(StatusUpdate.CUR_LOAD, player.getCurrentLoad());
          player.sendPacket(su);
View Full Code Here

          iu.addRemovedItem(this);
          player.sendPacket(iu);

          StatusUpdate su = new StatusUpdate(player.getObjectId());
          su.addAttribute(StatusUpdate.CUR_LOAD, player.getCurrentLoad());
          player.sendPacket(su);

        }
        else
        {
          player.getWarehouse().destroyItem("L2ItemInstance", this, player, null);
View Full Code Here

        }
        if (getLocation() != ItemLocation.WAREHOUSE)
        {
          InventoryUpdate iu = new InventoryUpdate();
          iu.addModifiedItem(this);
          player.sendPacket(iu);
        }
      }
    }
  }
View Full Code Here

                L2ItemInstance spb = player.getInventory().getItemByItemId(spbId);

                if (spb == null)// Haven't spellbook
                {
                  player.sendPacket(new SystemMessage(SystemMessageId.YOU_DONT_HAVE_ALL_OF_THE_ITEMS_NEEDED_TO_ENCHANT_THAT_SKILL));
                  return;
                }
                // ok
                player.destroyItem("Consume", spb, trainer, true);
              }
View Full Code Here

              }
          }
          else
          {
            SystemMessage sm = new SystemMessage(SystemMessageId.YOU_DONT_HAVE_ENOUGH_EXP_TO_ENCHANT_THAT_SKILL);
              player.sendPacket(sm);
            return;
          }
        }
        else
        {
View Full Code Here

          }
        }
        else
        {
          SystemMessage sm = new SystemMessage(SystemMessageId.YOU_DONT_HAVE_ENOUGH_SP_TO_ENCHANT_THAT_SKILL);
          player.sendPacket(sm);
          return;
        }
        if (Rnd.get(100) <= _rate)
        {
          player.addSkill(skill, true);
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.