Jump to content

Recommended Posts

Posted

If you want to prevent to some class use some kind of equipment (for example Titan with bow) you can use this script.

You need to insert to network/clientpackets/UseItem.java the following lines:

 

 

if (item.isEquipable())

{

if (activeChar.isDisarmed())

return;

 

if (!((L2Equip) item.getItem()).allowEquip(activeChar))

{

activeChar.sendPacket(new SystemMessage(SystemMessageId.NO_CONDITION_TO_EQUIP));

return;

}

 

//Begining the script

+ if (activeChar.getClassId().getId() == 88)

+ {

+ if (item.getItemType() == L2ArmorType.MAGIC)

+ {

+ activeChar.sendPacket(new +SystemMessage(SystemMessageId.NO_CONDITION_TO_EQUIP));

+ return;

+ }

+ }

 

 

In this example the class is Duelist and the item type is robe armor.

If you want the same with some kind of weapon you need to change the line

if (item.getItemType() == L2ArmorType.MAGIC)

to

if (item.getItemType() == L2WeaponType.DAGGER)

the available class-ids and item types are listed below.

 

To prevent sub-class bugging i use this script to unequip all the armors/weapon/jewels on class changing:

 

model/actor/instance/L2PcInstance.java

/**

* Changes the character's class based on the given class index.

* <BR><BR>

* An index of zero specifies the character's original (base) class,

* while indexes 1-3 specifies the character's sub-classes respectively.

*

* @param classIndex

*/

public boolean setActiveClass(int classIndex)

{

+ L2ItemInstance chest = getInventory().getPaperdollItem(Inventory.PAPERDOLL_CHEST);

+ if (chest != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(chest.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+

+ L2ItemInstance head = getInventory().getPaperdollItem(Inventory.PAPERDOLL_HEAD);

+ if (head != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(head.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+

+ L2ItemInstance gloves = getInventory().getPaperdollItem(Inventory.PAPERDOLL_GLOVES);

+ if (gloves != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(gloves.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+

+ L2ItemInstance feet = getInventory().getPaperdollItem(Inventory.PAPERDOLL_FEET);

+ if (feet != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(feet.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+

+ L2ItemInstance legs = getInventory().getPaperdollItem(Inventory.PAPERDOLL_LEGS);

+ if (legs != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(legs.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+

+ L2ItemInstance rhand = getInventory().getPaperdollItem(Inventory.PAPERDOLL_RHAND);

+ if (rhand != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(rhand.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+

+ L2ItemInstance lhand = getInventory().getPaperdollItem(Inventory.PAPERDOLL_LHAND);

+ if (lhand != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(lhand.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+ L2ItemInstance lear = getInventory().getPaperdollItem(Inventory.PAPERDOLL_LEAR);

+ if (lhand != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(lear.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+ L2ItemInstance rear = getInventory().getPaperdollItem(Inventory.PAPERDOLL_REAR);

+ if (lhand != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(rear.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+ L2ItemInstance neck = getInventory().getPaperdollItem(Inventory.PAPERDOLL_NECK);

+ if (lhand != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(neck.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+ L2ItemInstance lfinger = getInventory().getPaperdollItem(Inventory.PAPERDOLL_LFINGER);

+ if (lhand != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(lfinger.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+ L2ItemInstance rfinger = getInventory().getPaperdollItem(Inventory.PAPERDOLL_RFINGER);

+ if (lhand != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(rfinger.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

+ L2ItemInstance under = getInventory().getPaperdollItem(Inventory.PAPERDOLL_UNDER);

+ if (lhand != null)

+ {

+

+ L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(under.getItem().getBodyPart());

+ InventoryUpdate iu = new InventoryUpdate();

+ for (L2ItemInstance element : unequipped)

+ iu.addModifiedItem(element);

+ sendPacket(iu);

+

+ }

 

[table][tr][td]Class ID-s:[/td][td]Item types[/td][/tr][tr][td]HUMANS

-- 0=Human Fighter | 1=Warrior | 2=Gladiator | 3=Warlord | 4=Human Knight

-- 5=Paladin | 6=Dark Avenger | 7=Rogue | 8=Treasure Hunter | 9=Hawkeye

-- 10=Human Mystic | 11=Wizard | 12=Sorcerer/ss | 13=Necromancer | 14=Warlock

-- 15=Cleric | 16=Bishop | 17=Prophet

 

-- ELVES

-- 18=Elven Fighter | 19=Elven Knight | 20=Temple Knight | 21=Swordsinger | 22=Elven Scout

-- 23=Plainswalker | 24=Silver Ranger | 25=Elven Mystic | 26=Elven Wizard | 27=Spellsinger

-- 28=Elemental Summoner | 29=Elven Oracle | 30=Elven Elder

 

-- DARK ELVES

-- 31=Dark Fighter | 32=Palus Knight | 33=Shillien Knight | 34=Bladedancer | 35=Assassin

-- 36=Abyss Walker | 37=Phantom Ranger | 38=Dark Mystic | 39=Dark Wizard | 40=Spellhowler

-- 41=Phantom Summoner | 42=Shillien Oracle | 43=Shillien Elder

 

-- ORCS

-- 44=Orc Fighter | 45=Orc Raider | 46=Destroyer | 47=Monk | 48=Tyrant

-- 49=Orc Mystic | 50=Orc Shaman | 51=Overlord | 52=Warcryer

 

-- DWARVES

-- 53=Dwarven Fighter | 54=Scavenger | 55=Bounty Hunter | 56=Artisan | 57=Warsmith

 

-- HUMANS 3rd Professions

-- 88=Duelist | 89=Dreadnought | 90=Phoenix Knight | 91=Hell Knight | 92=Sagittarius

-- 93=Adventurer | 94=Archmage | 95=Soultaker | 96=Arcana Lord | 97=Cardinal

-- 98=Hierophant

 

-- ELVES 3rd Professions

-- 99=Evas Templar | 100=Sword Muse | 101=Wind Rider | 102=Moonlight Sentinel

-- 103=Mystic Muse | 104=Elemental Master | 105=Evas Saint

 

-- DARK ELVES 3rd Professions

-- 106=Shillien Templar | 107=Spectral Dancer | 108=Ghost Hunter | 109=Ghost Sentinel

-- 110=Storm Screamer | 111=Spectral Master | 112=Shillien Saint

 

-- ORCS 3rd Professions

-- 113=Titan | 114=Grand Khavatari

-- 115=Dominator | 116=Doomcryer

 

-- DWARVES 3rd Professions

-- 117=Fortune Seeker | 118=Maestro

 

-- KAMAELS

-- 123=Male Soldier | 124=Female Soldier | 125=Trooper | 126=Warder

-- 127=Berserker | 128=Male Soul Breaker | 129=Female Soul Breaker | 130=Arbalester

-- 131=Doombringer | 132=Male Soul Hound | 133=Female Soul Hound | 134=Trickster

-- 135=Inspector | 136=Judicator [/td][td]-Weapons-

NONE (Shield)

SWORD

BLUNT

DAGGER

BOW

POLE

ETC

FIST

DUAL

DUALFIST

BIGSWORD (Two Handed Swords)

PET

ROD

BIGBLUNT (Two handed blunt)

ANCIENT_SWORD

CROSSBOW

RAPIER

 

-Armors-

HEAVY

LIGHT

MAGIC

[/td][/tr][/table]

 

Tested on L2JFree. I hope this share was usefull. and sorry for my bad english:P

Posted

+1 karma for your both shares.Really nice.That's the part that maxcheaters is missing,the development on java.Keep it up dude.

  • 1 month later...
Posted

do i have to replace this with urs?

 

            if (item.isEquipable())
            {
            	// No unequipping/equipping while the player is in special conditions
			if (activeChar.isStunned() || activeChar.isSleeping() || activeChar.isParalyzed()
					|| activeChar.isAlikeDead())
			{
				activeChar.sendMessage("Your status does not allow you to do that.");
				return;
			}

			int bodyPart = item.getItem().getBodyPart();

			// Prevent player to remove the weapon on special conditions
                if ((activeChar.isAttackingNow() || activeChar.isCastingNow() || activeChar.isMounted() || (activeChar._inEventCTF && activeChar._haveFlagCTF))
                        && (bodyPart == L2Item.SLOT_LR_HAND 
                            || bodyPart == L2Item.SLOT_L_HAND 
                            || bodyPart == L2Item.SLOT_R_HAND))
                {
                    if (activeChar._inEventCTF && activeChar._haveFlagCTF)
                    	activeChar.sendMessage("This item can not be equipped when you have the flag.");
                	return;
                }
                
                // Don't allow weapon/shield equipment if a cursed weapon is equiped
                if (activeChar.isCursedWeaponEquiped()
                       && ((bodyPart == L2Item.SLOT_LR_HAND 
                               || bodyPart == L2Item.SLOT_L_HAND 
                               || bodyPart == L2Item.SLOT_R_HAND)
                       || itemId == 6408)) // Don't allow to put formal wear
                {
                   return;
                }

 

 

also if i add it can i add multiple numbers like that?

 

 

+			if (activeChar.getClassId().getId() == 88,117,118

 

 

Posted
Buildfile: C:\Documents and Settings\workspace\L2_GameServer_It\build.xml
clean:
init:
    [mkdir] Created dir: C:\Documents and Settings\workspace\L2_GameServer_It\build
    [mkdir] Created dir: C:\Documents and Settings\workspace\L2_GameServer_It\build\classes
    [mkdir] Created dir: C:\Documents and Settings\workspace\L2_GameServer_It\build\dist
    [mkdir] Created dir: C:\Documents and Settings\workspace\L2_GameServer_It\build\dist\login
    [mkdir] Created dir: C:\Documents and Settings\workspace\L2_GameServer_It\build\dist\gameserver
version:
     [exec] Execute failed: java.io.IOException: Cannot run program "svnversion": CreateProcess error=2, ??? ????? ?????? ? ?????? ??? ???????????? ??????? ??? ?? ???????
compile:
    [javac] Compiling 1214 source files to C:\Documents and Settings\workspace\L2_GameServer_It\build\classes
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\clientpackets\UseItem.java:402: class, interface, or enum expected
    [javac] if (item.isEquipable())
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\clientpackets\UseItem.java:407: class, interface, or enum expected
    [javac] 			if (!((L2Equip) item.getItem()).allowEquip(activeChar))
    [javac] 			^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\clientpackets\UseItem.java:410: class, interface, or enum expected
    [javac] 				return;
    [javac] 				^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\clientpackets\UseItem.java:411: class, interface, or enum expected
    [javac] 			}
    [javac] 			^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\clientpackets\UseItem.java:419: class, interface, or enum expected
    [javac] +					return;
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\clientpackets\UseItem.java:420: class, interface, or enum expected
    [javac] +				}	
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8539: not a statement
    [javac] +		L2ItemInstance chest = getInventory().getPaperdollItem(Inventory.PAPERDOLL_CHEST);
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8539: ';' expected
    [javac] +		L2ItemInstance chest = getInventory().getPaperdollItem(Inventory.PAPERDOLL_CHEST);
    [javac]  		              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8540: illegal start of expression
    [javac] +		if (chest != null)
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8540: not a statement
    [javac] +		if (chest != null)
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8541: illegal start of expression
    [javac] +		{
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8541: not a statement
    [javac] +		{
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8543: '.class' expected
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(chest.getItem().getBodyPart());
    [javac]  				                 ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8542: not a statement
    [javac] +			
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8543: illegal start of expression
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(chest.getItem().getBodyPart());
    [javac]  				                            ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8543: not a statement
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(chest.getItem().getBodyPart());
    [javac]  				                              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8544: not a statement
    [javac] +				InventoryUpdate iu = new InventoryUpdate();
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8544: ';' expected
    [javac] +				InventoryUpdate iu = new InventoryUpdate();
    [javac]  				               ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8545: illegal start of expression
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8545: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8545: ')' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                   ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8545: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				    ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8545: ';' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                           ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8545: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8545: ';' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                                        ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8547: not a statement
    [javac] +				sendPacket(iu);
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8549: illegal start of expression
    [javac] +		}
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8548: not a statement
    [javac] +			
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8550: not a statement
    [javac] +		
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8551: ';' expected
    [javac] +		L2ItemInstance head = getInventory().getPaperdollItem(Inventory.PAPERDOLL_HEAD);
    [javac]  		              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8552: illegal start of expression
    [javac] +		if (head != null)
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8552: not a statement
    [javac] +		if (head != null)
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8553: illegal start of expression
    [javac] +		{
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8553: not a statement
    [javac] +		{
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8555: '.class' expected
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(head.getItem().getBodyPart());
    [javac]  				                 ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8554: not a statement
    [javac] +			
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8555: illegal start of expression
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(head.getItem().getBodyPart());
    [javac]  				                            ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8555: not a statement
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(head.getItem().getBodyPart());
    [javac]  				                              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8556: not a statement
    [javac] +				InventoryUpdate iu = new InventoryUpdate();
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8556: ';' expected
    [javac] +				InventoryUpdate iu = new InventoryUpdate();
    [javac]  				               ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8557: illegal start of expression
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8557: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8557: ')' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                   ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8557: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				    ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8557: ';' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                           ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8557: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8557: ';' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                                        ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8559: not a statement
    [javac] +				sendPacket(iu);
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8561: illegal start of expression
    [javac] +		}
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8560: not a statement
    [javac] +			
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8562: not a statement
    [javac] +		
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8563: ';' expected
    [javac] +		L2ItemInstance gloves = getInventory().getPaperdollItem(Inventory.PAPERDOLL_GLOVES);
    [javac]  		              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8564: illegal start of expression
    [javac] +		if (gloves != null)
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8564: not a statement
    [javac] +		if (gloves != null)
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8565: illegal start of expression
    [javac] +		{
    [javac]  		^

Posted

    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8565: not a statement
    [javac] +		{
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8567: '.class' expected
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(gloves.getItem().getBodyPart());
    [javac]  				                 ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8566: not a statement
    [javac] +			
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8567: illegal start of expression
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(gloves.getItem().getBodyPart());
    [javac]  				                            ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8567: not a statement
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(gloves.getItem().getBodyPart());
    [javac]  				                              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8568: not a statement
    [javac] +				InventoryUpdate iu = new InventoryUpdate();
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8568: ';' expected
    [javac] +				InventoryUpdate iu = new InventoryUpdate();
    [javac]  				               ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8569: illegal start of expression
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8569: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8569: ')' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                   ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8569: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				    ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8569: ';' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                           ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8569: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8569: ';' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                                        ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8571: not a statement
    [javac] +				sendPacket(iu);
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8573: illegal start of expression
    [javac] +		}
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8572: not a statement
    [javac] +			
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8574: not a statement
    [javac] +		
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8575: ';' expected
    [javac] +		L2ItemInstance feet = getInventory().getPaperdollItem(Inventory.PAPERDOLL_FEET);
    [javac]  		              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8576: illegal start of expression
    [javac] +		if (feet != null)
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8576: not a statement
    [javac] +		if (feet != null)
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8577: illegal start of expression
    [javac] +		{
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8577: not a statement
    [javac] +		{
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8579: '.class' expected
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(feet.getItem().getBodyPart());
    [javac]  				                 ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8578: not a statement
    [javac] +			
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8579: illegal start of expression
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(feet.getItem().getBodyPart());
    [javac]  				                            ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8579: not a statement
    [javac] +				L2ItemInstance[] unequipped = +getInventory().unEquipItemInBodySlotAndRecord(feet.getItem().getBodyPart());
    [javac]  				                              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8580: not a statement
    [javac] +				InventoryUpdate iu = new InventoryUpdate();
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8580: ';' expected
    [javac] +				InventoryUpdate iu = new InventoryUpdate();
    [javac]  				               ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8581: illegal start of expression
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8581: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8581: ')' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                   ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8581: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				    ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8581: ';' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                           ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8581: not a statement
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8581: ';' expected
    [javac] +				for (L2ItemInstance element : unequipped)
    [javac]  				                                        ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8583: not a statement
    [javac] +				sendPacket(iu);
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8585: illegal start of expression
    [javac] +		}
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8584: not a statement
    [javac] +			
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8586: not a statement
    [javac] +		
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8587: ';' expected
    [javac] +		L2ItemInstance legs = getInventory().getPaperdollItem(Inventory.PAPERDOLL_LEGS);
    [javac]  		              ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8588: illegal start of expression
    [javac] +		if (legs != null)
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8588: not a statement
    [javac] +		if (legs != null)
    [javac] ^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8589: illegal start of expression
    [javac] +		{
    [javac]  		^
    [javac] C:\Documents and Settings\workspace\L2_GameServer_It\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:8589: not a statement
    [javac] +		{
    [javac] ^
    [javac] 100 errors

BUILD FAILED
C:\Documents and Settings\workspace\L2_GameServer_It\build.xml:67: Compile failed; see the compiler error output for details.

Total time: 6 seconds

 

 

First sorry for double post i could write over 20000 characters...

 

 

Second What have i to make now?

Posted

First sorry for double post i could write over 20000 characters...

 

 

Second What have i to make now?

 

what a nab!

 

you must remove the + !!!

 

Also, I applied Succsessfully this to L2J (in eclipse), lets Hope it will Work in Game too . I will post a feedback later.

Posted

ok, here my FeedBack :

 

      if (activeChar.getClassId().getId() == 88)

        {

            if (item.getItemType() == L2ArmorType.MAGIC)

            {

              activeChar.sendPacket(new +SystemMessage(SystemMessageId.NO_CONDITION_TO_EQUIP));

              return;

            } 

        }

 

Armor Types for Me Didnt Worked at all (tried only MAGIC) maybe is different in L2J.

 

################################################################

 

 

        if (activeChar.getClassId().getId() == 88)

        {

            if (item.getItemType() == L2ArmorType.BOW)

            {

              activeChar.sendPacket(new +SystemMessage(SystemMessageId.NO_CONDITION_TO_EQUIP));

              return;

            } 

        }

 

This Worked.

 

#################################################################

 

 

The sub-class bugging Prevention Worked Well.

 

#################################################################

 

 

Now My Question is : How can be In L2J the Armor Type ? I mean...Why the Hell didnt worked ?

Posted

Ok i done it....

 

Whats ur problem ?

 

i dont care what u say i am new to java....

what a nab!

 

you must remove the + !!!

 

Also, I applied Succsessfully this to L2J (in eclipse), lets Hope it will Work in Game too . I will post a feedback later.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.




×
×
  • Create New...