Jump to content

[Share] Stuck augument fix ! [Both ways]


DominiQue
 Share

Recommended Posts

There are 2 ways I think :

Equip an 2handed wep and put a shield :)

Equip an one handed weapons ,equp shield and put a 2handed weapon in hand :)

 

File :

/**

*

* useitem.java

*

*/

 

 

FIX :

           if (activeChar.isFishing() && (itemId < 6535 || itemId > 6540))

           {

               // You cannot do anything else while fishing

               SystemMessage sm = new SystemMessage(SystemMessageId.CANNOT_DO_WHILE_FISHING_3);

               getClient().getActiveChar().sendPacket(sm);

               sm = null;

               return;

           }

 

+ L2Weapon curwep = activeChar.getActiveWeaponItem();

+            if (curwep != null)

+               {

+            if ((curwep.getItemType() == L2WeaponType.DUAL) && (item.getItemType() == L2WeaponType.NONE))

+                    {

+             activeChar.sendMessage("You are not allowed to do this.");

+             return;

+                    }

+             else if ((curwep.getItemType() == L2WeaponType.BOW) && (item.getItemType() == L2WeaponType.NONE))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+             else if ((curwep.getItemType() == L2WeaponType.BIGBLUNT) && (item.getItemType() == L2WeaponType.NONE))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+             else if ((curwep.getItemType() == L2WeaponType.BIGSWORD) && (item.getItemType() == L2WeaponType.NONE))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+             else if ((curwep.getItemType() == L2WeaponType.POLE) && (item.getItemType() == L2WeaponType.NONE))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.DUALFIST) && (item.getItemType() == L2WeaponType.NONE))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.DAGGER) && (item.getItemType() == L2WeaponType.DUALFIST))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                   }

+ else if ((curwep.getItemType() == L2WeaponType.DAGGER) && (item.getItemType() == L2WeaponType.POLE))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.DAGGER) && (item.getItemType() == L2WeaponType.BIGBLUNT))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.DAGGER) && (item.getItemType() == L2WeaponType.BIGSWORD))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.DAGGER) && (item.getItemType() == L2WeaponType.BOW))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.DAGGER) && (item.getItemType() == L2WeaponType.DUAL))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.SWORD) && (item.getItemType() == L2WeaponType.DUALFIST))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.SWORD) && (item.getItemType() == L2WeaponType.POLE))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.SWORD) && (item.getItemType() == L2WeaponType.BIGBLUNT))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.SWORD) && (item.getItemType() == L2WeaponType.BIGSWORD))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.SWORD) && (item.getItemType() == L2WeaponType.BOW))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.SWORD) && (item.getItemType() == L2WeaponType.DUAL))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.BLUNT) && (item.getItemType() == L2WeaponType.DUALFIST))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.BLUNT) && (item.getItemType() == L2WeaponType.POLE))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.BLUNT) && (item.getItemType() == L2WeaponType.BIGBLUNT))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.BLUNT) && (item.getItemType() == L2WeaponType.BIGSWORD))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.BLUNT) && (item.getItemType() == L2WeaponType.BOW))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+ else if ((curwep.getItemType() == L2WeaponType.BLUNT) && (item.getItemType() == L2WeaponType.DUAL))

+                    {

+         activeChar.sendMessage("You are not allowed to do this.");

+         return;

+                    }

+                }

 

// Char cannot use item when dead

if (activeChar.isDead())

{

SystemMessage sm = new SystemMessage(SystemMessageId.S1_CANNOT_BE_USED);

sm.addItemName(itemId);

getClient().getActiveChar().sendPacket(sm);

sm = null;

return;

}

 

 

CREDITS : V3ndetta[ME}
Link to comment
Share on other sites

  • 2 weeks later...
  • 3 weeks later...
  • 4 weeks later...

then sey as that weys, some ppl will fix that i think

 

and here you have same code but some shorter :)

 

            L2Weapon curwep = activeChar.getActiveWeaponItem();
            if(curwep != null)
            {
            	if((curwep.getItemType() == L2WeaponType.DUAL && item.getItemType() == L2WeaponType.NONE)
            		|| (curwep.getItemType() == L2WeaponType.BOW && item.getItemType() == L2WeaponType.NONE)
            		|| (curwep.getItemType() == L2WeaponType.BIGBLUNT && item.getItemType() == L2WeaponType.NONE)
            		|| (curwep.getItemType() == L2WeaponType.BIGBLUNT && item.getItemType() == L2WeaponType.NONE)
            		|| (curwep.getItemType() == L2WeaponType.POLE && item.getItemType() == L2WeaponType.NONE)
            		|| (curwep.getItemType() == L2WeaponType.DUALFIST && item.getItemType() == L2WeaponType.NONE)
            		|| (curwep.getItemType() == L2WeaponType.DAGGER && item.getItemType() == L2WeaponType.DUALFIST)
            		|| (curwep.getItemType() == L2WeaponType.DAGGER && item.getItemType() == L2WeaponType.POLE)
            		|| (curwep.getItemType() == L2WeaponType.DAGGER && item.getItemType() == L2WeaponType.BIGBLUNT)
            		|| (curwep.getItemType() == L2WeaponType.DAGGER && item.getItemType() == L2WeaponType.BIGSWORD)
            		|| (curwep.getItemType() == L2WeaponType.DAGGER && item.getItemType() == L2WeaponType.BOW)
            		|| (curwep.getItemType() == L2WeaponType.DAGGER && item.getItemType() == L2WeaponType.DUAL)
            		|| (curwep.getItemType() == L2WeaponType.SWORD && item.getItemType() == L2WeaponType.DUALFIST)
            		|| (curwep.getItemType() == L2WeaponType.SWORD && item.getItemType() == L2WeaponType.POLE)
            		|| (curwep.getItemType() == L2WeaponType.SWORD && item.getItemType() == L2WeaponType.BIGBLUNT)
            		|| (curwep.getItemType() == L2WeaponType.SWORD && item.getItemType() == L2WeaponType.BIGSWORD)
            		|| (curwep.getItemType() == L2WeaponType.SWORD && item.getItemType() == L2WeaponType.BOW)
            		|| (curwep.getItemType() == L2WeaponType.SWORD && item.getItemType() == L2WeaponType.DUAL)
            		|| (curwep.getItemType() == L2WeaponType.BLUNT && item.getItemType() == L2WeaponType.DUALFIST)
            		|| (curwep.getItemType() == L2WeaponType.BLUNT && item.getItemType() == L2WeaponType.POLE)
            		|| (curwep.getItemType() == L2WeaponType.BLUNT && item.getItemType() == L2WeaponType.BIGBLUNT)
            		|| curwep.getItemType() == L2WeaponType.BLUNT && item.getItemType() == L2WeaponType.BIGSWORD)
            		|| (curwep.getItemType() == L2WeaponType.BLUNT && item.getItemType() == L2WeaponType.BOW)
            		|| (curwep.getItemType() == L2WeaponType.BLUNT && item.getItemType() == L2WeaponType.DUAL))
            	{
            		activeChar.sendMessage("You are not allowed to do this.");
            		return;
            	}	
            }

Link to comment
Share on other sites

  • 3 months later...

credits to setekh from L2J-Archid.

Credits to vago... Anyway i said it once and again.. the packet protection of auguments is stupid.. CUS IT OVERLAP! use item listeners.

Locked

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share



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