Package org.napile.primitive.sets

Examples of org.napile.primitive.sets.IntSet


   * Method openDoor.
   * @param npcId int
   */
  private void openDoor(int npcId)
  {
    IntSet set = doors.get(npcId);
    if (set != null)
    {
      for (int i : set.toArray())
      {
        DoorInstance doorToOpen = ReflectionUtils.getDoor(i);
        doorToOpen.openMe();
        ThreadPoolManager.getInstance().schedule(new DoorClose(doorToOpen), 120 * 1000L);
      }
 
View Full Code Here


        {
          Element subElement = subElementIterator.next();
          int itemId = Integer.parseInt(subElement.attributeValue("item_id"));
          int npcId2 = Integer.parseInt(subElement.attributeValue("npc_id"));
          int maxGuard = Integer.parseInt(subElement.attributeValue("max"));
          IntSet intSet = new HashIntSet(3);
          String[] ssq = subElement.attributeValue("ssq").split(";");
          for (String q : ssq)
          {
            if (q.equalsIgnoreCase("cabal_null"))
            {
              intSet.add(0);
            }
          }
          ((Castle) residence).addMerchantGuard(new MerchantGuard(itemId, npcId2, maxGuard, intSet));
        }
      }
View Full Code Here

   * @return int[] * @see lineage2.gameserver.handler.items.IItemHandler#getItemIds()
   */
  @Override
  public final int[] getItemIds()
  {
    final IntSet set = new HashIntSet(100);
    final Collection<Castle> castles = ResidenceHolder.getInstance().getResidenceList(Castle.class);
    for (Castle c : castles)
    {
      set.addAll(c.getMerchantGuards().keySet());
    }
    return set.toArray();
  }
View Full Code Here

TOP

Related Classes of org.napile.primitive.sets.IntSet

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.