Examples of broadcastUserInfo()

  • l2p.gameserver.model.L2Player.broadcastUserInfo()
    Отправляет UserInfo даному игроку и CharInfo всем окружающим.

    Концепт :

    Сервер шлет игроку UserInfo. Сервер вызывает метод {@link L2Player#broadcastPacketToOthers(l2p.gameserver.serverpackets.L2GameServerPacket)} для рассылки CharInfo

    Действия :

  • Отсылка игроку UserInfo(личные и общие данные)
  • Отсылка другим игрокам CharInfo(Public data only)


  • Внимание : НЕ ПОСЫЛАЙТЕ UserInfo другим игрокам либо CharInfo даному игроку.
    НЕ ВЫЗЫВАЕЙТЕ ЭТОТ МЕТОД КРОМЕ ОСОБЫХ ОБСТОЯТЕЛЬСТВ(смена сабкласса к примеру)!!! Траффик дико кушается у игроков и начинаются лаги.
    Используйте метод {@link l2p.gameserver.model.L2Player#sendChanges()}


  • l2p.gameserver.model.instances.L2NpcInstance.broadcastUserInfo()
  • lineage2.gameserver.model.Player.broadcastUserInfo()
    Method broadcastUserInfo. @param force boolean
  • net.sf.l2j.gameserver.model.L2Character.broadcastUserInfo()
  • net.sf.l2j.gameserver.model.actor.instance.L2PcInstance.broadcastUserInfo()
    Send a Server->Client packet UserInfo to this L2PcInstance and CharInfo to all L2PcInstance in its _KnownPlayers.
    Concept :
    Others L2PcInstance in the detection area of the L2PcInstance are identified in _knownPlayers. In order to inform other players of this L2PcInstance state modifications, server just need to go through _knownPlayers to send Server->Client Packet
    Actions :
  • Send a Server->Client packet UserInfo to this L2PcInstance (Public and Private Data)
  • Send a Server->Client packet CharInfo to all L2PcInstance in _KnownPlayers of the L2PcInstance (Public data only)

  • Caution : DON'T SEND UserInfo packet to other players instead of CharInfo packet. Indeed, UserInfo packet contains PRIVATE DATA as MaxHP, STR, DEX...

    Examples of com.l2jfrozen.gameserver.model.actor.instance.L2PcInstance.broadcastUserInfo()

        }
       
        if (_count <= 0)
        {
          player.setPrivateStoreType(L2PcInstance.STORE_PRIVATE_NONE);
          player.broadcastUserInfo();
          return;
        }
       
        if (player.isProcessingTransaction())
        {
    View Full Code Here

    Examples of l2p.gameserver.model.L2Player.broadcastUserInfo()

          player.getInventory().unEquipItemInSlot(armorType);
          itemInstance.setEnchantLevel(ench);
          player.getInventory().equipItem(itemInstance, true);
          // send packets
          player.sendPacket(new InventoryUpdate().addModifiedItem(itemInstance));
          player.broadcastUserInfo(true);
          // informations
          activeChar.sendMessage("Changed enchantment of " + player.getName() + "'s " + itemInstance.getName() + " from " + curEnchant + " to " + ench + ".");
          player.sendMessage("Admin has changed the enchantment of your " + itemInstance.getName() + " from " + curEnchant + " to " + ench + ".");
          if(activeChar != player && ench >= (itemInstance.getItem().getType2() == L2Item.TYPE2_WEAPON ? 6 : 5))
          {
    View Full Code Here

    Examples of l2p.gameserver.model.instances.L2NpcInstance.broadcastUserInfo()

                  actor.addStatFunc(new FuncMul(Stats.MAGIC_ATTACK_SPEED, 0x40, this, 5));
                  actor.addStatFunc(new FuncMul(Stats.MAGIC_DAMAGE, 0x40, this, 10));
                  actor.addStatFunc(new FuncMul(Stats.PHYSICAL_DAMAGE, 0x40, this, 10));
                  actor.addStatFunc(new FuncMul(Stats.RUN_SPEED, 0x40, this, 3));
                  actor.addSkill(SkillTable.getInstance().getInfo(1467, 1));
                  actor.broadcastUserInfo(true);
                  step_stage2 = 4;
                  return true;
                case 4:
                  setIntention(CtrlIntention.AI_INTENTION_ATTACK, null);
                  return true;
    View Full Code Here

    Examples of lineage2.gameserver.model.Player.broadcastUserInfo()

          st.giveItems(9627, 1);
          st.takeItems(DeadSoldierOrbs, -1);
          st.setState(COMPLETED);
          st.exitCurrentQuest(false);
          st.playSound(SOUND_FINISH);
          player.broadcastUserInfo();
          player.sendPacket(new ExShowScreenMessage(NpcString.CONGRATULATIONS_YOU_WILL_NOW_GRADUATE_FROM_THE_CLAN_ACADEMY_AND_LEAVE_YOUR_CURRENT_CLAN_AS_A_GRADUATE_OF_THE_ACADEMY_YOU_CAN_IMMEDIATELY_JOIN_A_CLAN_AS_A_REGULAR_MEMBER_WITHOUT_BEING_SUBJECT_TO_ANY_PENALTIES, 10000, ScreenMessageAlign.MIDDLE_CENTER, true));
          return StartNPC + "-7.htm";
        }
        return htmltext;
    View Full Code Here

    Examples of net.sf.l2j.gameserver.model.L2Character.broadcastUserInfo()

          try
          {
            for (L2PcInstance player : activeChar.getKnownList().getKnownPlayers().values())
            {
              player.setTeam(0);
              player.broadcastUserInfo();
            }
          }
          catch (Exception e){}
        }
        else if (command.startsWith("admin_setteam_close"))
    View Full Code Here

    Examples of net.sf.l2j.gameserver.model.L2Character.broadcastUserInfo()

                {
                  SystemMessage sm = new SystemMessage(SystemMessageId.S1_S2);
                  sm.addString("You have joined team " + teamVal);
                  player.sendPacket(sm);
                }
                player.broadcastUserInfo();
              }
            }
          }
          catch (Exception e)
          {
    View Full Code Here

    Examples of net.sf.l2j.gameserver.model.L2Character.broadcastUserInfo()

          {
            SystemMessage sm = new SystemMessage(SystemMessageId.S1_S2);
            sm.addString("You have joined team " + teamVal);
            player.sendPacket(sm);
          }
          player.broadcastUserInfo();
        }
        else if (command.startsWith("admin_social"))
        {
          try
          {
    View Full Code Here

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

        L2PcInstance player = getClient().getActiveChar();
        if (player == null)
            return;

        player.setPrivateStoreType(L2PcInstance.STORE_PRIVATE_NONE);
        player.broadcastUserInfo();
        player.standUp();
      }

      @Override
      public String getType()
    View Full Code Here

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

          {
            SystemMessage sm = new SystemMessage(SystemMessageId.S1_S2);
            sm.addString("You have joined team " + teamVal);
            player.sendPacket(sm);
          }
          player.broadcastUserInfo();
        }
        else if (command.startsWith("admin_social"))
        {
          try
          {
    View Full Code Here

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

            InventoryUpdate iu = new InventoryUpdate();
            iu.addItems(Arrays.asList(items));
            activeChar.sendPacket(iu);
            activeChar.abortAttack();
            activeChar.broadcastUserInfo();
          }
          else
          {
                    L2Weapon weaponItem = activeChar.getActiveWeaponItem();
                    int itemid = item.getItemId();
    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.