Jump to content

Recommended Posts

Posted

I couldn't find this code on forum so i've decided to share it. I took it from L2jServer rev3008, but it wasn't implemented on interlude, so whoever had that problem like me here it is

 

Go to net.sf.l2j.gameserver.util.FloodProtector.java

 

and find this array

private static final int[] REUSEDELAY = new int[]{ 4, 42, 42, 16, 100 }

 

edit it to look like this

 

private static final int[] REUSEDELAY = new int[]{ 4, 42, 42, 16, 100, 20 }

 

if you have more numbers here np, just add ,20 at the end.

 

now find this variables

 

public static final int PROTECTED_USEITEM		= 0;
public static final int PROTECTED_ROLLDICE		= 1;
public static final int PROTECTED_FIREWORK		= 2;
public static final int PROTECTED_ITEMPETSUMMON	= 3;
public static final int PROTECTED_HEROVOICE		= 4;

 

and after them add 1 more line

 

public static final int PROTECTED_MULTISELL		= 5;

 

now go to net.sf.l2j.gameserver.clientpackets.MultiSellChoose.java

 

find

@Override
public void runImpl()
    {

function and add this line just after {

L2PcInstance player = getClient().getActiveChar(); 
    	if (player == null) 
    		return; 
    	
    	if (!FloodProtector.getInstance().tryPerformAction(player.getObjectId(), FloodProtector.PROTECTED_MULTISELL)) 
        { 
               player.sendMessage("You can not use shop that fast!"); 
                return; 
        }

 

if you have

L2PcInstance player = getClient().getActiveChar(); 
    	if (player == null) 
    		return; 

somewhere later in that function, eclipse will warn you about error, so just delete that lines.

tested, its working on l2jserver latest rev

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


×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock