Package lineage2.gameserver.network.serverpackets

Examples of lineage2.gameserver.network.serverpackets.StatusUpdate


   */
  @Override
  protected void onEvtDead(Creature killer)
  {
    final NpcInstance actor = getActor();
    actor.broadcastPacket(new PlaySound(PlaySound.Type.MUSIC, "BS02_D", 1, 0, actor.getLoc()));
    Functions.npcSay(actor, "A fatal error has occurred");
    Functions.npcSay(actor, "System is being shut down...");
    Functions.npcSay(actor, "......");
    try
    {
View Full Code Here


  {
    if (npcId != actor.getDisplayId())
    {
      actor.setDisplayId(npcId);
      DeleteObject d = new DeleteObject(actor);
      L2GameServerPacket su = new StatusUpdate(actor).addAttribute(StatusUpdateField.CUR_HP, StatusUpdateField.MAX_HP);
      for (Player player : World.getAroundPlayers(actor))
      {
        player.sendPacket(d, new NpcInfo(actor, player));
        if (player.getTarget() == actor)
        {
View Full Code Here

  {
    if (!needStatusUpdate())
    {
      return;
    }
    StatusUpdate statusUpdatePacket = new StatusUpdate(this).addAttribute(StatusUpdateField.CUR_HP, StatusUpdateField.MAX_HP);

    for(final Player pla : World.getAroundPlayers(this))
    {
      if(pla == null)
      {
View Full Code Here

      NpcInstance npc = NpcUtils.spawnSingle(transformer, actor.getLoc(), actor.getReflection());
      if ((killer != null) && killer.isPlayable())
      {
        npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, killer, 100);
        killer.setTarget(npc);
        killer.sendPacket(new StatusUpdate(npc).addAttribute(StatusUpdateField.CUR_HP, StatusUpdateField.MAX_HP));
      }
    }
    super.onEvtDead(killer);
  }
View Full Code Here

        npc.spawnMe(npc.getSpawnedLoc());
        npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, attacker, 100);
        actor.doDie(actor);
        actor.decayMe();
        attacker.setTarget(npc);
        attacker.sendPacket(new StatusUpdate(npc).addAttribute(StatusUpdateField.CUR_HP, StatusUpdateField.MAX_HP));
        return;
      }
    }
    Player player = attacker.getPlayer();
    if (player != null)
View Full Code Here

  @Override
  public void broadcastStatusUpdate()
  {
    super.broadcastStatusUpdate();

    sendPacket(new StatusUpdate(this).addAttribute(StatusUpdateField.CUR_HP, StatusUpdateField.CUR_MP, StatusUpdateField.CUR_CP, StatusUpdateField.MAX_HP, StatusUpdateField.MAX_MP, StatusUpdateField.MAX_CP));
    if(isInParty())
    // Send the Server->Client packet PartySmallWindowUpdate with current HP, MP and Level to all other L2Player of the Party
    {
      getParty().broadcastToPartyMembers(this, new PartySmallWindowUpdate(this));
    }
View Full Code Here

    if ((fields.length == 0) || (entering && !broadCast))
    {
      return;
    }
   
    StatusUpdate su = new StatusUpdate(this).addAttribute(fields);

    if(su.isEmpty())
    {
      return;
    }

    List<L2GameServerPacket> packets = new ArrayList<L2GameServerPacket>(withPet ? 4 : 1);
    if (withPet)
    {
      for (Summon summon : getSummonList())
      {
        packets.add(new StatusUpdate(summon).addAttribute(fields));
      }
    }
    packets.add(su);
    if (!broadCast)
    {
View Full Code Here

      {
        ((Creature) newTarget).addStatusListener(this);

        if(newTarget.displayHpBar())
        {
          sendPacket(new StatusUpdate(((Creature) newTarget)).addAttribute(StatusUpdateField.MAX_HP, StatusUpdateField.CUR_HP));
        }
      }

      updateTargetSelectionInfo(newTarget);
      broadcastPacketToOthers(new TargetSelected(getObjectId(), newTarget.getObjectId(), getLoc()));
View Full Code Here

          break;
        case 30:
        case 20:
        case 10:
        case 5:
          Announcements.getInstance().announceToAll(new SystemMessage(SystemMessage.THE_SERVER_WILL_BE_COMING_DOWN_IN_S1_SECONDS__PLEASE_FIND_A_SAFE_PLACE_TO_LOG_OUT).addNumber(shutdownCounter));
          break;
        case 0:
          switch (shutdownMode)
          {
            case SHUTDOWN:
View Full Code Here

            spawnRoom(7);
            setReenterTime(System.currentTimeMillis());
            for(Player p : getPlayers())
            {
              p.sendPacket(new ExSendUIEvent(p, 1, 1, 0, 0));
              p.sendPacket(new SystemMessage(SystemMessage.THIS_DUNGEON_WILL_EXPIRE_IN_S1_MINUTES).addNumber(5));
            }
            startCollapseTimer(5 * 60 * 1000L);
            timeSpent = (int) (System.currentTimeMillis() - _savedTime) / 1000;
          }
        }, 10000L);
View Full Code Here

TOP

Related Classes of lineage2.gameserver.network.serverpackets.StatusUpdate

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.