if (player == null)
{
return;
}
Party party = player.getParty();
CommandChannel channel = party != null ? party.getCommandChannel() : null;
if ((channel != null) && (channel.getChannelLeader() == player))
{
if (channel.getMatchingRoom() == null)
{
CCMatchingRoom room = new CCMatchingRoom(player, 1, player.getLevel(), 50, party.getLootDistribution(), player.getName());
channel.setMatchingRoom(room);
}
}
else if ((channel != null) && !channel.getParties().contains(party))
{
player.sendPacket(SystemMsg.THE_COMMAND_CHANNEL_AFFILIATED_PARTYS_PARTY_MEMBER_CANNOT_USE_THE_MATCHING_SCREEN);
}
else if ((party != null) && !party.isLeader(player))
{