Package lineage2.gameserver.model.pledge

Examples of lineage2.gameserver.model.pledge.Clan.broadcastToOnlineMembers()


    SubUnit oldUnit = null;
    if (replacement != null)
    {
      oldUnit = replacement.getSubUnit();
      oldUnit.replace(replacement.getObjectId(), subject.getPledgeType());
      clan.broadcastToOnlineMembers(new PledgeShowMemberListUpdate(replacement));
      if (replacement.isOnline())
      {
        replacement.getPlayer().updatePledgeClass();
        replacement.getPlayer().broadcastCharInfo();
      }
View Full Code Here


        replacement.getPlayer().broadcastCharInfo();
      }
    }
    oldUnit = subject.getSubUnit();
    oldUnit.replace(subject.getObjectId(), _targetUnit);
    clan.broadcastToOnlineMembers(new PledgeShowMemberListUpdate(subject));
    if (subject.isOnline())
    {
      subject.getPlayer().updatePledgeClass();
      subject.getPlayer().broadcastCharInfo();
    }
View Full Code Here

  public void stopEvent(boolean step)
  {
    Clan newOwner = getResidence().getOwner();
    if (newOwner != null)
    {
      newOwner.broadcastToOnlineMembers(PlaySound.SIEGE_VICTORY);
      newOwner.incReputation(1700, false, toString());
      broadcastTo(new SystemMessage2(SystemMsg.S1_CLAN_HAS_DEFEATED_S2).addString(newOwner.getName()).addResidenceName(getResidence()), ATTACKERS);
      broadcastTo(new SystemMessage2(SystemMsg.THE_SIEGE_OF_S1_IS_FINISHED).addResidenceName(getResidence()), ATTACKERS);
    }
    else
View Full Code Here

    Clan newOwner = getResidence().getOwner();
    if (newOwner != null)
    {
      if (_oldOwner != newOwner)
      {
        newOwner.broadcastToOnlineMembers(PlaySound.SIEGE_VICTORY);
        newOwner.incReputation(1700, false, toString());
        if (_oldOwner != null)
        {
          _oldOwner.incReputation(-1700, false, toString());
        }
View Full Code Here

      activeChar.sendMessage("A clan leader may not be dismissed.");
      return;
    }
    int subUnitType = activeChar.getPledgeType();
    clan.removeClanMember(subUnitType, activeChar.getObjectId());
    clan.broadcastToOnlineMembers(new SystemMessage2(SystemMsg.S1_HAS_WITHDRAWN_FROM_THE_CLAN).addString(activeChar.getName()), new PledgeShowMemberListDelete(activeChar.getName()));
    if (subUnitType == Clan.SUBUNIT_ACADEMY)
    {
      activeChar.setLvlJoinedAcademy(0);
    }
    activeChar.setClan(null);
View Full Code Here

    pledgeType = clan.createSubPledge(player, pledgeType, subLeader, clanName);
    if (pledgeType == Clan.SUBUNIT_NONE)
    {
      return;
    }
    clan.broadcastToOnlineMembers(new PledgeReceiveSubPledgeCreated(clan.getSubUnit(pledgeType)));
    SystemMessage sm;
    if (pledgeType == Clan.SUBUNIT_ACADEMY)
    {
      sm = new SystemMessage(SystemMessage.CONGRATULATIONS_THE_S1S_CLAN_ACADEMY_HAS_BEEN_CREATED);
      sm.addString(player.getClan().getName());
View Full Code Here

      sm = Msg.CLAN_HAS_BEEN_CREATED;
    }
    player.sendPacket(sm);
    if (subLeader != null)
    {
      clan.broadcastToOnlineMembers(new PledgeShowMemberListUpdate(subLeader));
      if (subLeader.isOnline())
      {
        subLeader.getPlayer().updatePledgeClass();
        subLeader.getPlayer().broadcastCharInfo();
      }
View Full Code Here

    {
      player.sendMessage(new CustomMessage("lineage2.gameserver.model.instances.L2VillageMasterInstance.ItCantBeSubUnitLeader", player));
      return;
    }
    targetUnit.setLeader(subLeader, true);
    clan.broadcastToOnlineMembers(new PledgeReceiveSubPledgeCreated(targetUnit));
    clan.broadcastToOnlineMembers(new PledgeShowMemberListUpdate(subLeader));
    if (subLeader.isOnline())
    {
      subLeader.getPlayer().updatePledgeClass();
      subLeader.getPlayer().broadcastCharInfo();
View Full Code Here

      player.sendMessage(new CustomMessage("lineage2.gameserver.model.instances.L2VillageMasterInstance.ItCantBeSubUnitLeader", player));
      return;
    }
    targetUnit.setLeader(subLeader, true);
    clan.broadcastToOnlineMembers(new PledgeReceiveSubPledgeCreated(targetUnit));
    clan.broadcastToOnlineMembers(new PledgeShowMemberListUpdate(subLeader));
    if (subLeader.isOnline())
    {
      subLeader.getPlayer().updatePledgeClass();
      subLeader.getPlayer().broadcastCharInfo();
    }
View Full Code Here

    if (clan.equals(clan.getAlliance().getLeader()))
    {
      activeChar.sendPacket(Msg.ALLIANCE_LEADERS_CANNOT_WITHDRAW);
      return;
    }
    clan.broadcastToOnlineMembers(Msg.YOU_HAVE_WITHDRAWN_FROM_THE_ALLIANCE, Msg.A_CLAN_THAT_HAS_WITHDRAWN_OR_BEEN_EXPELLED_CANNOT_ENTER_INTO_AN_ALLIANCE_WITHIN_ONE_DAY_OF_WITHDRAWAL_OR_EXPULSION);
    Alliance alliance = clan.getAlliance();
    clan.setAllyId(0);
    clan.setLeavedAlly();
    alliance.broadcastAllyStatus();
    alliance.removeAllyMember(clan.getClanId());
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.