Examples of addItem()


Examples of lineage2.gameserver.model.items.PcFreight.addItem()

        {
          continue;
        }
        ItemInstance item = inventory.removeItemByObjectId(_items[i], _itemQ[i]);
        Log.LogItem(player, Log.FreightDeposit, item);
        freight.addItem(item);
      }
    }
    catch (ArithmeticException ae)
    {
      player.sendPacket(SystemMsg.YOU_HAVE_EXCEEDED_THE_QUANTITY_THAT_CAN_BE_INPUTTED);
View Full Code Here

Examples of lineage2.gameserver.model.items.PcInventory.addItem()

                  }
                  if (augmentationId != 0)
                  {
                    product.setAugmentationId(augmentationId);
                  }
                  inventory.addItem(product);
                  activeChar.sendPacket(SystemMessage2.obtainItems(product));
                  break cycle1;
                 
                }
                chanceFrom += chance;
View Full Code Here

Examples of lineage2.gameserver.model.items.PetInventory.addItem()

    if (!pet.getInventory().validateCapacity(slots))
    {
      sendPacket(Msg.DUE_TO_THE_VOLUME_LIMIT_OF_THE_PETS_INVENTORY_NO_MORE_ITEMS_CAN_BE_PLACED_THERE);
      return;
    }
    petInventory.addItem(playerInventory.removeItemByObjectId(_objectId, _amount));
    pet.sendChanges();
    activeChar.sendChanges();
  }
}
View Full Code Here

Examples of lineage2.gameserver.model.items.Warehouse.addItem()

            if (oldOwner != null) {
                long amount = getTreasury();
                if (amount > 0) {
                    Warehouse warehouse = oldOwner.getWarehouse();
                    if (warehouse != null) {
                        warehouse.addItem(ItemTemplate.ITEM_ID_ADENA, amount);
                        addToTreasuryNoTax(-amount, false, false);
                        Log.add(getName() + "|" + -amount + "|Castle:changeOwner", "treasury");
                    }
                }
View Full Code Here

Examples of lmnd.model.command.CommandData.addItem()

                        dialog.dispose();
                        return;
                }
                CommandData data = new CommandData();
                Credentials credentials = dialog.getCredentials();
                data.addItem(Keys.CREDENTIALS, credentials);
                Collection<File> sources = getSourceFiles();
                data.addItem(Keys.SOURCE_FILES, sources);
                MessageData messageData = dialog.getMessageData();
                data.addItem(Keys.MESSAGE_DATA, messageData);
                // Create command.
View Full Code Here

Examples of logisticspipes.interfaces.routing.IDirectRoutingConnection.addItem()

    if(isConnectedInv(tile)) {
      if(hasRemoteConnection()) {
        CoreRoutedPipe CRP = SimpleServiceLocator.connectionManager.getConnectedPipe(getRouter());
        if(CRP instanceof IDirectRoutingConnection) {
          IDirectRoutingConnection pipe = (IDirectRoutingConnection) CRP;
          pipe.addItem(info);
          spawnParticle(Particles.OrangeParticle, 4);
        }
      }
    }
  }
View Full Code Here

Examples of lupos.rif.model.RuleList.addItem()

    result.setParent(argu);
    if (n.f2.which == 1) {
      List<INode> nodes = (List<INode>) n.f2.choice.accept(this, result);
      List<INode> terms = (List<INode>) nodes.get(0).accept(this, result);
      for (INode term : terms)
        result.addItem((IExpression) term.accept(this, result));
      // Tail anh�ngen
      if (((NodeOptional) nodes.get(1)).present()) {
        result.isOpen = true;
        result.addItem((IExpression) ((List<INode>) nodes.get(1)
            .accept(this, result)).get(1).accept(this, result));
View Full Code Here

Examples of mallemuck.model.command.CommandData.addItem()

    public void actionPerformed(ActionEvent event) {
        // Get directory name.
        Collection<File> sources = getSourceFiles();
        File destanation = getDestanationPath();
        CommandData data = new CommandData();
        data.addItem(Keys.SOURCE_FILES, sources);
        data.addItem(Keys.DEST_DIR, destanation);
        // Create command.
        Move move = new Move();
        try {
            move.perform(data);
View Full Code Here

Examples of model.Character.addItem()

  @Test
  public void Elixir() {
    System.out.println();
    Character Greg = new Archer("Greg");
    Greg.addItem(new Elixir());
    int initialHealth = Greg.getHealth();
    System.out.println("Before: " + Greg.inventoryToString());
    Greg.useItem(0);
    int finalHealth = Greg.getHealth();
    System.out.println("After: " + Greg.inventoryToString());
View Full Code Here

Examples of model.Mage.addItem()

    Character c3 = new Warrior("warrior");
    c4.setTarget(c3);
    c3.setTarget(c4);
    System.out.println(c4.statusToString());
    assertTrue(c4.getCurrentHealth() == 21);
    c4.addItem(new Elixir());
    c3.attack();
    System.out.println(c4.statusToString());
    assertTrue(c4.getCurrentHealth() == 15);
    c4.useItem(0);
    System.out.println(c4.statusToString());
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.