Jump to content
  • 0

Small Help With Java


Question

Posted (edited)

Hey there, I need help to block party and clan invite to players that are registered in olympiad.

Where and how could I add this exception into my core?

 

ps. I use l2jfrozen

Edited by vecc

2 answers to this question

Recommended Posts

  • 0
Posted (edited)

Next time use a proper title for your topic. "Help me with java" is not even close to what you are asking....

 

 

Restrict party:

 

 

com.l2jserver.gameserver.network.clientpackets.RequestJoinParty.java

 

if (requestor.isPartyBanned()) {
   requestor.sendPacket(SystemMessageId.YOU_HAVE_BEEN_REPORTED_SO_PARTY_NOT_ALLOWED);
   requestor.sendPacket(ActionFailed.STATIC_PACKET);
   return;
  }
+  if (target.isInOlympiadMode() || OlympiadManager.getInstance().isRegisteredInComp(target)) {
+   requestor.sendMessage("Your target is in olympiad.");
+   return;
+  }

  if (target.isPartyBanned()) {
   SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_REPORTED_AND_CANNOT_PARTY);
   sm.addCharName(target);
   requestor.sendPacket(sm);
   return;
  }

 

 

Restrict clan invite:

 

 

com.l2jserver.gameserver.network.clientpackets.RequestJoinPldege.java

 

if (!clan.checkClanJoinCondition(activeChar, target, _pledgeType))
  {
   return;
  }
+  if (target.isInOlympiadMode() || OlympiadManager.getInstance().isRegisteredInComp(target)) {
+   activeChar.sendMessage("Your target is in olympiad.");
+   return;
+  }

  if (!activeChar.getRequest().setRequest(target, this))
  {
   return;
  }

 

 

 

Edited by Solomun
Guest
This topic is now closed to further replies.


×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..