Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Index: head-src/com/l2jfrozen/gameserver/model/Inventory.java
- ===================================================================
- --- head-src/com/l2jfrozen/gameserver/model/Inventory.java (revision 1004)
- +++ head-src/com/l2jfrozen/gameserver/model/Inventory.java (working copy)
- @@ -1180,7 +1180,7 @@
- *
- * @param slot : int designating the slot
- */
- - private void unEquipItemInBodySlot(int slot)
- + public void unEquipItemInBodySlot(int slot)
- {
- if(Config.DEBUG)
- {
- Index: head-src/com/l2jfrozen/gameserver/network/clientpackets/EnterWorld.java
- ===================================================================
- --- head-src/com/l2jfrozen/gameserver/network/clientpackets/EnterWorld.java (revision 1004)
- +++ head-src/com/l2jfrozen/gameserver/network/clientpackets/EnterWorld.java (working copy)
- @@ -51,6 +51,7 @@
- import com.l2jfrozen.gameserver.model.actor.instance.L2ClassMasterInstance;
- import com.l2jfrozen.gameserver.model.actor.instance.L2ItemInstance;
- import com.l2jfrozen.gameserver.model.actor.instance.L2PcInstance;
- +import com.l2jfrozen.gameserver.model.base.ClassId;
- import com.l2jfrozen.gameserver.model.base.ClassLevel;
- import com.l2jfrozen.gameserver.model.base.PlayerClass;
- import com.l2jfrozen.gameserver.model.entity.Announcements;
- @@ -92,6 +93,7 @@
- import com.l2jfrozen.gameserver.network.serverpackets.SystemMessage;
- import com.l2jfrozen.gameserver.network.serverpackets.UserInfo;
- import com.l2jfrozen.gameserver.powerpak.PowerPakConfig;
- +import com.l2jfrozen.gameserver.templates.L2WeaponType;
- import com.l2jfrozen.gameserver.thread.TaskPriority;
- import com.l2jfrozen.gameserver.thread.ThreadPoolManager;
- import com.l2jfrozen.gameserver.util.Util;
- @@ -406,6 +408,17 @@
- activeChar.teleToLocation(MapRegionTable.TeleportWhereType.Town);
- activeChar.sendMessage("You have been teleported to the nearest town due to you being in siege zone");
- }
- +
- + if (activeChar.getClassId() == ClassId.phoenixKnight || activeChar.getClassId() == ClassId.hellKnight || activeChar.getClassId() == ClassId.evaTemplar || activeChar.getClassId() == ClassId.shillienTemplar)
- + {
- + L2ItemInstance item = activeChar.getInventory().getPaperdollItem(Inventory.PAPERDOLL_RHAND);
- +
- + if (item != null && item.getItemType() == L2WeaponType.BOW)
- + {
- + int slot = activeChar.getInventory().getSlotFromItem(item);
- + activeChar.getInventory().unEquipItemInBodySlot(slot);
- + }
- + }
- RegionBBSManager.getInstance().changeCommunityBoard();
- CustomWorldHandler.getInstance().enterWorld(activeChar);
- Index: head-src/com/l2jfrozen/gameserver/network/clientpackets/UseItem.java
- ===================================================================
- --- head-src/com/l2jfrozen/gameserver/network/clientpackets/UseItem.java (revision 1004)
- +++ head-src/com/l2jfrozen/gameserver/network/clientpackets/UseItem.java (working copy)
- @@ -33,6 +33,7 @@
- import com.l2jfrozen.gameserver.model.L2Object;
- import com.l2jfrozen.gameserver.model.actor.instance.L2ItemInstance;
- import com.l2jfrozen.gameserver.model.actor.instance.L2PcInstance;
- +import com.l2jfrozen.gameserver.model.base.ClassId;
- import com.l2jfrozen.gameserver.network.SystemMessageId;
- import com.l2jfrozen.gameserver.network.serverpackets.ActionFailed;
- import com.l2jfrozen.gameserver.network.serverpackets.EtcStatusUpdate;
- @@ -194,6 +195,12 @@
- return;
- }
- + if ((activeChar.getClassId() == ClassId.phoenixKnight || activeChar.getClassId() == ClassId.hellKnight || activeChar.getClassId() == ClassId.evaTemplar || activeChar.getClassId() == ClassId.shillienTemplar) && item.getItemType() == L2WeaponType.BOW)
- + {
- + activeChar.sendMessage("You can't equip that");
- + return;
- + }
- +
- // Scroll of resurrection like L2OFF if you are casting you can't use them
- if ((itemId == 737 || itemId == 3936 || itemId == 3959 || itemId == 6387) && activeChar.isCastingNow())
- return;
- Index: head-src/com/l2jfrozen/gameserver/model/actor/instance/L2PcInstance.java
- ===================================================================
- --- head-src/com/l2jfrozen/gameserver/model/actor/instance/L2PcInstance.java (revision 1004)
- +++ head-src/com/l2jfrozen/gameserver/model/actor/instance/L2PcInstance.java (working copy)
- @@ -15447,6 +15447,17 @@
- _macroses.sendUpdate();
- _shortCuts.restore();
- sendPacket(new ShortCutInit(this));
- +
- + if (getClassId() == ClassId.phoenixKnight || getClassId() == ClassId.hellKnight || getClassId() == ClassId.evaTemplar || getClassId() == ClassId.shillienTemplar)
- + {
- + L2ItemInstance item = getInventory().getPaperdollItem(Inventory.PAPERDOLL_RHAND);
- +
- + if (item != null && item.getItemType() == L2WeaponType.BOW)
- + {
- + int slot = getInventory().getSlotFromItem(item);
- + getInventory().unEquipItemInBodySlot(slot);
- + }
- + }
- // Rebirth Caller - if player has any skills, they will be granted them.
- if(Config.REBIRTH_ENABLE)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement