Package com.l2jfrozen.gameserver.network.serverpackets

Examples of com.l2jfrozen.gameserver.network.serverpackets.SocialAction


        {
          // Send a Server->Client packet SocialAction to the all
          // L2PcInstance on the _knownPlayer of the L2NpcInstance
          // to display a social action of the L2NpcInstance on their
          // client
          SocialAction sa = new SocialAction(getObjectId(), Rnd.get(8));
          broadcastPacket(sa);

          doAction(player);
        }
      }
View Full Code Here


        {
          targetPlayer.setDonator(true);
          targetPlayer.updateNameTitleColor();
          updateDatabase(targetPlayer, true);
          sendMessages(true, targetPlayer, activeChar, false, true);
          targetPlayer.broadcastPacket(new SocialAction(targetPlayer.getObjectId(), 16));
          targetPlayer.broadcastUserInfo();
        }
        else
        {
          targetPlayer.setDonator(false);
View Full Code Here

          || _text.equalsIgnoreCase("hi"))
          && (!activeChar.isRunning()
              || !activeChar.isAttackingNow()
              || !activeChar.isCastingNow()
              || !activeChar.isCastingPotionNow()))
        activeChar.broadcastPacket(new SocialAction(activeChar.getObjectId(), 2));
     
      if ((_text.equalsIgnoreCase("lol")
          || _text.equalsIgnoreCase("haha")
          || _text.equalsIgnoreCase("xaxa")
          || _text.equalsIgnoreCase("ghgh")
          || _text.equalsIgnoreCase("jaja"))
          && (!activeChar.isRunning() || !activeChar.isAttackingNow() || !activeChar.isCastingNow() || !activeChar.isCastingPotionNow()))
        activeChar.broadcastPacket(new SocialAction(activeChar.getObjectId(), 10));
       
      if ((_text.equalsIgnoreCase("yes")
          || _text.equalsIgnoreCase("si")
          || _text.equalsIgnoreCase("yep"))
          && (!activeChar.isRunning() || !activeChar.isAttackingNow() || !activeChar.isCastingNow()|| !activeChar.isCastingPotionNow()))
        activeChar.broadcastPacket(new SocialAction(activeChar.getObjectId(), 6));
     
      if ((_text.equalsIgnoreCase("no")
          || _text.equalsIgnoreCase("nop")
          || _text.equalsIgnoreCase("nope"))
          && (!activeChar.isRunning() || !activeChar.isAttackingNow() || !activeChar.isCastingNow()|| !activeChar.isCastingPotionNow()))
        activeChar.broadcastPacket(new SocialAction(activeChar.getObjectId(), 5));
   
    }
   
    // by Azagthtot
    PowerPak.getInstance().chatHandler(activeChar, _type, _text);
View Full Code Here

          player.sendPacket(new ValidateLocation(this));
        }
        else if (isInsideRadius(player, INTERACTION_DISTANCE, false, false))
        {
          //SocialAction sa = new SocialAction(this, Rnd.get(8));
          player.broadcastPacket(new SocialAction(player.getObjectId(), 6));
          //broadcastPacket(sa);
          //player.setCurrentFolkNPC(this);
          delevelInfo(player);
          player.sendPacket(ActionFailed.STATIC_PACKET);
        }
View Full Code Here

      if(Config.DEBUG)
      {
        _log.fine("Social Action:" + _actionId);
      }

      SocialAction atk = new SocialAction(activeChar.getObjectId(), _actionId);
      activeChar.broadcastPacket(atk);
      /*
      // Schedule a social task to wait for the animation to finish
      ThreadPoolManager.getInstance().scheduleGeneral(new SocialTask(this), 2600);
      activeChar.setIsParalyzed(true);
View Full Code Here

      {
        if(player != null)
        {
          if(!player._teamNameCTF.equals(teamName))
          {
            player.broadcastPacket(new SocialAction(player.getObjectId(), 7));
          }
          else if(player._teamNameCTF.equals(teamName))
          {
            player.broadcastPacket(new SocialAction(player.getObjectId(), 3));
          }
        }
      }
    }
   
View Full Code Here

      if(wpn!=null)
        _player.getInventory().unEquipItemInBodySlotAndRecord(Inventory.PAPERDOLL_LHAND);
    }
    // Add the flag in his hands
    _player.getInventory().equipItem(ItemTable.getInstance().createItem("",CTF._FLAG_IN_HAND_ITEM_ID,1,_player,null));
    _player.broadcastPacket(new SocialAction(_player.getObjectId(), 16)); // Amazing glow
    _player._haveFlagCTF = true;
    _player.broadcastUserInfo();
    CreatureSay cs = new CreatureSay(_player.getObjectId(), 15, ":", "You got it! Run back! ::"); // 8D
    _player.sendPacket(cs);
  }
View Full Code Here

            int indexEnemy = _teams.indexOf(_player._teamNameHaveFlagCTF);
            // Return enemy flag to place
            _flagsTaken.set(indexEnemy, false);
            spawnFlag(_player._teamNameHaveFlagCTF);
            // Remove the flag from this player
            _player.broadcastPacket(new SocialAction(_player.getObjectId(), 16)); // Amazing glow
            _player.broadcastUserInfo();
            _player.broadcastPacket(new SocialAction(_player.getObjectId(), 3)); // Victory
            _player.broadcastUserInfo();
            removeFlagFromPlayer(_player);
            _teamPointsCount.set(indexOwn, teamPointsCount(team)+1);
            Announcements.getInstance().gameAnnounceToAll(_eventName + ": " + _player.getName() + " scores for " + _player._teamNameCTF + ".");
          }
View Full Code Here

  public void onRandomAnimation()
  {
    int min = _customNpcInstance != null ? 1 : 2;
    int max = _customNpcInstance != null ? 13 : 3;
    // Send a packet SocialAction to all L2PcInstance in the _KnownPlayers of the L2NpcInstance
    SocialAction sa = new SocialAction(getObjectId(), Rnd.get(min, max));
    broadcastPacket(sa);
    sa = null;
  }
View Full Code Here

          // Like L2OFF if char is dead, is sitting, is in trade or is in fakedeath can't interact with npc
          if (player.isSitting() || player.isDead() || player.isFakeDeath() || player.getActiveTradeList() != null)
            return;
         
          // Send a Server->Client packet SocialAction to the all L2PcInstance on the _knownPlayer of the L2NpcInstance to display a social action of the L2NpcInstance on their client
          SocialAction sa = new SocialAction(getObjectId(), Rnd.get(8));
          broadcastPacket(sa);
          // Open a chat window on client with the text of the L2NpcInstance
          if (isEventMob)
          {
            L2Event.showEventHtml(player, String.valueOf(getObjectId()));
View Full Code Here

TOP

Related Classes of com.l2jfrozen.gameserver.network.serverpackets.SocialAction

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.