Jump to content

Recommended Posts

Posted

Geia se olous, 8a ithela na kanw share to Flood Protection rework, pou einai aparaitito gia ola ta interludes :D. Prostateuei ton server apo bugs, spams, lags.


Einai reworked gia Interlude to Gracia Final to exei idi


1. ) Arxizoume kanontas delete to old FloodProtection sosta ? :D

2. ) As arxisoume, prota kanoume delete to Support apo to L2PcInstance gia to old floodprotection

Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java
@@ -201,5 +201,4 @@
import net.sf.l2j.gameserver.templates.L2WeaponType;
import net.sf.l2j.gameserver.util.Broadcast;
-import net.sf.l2j.gameserver.util.FloodProtector;
import net.sf.l2j.util.Point3D;
import net.sf.l2j.util.Rnd;
@@ -10883,6 +10883,5 @@
			// Close the connection with the client
			closeNetConnection();
-			// remove from flood protector
-			FloodProtector.getInstance().removePlayer(getObjectId());
+			
			if (getClanId() > 0)
			{

 

3. ) Tora kanoume delete to arxeio pou legete Floodprotector.java kai vriskete sto gameserver/util .Tora tha svisete oti protection exete valei se opio file exete valei apo to palio Flood Protection.

 

4. ) Ora na valoume to kainourio Mas FloodProtection System

Edo to code: FloodProtection Rework

 

5. ) Ora na prostateusoume ta arxeia pou theloume

Ena paradeigma: ( sto proigoumeno diff vriskete to support, omws tha sas dei3w pos ginete add se periptosi p thelete na kanete kai alla protections:

 

Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestBypassToServer.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestBypassToServer.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestBypassToServer.java (revision 423)
@@ -17,4 +17,6 @@
import java.util.logging.Level;
import java.util.logging.Logger;
+
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;

import net.sf.l2j.Config;
@@ -60,4 +62,11 @@
	{
		L2PcInstance activeChar = getClient().getActiveChar();
+		
+		if (!activeChar.getFloodProtectors().getServerBypass().tryPerformAction("_command"))
+		{
+			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
+		
		if (activeChar == null)

NOTE: "Actionfailed.STATIC_PACKET " can be changed to new ActionFaled()); without harming the code.
		{

 

Support: Prota anoigoume to arxeio FloodProtection.java Vazoume ta lines:

Stin arxi ( Mporeite na dite pou einai kai ta alla paromoia me auto to code )

+	/**
+	 * Server-bypass flood protector.
+	 */
+	private final FloodProtectorAction _serverBypass;

Edo meta gia na sindethei me ta Configs ( mporeite na deite pou akrivos tha to valete apo olokliro to code sto Proto diff.

+		_serverBypass = new FloodProtectorAction(player, Config.FLOOD_PROTECTOR_SERVER_BYPASS);

Auto sto telos.

+	/**
+	 * Returns {@link #_serverBypass}.
+	 * 
+	 * @return {@link #_serverBypass}
+	 */
+	public FloodProtectorAction getServerBypass()
+	{
+		return _serverBypass;
+	}

Auto itan ena paradeigma.

 

Prostateuste ta ipoloipa arxeia, deite to parakato to diff exei ta protections gia kapoia files. to Support tous sto FloodProtection / Config einai idi added sto proto diff

Ipoloipa protections: http://www.4shared.com/file/184891519/dbc74782/Protectingit.html

 

Next page :D

Posted

Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestBypassToServer.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestBypassToServer.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestBypassToServer.java (revision 423)
@@ -17,4 +17,6 @@
import java.util.logging.Level;
import java.util.logging.Logger;
+
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;

import net.sf.l2j.Config;
@@ -60,4 +62,11 @@
	{
		L2PcInstance activeChar = getClient().getActiveChar();
+		
+		if (!activeChar.getFloodProtectors().getServerBypass().tryPerformAction("_command"))
+		{
+			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
+		
		if (activeChar == null)
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestSellItem.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestSellItem.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestSellItem.java (revision 423)
@@ -84,4 +84,9 @@
	{
		L2PcInstance player = getClient().getActiveChar();
+		if (!player.getFloodProtectors().getMisc().tryPerformAction("misc"))
+		{
+			player.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
		if (player == null)
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/MultiSellChoose.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/MultiSellChoose.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/MultiSellChoose.java (revision 423)
@@ -30,4 +30,5 @@
import net.sf.l2j.gameserver.model.item.PcInventory;
import net.sf.l2j.gameserver.network.SystemMessageId;
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;
import net.sf.l2j.gameserver.network.serverpackets.ItemList;
import net.sf.l2j.gameserver.network.serverpackets.PledgeShowInfoUpdate;
@@ -90,4 +91,9 @@
	private void doExchange(L2PcInstance player, MultiSellEntry templateEntry, boolean applyTaxes, boolean maintainEnchantment, int enchantment)
	{
+		if (!player.getFloodProtectors().getMultisell().tryPerformAction("multisell"))
+		{
+			player.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
		PcInventory inv = player.getInventory();
		boolean maintainItemFound = false;
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestPrivateStoreBuy.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestPrivateStoreBuy.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestPrivateStoreBuy.java (revision 423)
@@ -72,4 +72,12 @@
	{
		L2PcInstance player = getClient().getActiveChar();
+		
+		if (!player.getFloodProtectors().getMisc().tryPerformAction("misc"))
+		{
+			player.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
+		
+		
		if (player == null)
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/SendWareHouseWithDrawList.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/SendWareHouseWithDrawList.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/SendWareHouseWithDrawList.java (revision 423)
@@ -26,4 +26,5 @@
import net.sf.l2j.gameserver.model.item.ItemContainer;
import net.sf.l2j.gameserver.network.SystemMessageId;
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;
import net.sf.l2j.gameserver.network.serverpackets.InventoryUpdate;
import net.sf.l2j.gameserver.network.serverpackets.ItemList;
@@ -84,4 +85,9 @@
		{
			player.sendMessage("Transactions are disable for your Access Level");
+			return;
+		}
+		if (!player.getFloodProtectors().getWerehouse().tryPerformAction("werehouse"))
+		{
+			player.sendPacket(ActionFailed.STATIC_PACKET);
			return;
		}
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestPrivateStoreSell.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestPrivateStoreSell.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestPrivateStoreSell.java (revision 423)
@@ -89,4 +89,11 @@
	{
		L2PcInstance player = getClient().getActiveChar();
+		
+		if (!player.getFloodProtectors().getMisc().tryPerformAction("misc"))
+		{
+			player.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
+		
		if (player == null)
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestDestroyItem.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestDestroyItem.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestDestroyItem.java (revision 423)
@@ -18,4 +18,6 @@
import java.util.logging.Level;
import java.util.logging.Logger;
+
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;

import net.sf.l2j.Config;
@@ -56,4 +58,11 @@
	{
		L2PcInstance activeChar = getClient().getActiveChar();
+		
+		if (!activeChar.getFloodProtectors().getMisc().tryPerformAction("misc"))
+		{
+			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
+		
		if (activeChar == null)
			return;
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestDropItem.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestDropItem.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestDropItem.java (revision 423)
@@ -17,4 +17,6 @@
import java.util.logging.Logger;

+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;
+
import net.sf.l2j.Config;
import net.sf.l2j.gameserver.GmListTable;
@@ -61,4 +63,11 @@
	{
		L2PcInstance activeChar = getClient().getActiveChar();
+		
+		if (!activeChar.getFloodProtectors().getDropItem().tryPerformAction("drop"))
+		{
+			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
+		
		if (activeChar == null || activeChar.isDead())
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/Say2.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/Say2.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/Say2.java (revision 423)
@@ -25,4 +25,5 @@
import net.sf.l2j.gameserver.handler.IChatHandler;
import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance;
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;

/**
@@ -85,4 +86,13 @@
		// getting char instance
		L2PcInstance activeChar = getClient().getActiveChar();
+		
+		if (activeChar != null && activeChar instanceof L2PcInstance)
+		{
+			if (!activeChar.getFloodProtectors().getChat().tryPerformAction("chat"))
+			{
+				activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+				return;
+			}
+		}
		if (_text.length() >= 100)
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/AttackRequest.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/AttackRequest.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/AttackRequest.java (revision 423)
@@ -61,4 +61,10 @@
		else
			target = L2World.getInstance().findObject(_objectId);
+		// Update next commit
+		// if (!activeChar.getFloodProtectors().getActionMwx().tryPerformAction("_objectId"))
+		// {
+		//	activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+		//	return;
+		// }
		if (target == null)
			return;
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestBuyItem.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestBuyItem.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestBuyItem.java (revision 423)
@@ -83,4 +83,11 @@
	{
		L2PcInstance player = getClient().getActiveChar();
+		
+		if (!player.getFloodProtectors().getMisc().tryPerformAction("misc"))
+		{
+			player.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
+		
		if (player == null)
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestEnchantItem.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestEnchantItem.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/RequestEnchantItem.java (revision 423)
@@ -16,4 +16,6 @@

import java.util.logging.Logger;
+
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;

import net.sf.l2j.Config;
@@ -410,4 +412,11 @@
					activeChar.sendPacket(sm);
				}
+				
+				if (!activeChar.getFloodProtectors().getWerehouse().tryPerformAction("werehouse"))
+				{
+					activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+					return;
+				}
+				
				item.setEnchantLevel(item.getEnchantLevel() + 1);
				item.updateDatabase();
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/UseItem.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/UseItem.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/network/clientpackets/UseItem.java (revision 423)
@@ -60,4 +60,9 @@
		if (activeChar == null)
			return;
+		if (!activeChar.getFloodProtectors().getUseItem().tryPerformAction("use item"))
+		{
+			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
		if (activeChar.getPrivateStoreType() != 0)
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2NpcBufferInstance.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2NpcBufferInstance.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2NpcBufferInstance.java (revision 423)
@@ -18,4 +18,6 @@
import java.util.concurrent.ScheduledFuture;

+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;
+
import net.sf.l2j.gameserver.ThreadPoolManager;
import net.sf.l2j.gameserver.datatables.NpcBufferSkillIdsTable;
@@ -191,4 +193,9 @@
		if (command.startsWith("npc_buffer_heal"))
		{
+			if (!playerInstance.getFloodProtectors().getBuffer().tryPerformAction("npc_buffer_heal"))
+			{
+				playerInstance.sendPacket(ActionFailed.STATIC_PACKET);
+				return;
+			}
			if (playerInstance.getCurrentHp() == 0 || playerInstance.getPvpFlag() > 0)
			{
@@ -204,4 +211,9 @@
		if (command.startsWith("npc_buffer_cancel"))
		{
+			if (!playerInstance.getFloodProtectors().getBuffer().tryPerformAction("npc_buffer_cancel"))
+			{
+				playerInstance.sendPacket(ActionFailed.STATIC_PACKET);
+				return;
+			}
			if (playerInstance.getCurrentHp() == 0 || playerInstance.getPvpFlag() > 0)
			{
@@ -215,4 +227,9 @@
		if (command.startsWith("npc_buffer_buff"))
		{
+			if (!playerInstance.getFloodProtectors().getBuffer().tryPerformAction("npc_buffer_buff"))
+			{
+				playerInstance.sendPacket(ActionFailed.STATIC_PACKET);
+				return;
+			}
			String[] params = command.split(" ");
			int skillId = Integer.parseInt(params[1]);
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2NpcInstance.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2NpcInstance.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2NpcInstance.java (revision 423)
@@ -2814,4 +2814,6 @@
		if (player == null)
			return;
+		if (!player.getFloodProtectors().getSubclass().tryPerformAction("buffer"))
+			return;
		// Blessing of protection - author kerberos_20. Used codes from Rayan - L2Emu project.
		int player_level = player.getLevel();
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2VillageMasterInstance.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2VillageMasterInstance.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/model/actor/instance/L2VillageMasterInstance.java (revision 423)
@@ -285,4 +285,12 @@
				case 4: // Add Subclass - Action (Subclass 4 x[x])
					boolean allowAddition = true;
+					
+					if (!player.getFloodProtectors().getSubclass().tryPerformAction("add subclass"))
+					{
+						player.sendMessage("Don't change sub classes so rapidly, please wait.");
+						player.sendPacket(ActionFailed.STATIC_PACKET);
+						return;
+					}
+					
					/*
					 * If the character is less than level 75 on any of their previously chosen classes then disallow them to change to their most recently added sub-class choice.
@@ -373,4 +381,10 @@
					 * If the character is less than level 75 on any of their previously chosen classes then disallow them to change to their most recently added sub-class choice. Note: paramOne = classIndex
					 */
+					if (!player.getFloodProtectors().getSubclass().tryPerformAction("change class"))
+					{
+						player.sendMessage("Don't change sub classes so rapidly, please wait.");
+						player.sendPacket(ActionFailed.STATIC_PACKET);
+						return;
+					}
					if (Olympiad.getInstance().isRegisteredInComp(player) || (player.getOlympiadGameId() > 0))
					{
@@ -407,4 +421,10 @@
					 * Warning: the information about this subclass will be removed from the subclass list even if false!
					 */
+					if (!player.getFloodProtectors().getSubclass().tryPerformAction("change class"))
+					{
+						player.sendMessage("Don't change sub classes so rapidly, please wait.");
+						player.sendPacket(ActionFailed.STATIC_PACKET);
+						return;
+					}
					if (Olympiad.getInstance().isRegisteredInComp(player) || (player.getOlympiadGameId() > 0))
					{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/itemhandlers/SummonItems.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/itemhandlers/SummonItems.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/itemhandlers/SummonItems.java (revision 423)
@@ -58,4 +58,9 @@
		}
		L2PcInstance activeChar = (L2PcInstance) playable;
+		if (!activeChar.getFloodProtectors().getItemPetSummon().tryPerformAction("summon items"))
+		{
+			playable.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
		if (activeChar.isSitting())
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/itemhandlers/Firework.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/itemhandlers/Firework.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/itemhandlers/Firework.java (revision 423)
@@ -14,4 +14,6 @@
 */
package net.sf.l2j.gameserver.handler.itemhandlers;
+
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;

import net.sf.l2j.gameserver.datatables.SkillTable;
@@ -39,4 +41,49 @@
		L2PcInstance activeChar = (L2PcInstance) playable;
		int itemId = item.getItemId();
+		if (!activeChar.getFloodProtectors().getFirework().tryPerformAction("firework"))
+		{
+			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}

		/*
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/itemhandlers/RollingDice.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/itemhandlers/RollingDice.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/itemhandlers/RollingDice.java (revision 423)
@@ -69,4 +69,6 @@
	private int rollDice(L2PcInstance player)
	{
+		if (!player.getFloodProtectors().getRollDice().tryPerformAction("roll dice"))
+			return 0;
		// Check if the dice is ready
		return Rnd.get(1, 6);
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/voicedcommandhandlers/Banking.java
===================================================================
--- /trunk/v/java/net/sf/l2j/gameserver/handler/voicedcommandhandlers/Banking.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/voicedcommandhandlers/Banking.java (revision 423)
@@ -14,4 +14,6 @@
 */
package net.sf.l2j.gameserver.handler.voicedcommandhandlers;
+
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;

import net.sf.l2j.Config;
@@ -34,4 +36,9 @@
	public boolean useVoicedCommand(String command, L2PcInstance activeChar, String target)
	{
+		if (!activeChar.getFloodProtectors().getBankingSystem().tryPerformAction("BankingSystem"))
+		{
+			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+			return false;
+		}
		if (command.equalsIgnoreCase("bank"))
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/chathandlers/ChatTrade.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/chathandlers/ChatTrade.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/chathandlers/ChatTrade.java (revision 423)
@@ -20,4 +20,5 @@
import net.sf.l2j.gameserver.model.L2World;
import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance;
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;
import net.sf.l2j.gameserver.network.serverpackets.CreatureSay;

@@ -38,4 +39,9 @@
	public void handleChat(int type, L2PcInstance activeChar, String target, String text)
	{
+		if (!activeChar.getFloodProtectors().getGlobal().tryPerformAction("global"))
+		{
+			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
		CreatureSay cs = new CreatureSay(activeChar.getObjectId(), type, activeChar.getName(), text);
		if (Config.DEFAULT_TRADE_CHAT.equalsIgnoreCase("on") || (Config.DEFAULT_TRADE_CHAT.equalsIgnoreCase("gm") && activeChar.isGM()))
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/chathandlers/ChatShout.java
===================================================================
--- /trunk/v/java/net/sf/l2j/gameserver/handler/chathandlers/ChatShout.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/chathandlers/ChatShout.java (revision 423)
@@ -14,4 +14,6 @@
 */
package net.sf.l2j.gameserver.handler.chathandlers;
+
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;

import net.sf.l2j.Config;
@@ -38,4 +40,9 @@
	public void handleChat(int type, L2PcInstance activeChar, String target, String text)
	{
+		if (!activeChar.getFloodProtectors().getGlobal().tryPerformAction("global"))
+		{
+			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
		CreatureSay cs = new CreatureSay(activeChar.getObjectId(), type, activeChar.getName(), text);
		if (Config.DEFAULT_GLOBAL_CHAT.equalsIgnoreCase("on") || (Config.DEFAULT_GLOBAL_CHAT.equalsIgnoreCase("gm") && activeChar.isGM()))
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/chathandlers/ChatHeroVoice.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/chathandlers/ChatHeroVoice.java (revision 421)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/handler/chathandlers/ChatHeroVoice.java (revision 423)
@@ -19,4 +19,5 @@
import net.sf.l2j.gameserver.model.L2World;
import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance;
+import net.sf.l2j.gameserver.network.serverpackets.ActionFailed;
import net.sf.l2j.gameserver.network.serverpackets.CreatureSay;

@@ -37,6 +38,11 @@
	public void handleChat(int type, L2PcInstance activeChar, String target, String text)
	{
-		if (activeChar.isHero())
+		if (activeChar.isHero() || activeChar.isGM ())
		{
+			if (!activeChar.getFloodProtectors().getHeroVoice().tryPerformAction("hero voice") && !activeChar.isGM())
+			{
+				activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+				return;
+			}
			CreatureSay cs = new CreatureSay(activeChar.getObjectId(), type, activeChar.getName(), text);
			for (L2PcInstance player : L2World.getInstance().getAllPlayers())
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/RecipeController.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/RecipeController.java (revision 413)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/RecipeController.java (revision 423)
@@ -193,4 +193,9 @@
	public synchronized void requestMakeItem(L2PcInstance player, int recipeListId)
	{
+		if (!player.getFloodProtectors().getCraft().tryPerformAction("craft"))
+		{
+			player.sendPacket(ActionFailed.STATIC_PACKET);
+			return;
+		}
		if (player.isInDuel())
		{
Index: /trunk/Eclipse/java/net/sf/l2j/gameserver/util/FloodProtectors.java
===================================================================
--- /trunk/Eclipse/java/net/sf/l2j/gameserver/util/FloodProtectors.java (revision 422)
+++ /trunk/Eclipse/java/net/sf/l2j/gameserver/util/FloodProtectors.java (revision 423)
@@ -15,4 +15,6 @@
package  net.sf.l2j.gameserver.util;

+import net.sf.l2j.gameserver.util.FloodProtectorAction;
+
import  net.sf.l2j.Config;
import  net.sf.l2j.gameserver.model.actor.instance.L2PcInstance;

Credits: L2J kai se emena gia to rework sto Interlude.

Posted

NC...Man thelw na se rotisw kati , ama kses...kita ,egw exw interlude server kai thelw na perasw kati weapons....exw kai to (edit file) briskw to arxio [itemname-e.dat] & to [weapongrp.dat]  mesa sto fakelo system kai den borw na to aniksw gia na perasw ta items pou thelw...mipos kses pos to kanw?

Posted

NC...Man thelw na se rotisw kati , ama kses...kita ,egw exw interlude server kai thelw na perasw kati weapons....exw kai to (edit file) briskw to arxio [itemname-e.dat] & to [weapongrp.dat]  mesa sto fakelo system kai den borw na to aniksw gia na perasw ta items pou thelw...mipos kses pos to kanw?

Auto dn kolaei pouthena, psa3e sto MXC iparxoun Guides.

Posted

Einai olo-diko mou ! To ekana monos rework apo Gracia final gia Interlude.

 

lol to patch tou intrepid phres kai 2 sync apo to forum ths l2j.

akoma kai to paneykolo rework (pou to ousiastiko rework einai na vgaleis to floodprotector) den htan diko sou.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Posts

    • Hello guys, As you can understand I don't want to share yet many information regarding the project while it is under heavy development stage, I can understand your curiosity about  "What might be" however think it like a secret sauce from a restaurant that does not actually share the recipe from it, but of course once we have something in our hands we will provide any logical information. If you are interested that much you can always take a look in our discord: https://discord.com/invite/mightyproject Hello there, No it is not Unreal Engine 5, well for this we will need some good budget and a skilled team based on UE5. Thank you looking foward seeing you playing in our project soon, and trust me it will be mighty! https://discord.com/invite/mightyproject
    • Hello guys, There isn't much information to share yet regarding the project. We've been working on it for the past few months with the goal of creating something unique and truly different. Over the years, I've seen countless projects with the same features repeated over and over again. This time, we're aiming to build something solid and unlike anything players have seen before. Since many of you have been asking about Unreal Engine 5, I'd like to clear that up. Building something on UE5 requires a very large team and a lot of resources to accomplish properly. Right now, we can't say anything regarding UE5. Maybe in the future, who knows? Tzelal is a real life friend of mine. I've known him for many years, and he's a great guy. Right now, he's looking for people who genuinely want to be part of this project. The team is working 20+ hours a day, every single day. I'm often on calls with them, watching their progress and seeing everything they're creating. So, if anyone is wondering what's happening behind the scenes, my answer is simple, something amazing. I know many of you have been asking about features and other details, but we don't want to spoil anything just yet. There is still a lot of work to be done, and we'd rather reveal things when they're ready. Once everything is in the state we want, we'll start releasing sneak peeks. If you'd like to join the project, feel free to send Tzelal a private message so you can go through an interview. Please don't waste his time, or yours, if you're not genuinely interested. Now, I'd like to make a few things clear. No, we're not making another generic server with the same old features and the same old engine that you've seen for years. Our goal is to build something completely different, something that players haven't experienced before. And no, we're not going to give up on development. We work every day, and we keep pushing forward even when some challenges seem difficult. We're committed to making this project the best it can be. That's all for now. There will be much more to share once we're ready to show it. Thanks for your time, everyone.
    • 📢 MMORE.DEV — ONE SLOT AVAILABLE FOR A PROJECT   1 slot has opened up for long-term cooperation. We welcome anyone interested — we're looking for projects built for long-term collaboration, not one-off tasks.   🎯 We're ready to take on projects for these chronicles:   Essence Classic   Current protocols: 520, 542, 557+ One example of our developers' work — the Aden.Land team.   📋 We're also accepting preliminary discussions for the Main (GOD) branch — if you're planning a project on this chronicle, reach out in advance so we can go over the details and timeline. _______________________________________________________________________   For any questions — PM us or reach out on Telegram: https://t.me/L2scripts
    • 🔥 L2SCRIPTS BIG SALE 🔥 30-50% OFF ALL LEGACY PRODUCTS! Special offer for MaxCheaters users! Promotion runs from July 25 to August 1 inclusive _____________________________________________________    🎁 Promo details: 30-50% discount on all legacy studio products Source codes, ready-made builds, technical support — everything you've been wanting to grab at a great price. ___________________________________________________________________________   ⚡ Why you should hurry: A discount like this across the whole lineup is a rare event in our 20 years on the market This offer is strictly time-limited — exactly 7 days, no extensions Available only for MaxCheaters users Support slots are limited. ____________________________________________________ ✅ Proven quality — 20 years in the L2 market ✅ Full range of chronicles and ready-made solutions ✅ Personal support from our team ____________________________________________________   🌐 Our websites: L2-scripts.com — https://l2-scripts.com Mmore.dev — https://mmore.dev Telegram for contact: https://t.me/L2scripts ____________________________________________________   Don't miss your chance! In 7 days prices go back to normal — grab what you need at the best price in the studio's history. ➡️ Browse the product catalog: https://l2-scripts.com For any questions — PM us or check the support thread.
  • Topics

×
×
  • 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..