diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java index 1a985910dc..09aaa1dfcb 100644 --- a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java +++ b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java @@ -115,11 +115,11 @@ public class BeastSoulShot implements IItemHandler } // Pet uses the power of spirit. - activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); if (pet != null) { if (!pet.isChargedShot(ShotType.SOULSHOTS)) { + activeOwner.sendMessage("Your pet uses soulshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); pet.setChargedShot(ShotType.SOULSHOTS, true); // Visual effect change if player has equipped Ruby lvl 3 or higher if (activeOwner.getActiveRubyJewel() != null) @@ -137,6 +137,7 @@ public class BeastSoulShot implements IItemHandler { if (!s.isChargedShot(ShotType.SOULSHOTS)) { + activeOwner.sendMessage("Your servitor uses soulshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); s.setChargedShot(ShotType.SOULSHOTS, true); // Visual effect change if player has equipped Ruby lvl 3 or higher if (activeOwner.getActiveRubyJewel() != null) diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java index 765194563e..4e72564543 100644 --- a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java +++ b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java @@ -117,11 +117,11 @@ public class BeastSpiritShot implements IItemHandler } // Pet uses the power of spirit. - activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); if (pet != null) { if (!pet.isChargedShot(shotType)) { + activeOwner.sendMessage(isBlessed ? "Your pet uses blessed spiritshot." : "Your pet uses spiritshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); pet.setChargedShot(shotType, true); // Visual effect change if player has equipped Sapphire lvl 3 or higher if (activeOwner.getActiveShappireJewel() != null) @@ -139,6 +139,7 @@ public class BeastSpiritShot implements IItemHandler { if (!s.isChargedShot(shotType)) { + activeOwner.sendMessage(isBlessed ? "Your servitor uses blessed spiritshot." : "Your servitor uses spiritshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); s.setChargedShot(shotType, true); // Visual effect change if player has equipped Sapphire lvl 3 or higher if (activeOwner.getActiveShappireJewel() != null) diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java index 25f6828048..ca7c1239ec 100644 --- a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java +++ b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java @@ -115,11 +115,11 @@ public class BeastSoulShot implements IItemHandler } // Pet uses the power of spirit. - activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); if (pet != null) { if (!pet.isChargedShot(ShotType.SOULSHOTS)) { + activeOwner.sendMessage("Your pet uses soulshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); pet.chargeShot(ShotType.SOULSHOTS); // Visual effect change if player has equipped Ruby lvl 3 or higher if (activeOwner.getActiveRubyJewel() != null) @@ -137,6 +137,7 @@ public class BeastSoulShot implements IItemHandler { if (!s.isChargedShot(ShotType.SOULSHOTS)) { + activeOwner.sendMessage("Your servitor uses soulshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); s.chargeShot(ShotType.SOULSHOTS); // Visual effect change if player has equipped Ruby lvl 3 or higher if (activeOwner.getActiveRubyJewel() != null) diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java index de1917d42f..d631936c0d 100644 --- a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java +++ b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java @@ -117,11 +117,11 @@ public class BeastSpiritShot implements IItemHandler } // Pet uses the power of spirit. - activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); if (pet != null) { if (!pet.isChargedShot(shotType)) { + activeOwner.sendMessage(isBlessed ? "Your pet uses blessed spiritshot." : "Your pet uses spiritshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); pet.chargeShot(shotType); // Visual effect change if player has equipped Sapphire lvl 3 or higher if (activeOwner.getActiveShappireJewel() != null) @@ -139,6 +139,7 @@ public class BeastSpiritShot implements IItemHandler { if (!s.isChargedShot(shotType)) { + activeOwner.sendMessage(isBlessed ? "Your servitor uses blessed spiritshot." : "Your servitor uses spiritshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); s.chargeShot(shotType); // Visual effect change if player has equipped Sapphire lvl 3 or higher if (activeOwner.getActiveShappireJewel() != null) diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java index e32cce9e1f..1349e24ba8 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java @@ -18,6 +18,7 @@ package com.l2jmobius.gameserver.network.clientpackets; import com.l2jmobius.commons.network.PacketReader; import com.l2jmobius.gameserver.enums.PrivateStoreType; +import com.l2jmobius.gameserver.enums.ShotType; import com.l2jmobius.gameserver.model.actor.L2Summon; import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.items.L2Item; @@ -118,21 +119,32 @@ public final class RequestAutoSoulShot implements IClientIncomingPacket activeChar.addAutoSoulShot(_itemId); client.sendPacket(new ExAutoSoulShot(_itemId, _enable, _type)); - // Send message - final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_AUTOMATIC_USE_OF_S1_HAS_BEEN_ACTIVATED); - sm.addItemName(item); - client.sendPacket(sm); - // Recharge summon's shots final L2Summon pet = activeChar.getPet(); if (pet != null) { + // Send message + if (!pet.isChargedShot(item.getItem().getDefaultAction() == ActionType.SUMMON_SOULSHOT ? ShotType.SOULSHOTS : ((item.getId() == 6647) || (item.getId() == 20334)) ? ShotType.BLESSED_SPIRITSHOTS : ShotType.SPIRITSHOTS)) + { + final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_AUTOMATIC_USE_OF_S1_HAS_BEEN_ACTIVATED); + sm.addItemName(item); + client.sendPacket(sm); + } + // Charge pet.rechargeShots(isSoulshot, isSpiritshot, false); } - activeChar.getServitors().values().forEach(s -> + for (L2Summon summon : activeChar.getServitors().values()) { - s.rechargeShots(isSoulshot, isSpiritshot, false); - }); + // Send message + if (!summon.isChargedShot(item.getItem().getDefaultAction() == ActionType.SUMMON_SOULSHOT ? ShotType.SOULSHOTS : ((item.getId() == 6647) || (item.getId() == 20334)) ? ShotType.BLESSED_SPIRITSHOTS : ShotType.SPIRITSHOTS)) + { + final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_AUTOMATIC_USE_OF_S1_HAS_BEEN_ACTIVATED); + sm.addItemName(item); + client.sendPacket(sm); + } + // Charge + summon.rechargeShots(isSoulshot, isSpiritshot, false); + } } else { diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java index 25f6828048..ca7c1239ec 100644 --- a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java +++ b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java @@ -115,11 +115,11 @@ public class BeastSoulShot implements IItemHandler } // Pet uses the power of spirit. - activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); if (pet != null) { if (!pet.isChargedShot(ShotType.SOULSHOTS)) { + activeOwner.sendMessage("Your pet uses soulshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); pet.chargeShot(ShotType.SOULSHOTS); // Visual effect change if player has equipped Ruby lvl 3 or higher if (activeOwner.getActiveRubyJewel() != null) @@ -137,6 +137,7 @@ public class BeastSoulShot implements IItemHandler { if (!s.isChargedShot(ShotType.SOULSHOTS)) { + activeOwner.sendMessage("Your servitor uses soulshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); s.chargeShot(ShotType.SOULSHOTS); // Visual effect change if player has equipped Ruby lvl 3 or higher if (activeOwner.getActiveRubyJewel() != null) diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java index de1917d42f..d631936c0d 100644 --- a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java +++ b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java @@ -117,11 +117,11 @@ public class BeastSpiritShot implements IItemHandler } // Pet uses the power of spirit. - activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); if (pet != null) { if (!pet.isChargedShot(shotType)) { + activeOwner.sendMessage(isBlessed ? "Your pet uses blessed spiritshot." : "Your pet uses spiritshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); pet.chargeShot(shotType); // Visual effect change if player has equipped Sapphire lvl 3 or higher if (activeOwner.getActiveShappireJewel() != null) @@ -139,6 +139,7 @@ public class BeastSpiritShot implements IItemHandler { if (!s.isChargedShot(shotType)) { + activeOwner.sendMessage(isBlessed ? "Your servitor uses blessed spiritshot." : "Your servitor uses spiritshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); s.chargeShot(shotType); // Visual effect change if player has equipped Sapphire lvl 3 or higher if (activeOwner.getActiveShappireJewel() != null) diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java index e32cce9e1f..1349e24ba8 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java @@ -18,6 +18,7 @@ package com.l2jmobius.gameserver.network.clientpackets; import com.l2jmobius.commons.network.PacketReader; import com.l2jmobius.gameserver.enums.PrivateStoreType; +import com.l2jmobius.gameserver.enums.ShotType; import com.l2jmobius.gameserver.model.actor.L2Summon; import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.items.L2Item; @@ -118,21 +119,32 @@ public final class RequestAutoSoulShot implements IClientIncomingPacket activeChar.addAutoSoulShot(_itemId); client.sendPacket(new ExAutoSoulShot(_itemId, _enable, _type)); - // Send message - final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_AUTOMATIC_USE_OF_S1_HAS_BEEN_ACTIVATED); - sm.addItemName(item); - client.sendPacket(sm); - // Recharge summon's shots final L2Summon pet = activeChar.getPet(); if (pet != null) { + // Send message + if (!pet.isChargedShot(item.getItem().getDefaultAction() == ActionType.SUMMON_SOULSHOT ? ShotType.SOULSHOTS : ((item.getId() == 6647) || (item.getId() == 20334)) ? ShotType.BLESSED_SPIRITSHOTS : ShotType.SPIRITSHOTS)) + { + final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_AUTOMATIC_USE_OF_S1_HAS_BEEN_ACTIVATED); + sm.addItemName(item); + client.sendPacket(sm); + } + // Charge pet.rechargeShots(isSoulshot, isSpiritshot, false); } - activeChar.getServitors().values().forEach(s -> + for (L2Summon summon : activeChar.getServitors().values()) { - s.rechargeShots(isSoulshot, isSpiritshot, false); - }); + // Send message + if (!summon.isChargedShot(item.getItem().getDefaultAction() == ActionType.SUMMON_SOULSHOT ? ShotType.SOULSHOTS : ((item.getId() == 6647) || (item.getId() == 20334)) ? ShotType.BLESSED_SPIRITSHOTS : ShotType.SPIRITSHOTS)) + { + final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_AUTOMATIC_USE_OF_S1_HAS_BEEN_ACTIVATED); + sm.addItemName(item); + client.sendPacket(sm); + } + // Charge + summon.rechargeShots(isSoulshot, isSpiritshot, false); + } } else { diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java index 25f6828048..ca7c1239ec 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/itemhandlers/BeastSoulShot.java @@ -115,11 +115,11 @@ public class BeastSoulShot implements IItemHandler } // Pet uses the power of spirit. - activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); if (pet != null) { if (!pet.isChargedShot(ShotType.SOULSHOTS)) { + activeOwner.sendMessage("Your pet uses soulshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); pet.chargeShot(ShotType.SOULSHOTS); // Visual effect change if player has equipped Ruby lvl 3 or higher if (activeOwner.getActiveRubyJewel() != null) @@ -137,6 +137,7 @@ public class BeastSoulShot implements IItemHandler { if (!s.isChargedShot(ShotType.SOULSHOTS)) { + activeOwner.sendMessage("Your servitor uses soulshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); s.chargeShot(ShotType.SOULSHOTS); // Visual effect change if player has equipped Ruby lvl 3 or higher if (activeOwner.getActiveRubyJewel() != null) diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java index de1917d42f..d631936c0d 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/itemhandlers/BeastSpiritShot.java @@ -117,11 +117,11 @@ public class BeastSpiritShot implements IItemHandler } // Pet uses the power of spirit. - activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); if (pet != null) { if (!pet.isChargedShot(shotType)) { + activeOwner.sendMessage(isBlessed ? "Your pet uses blessed spiritshot." : "Your pet uses spiritshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); pet.chargeShot(shotType); // Visual effect change if player has equipped Sapphire lvl 3 or higher if (activeOwner.getActiveShappireJewel() != null) @@ -139,6 +139,7 @@ public class BeastSpiritShot implements IItemHandler { if (!s.isChargedShot(shotType)) { + activeOwner.sendMessage(isBlessed ? "Your servitor uses blessed spiritshot." : "Your servitor uses spiritshot."); // activeOwner.sendPacket(SystemMessageId.YOUR_PET_USES_SPIRITSHOT); s.chargeShot(shotType); // Visual effect change if player has equipped Sapphire lvl 3 or higher if (activeOwner.getActiveShappireJewel() != null) diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java index e32cce9e1f..1349e24ba8 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestAutoSoulShot.java @@ -18,6 +18,7 @@ package com.l2jmobius.gameserver.network.clientpackets; import com.l2jmobius.commons.network.PacketReader; import com.l2jmobius.gameserver.enums.PrivateStoreType; +import com.l2jmobius.gameserver.enums.ShotType; import com.l2jmobius.gameserver.model.actor.L2Summon; import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.items.L2Item; @@ -118,21 +119,32 @@ public final class RequestAutoSoulShot implements IClientIncomingPacket activeChar.addAutoSoulShot(_itemId); client.sendPacket(new ExAutoSoulShot(_itemId, _enable, _type)); - // Send message - final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_AUTOMATIC_USE_OF_S1_HAS_BEEN_ACTIVATED); - sm.addItemName(item); - client.sendPacket(sm); - // Recharge summon's shots final L2Summon pet = activeChar.getPet(); if (pet != null) { + // Send message + if (!pet.isChargedShot(item.getItem().getDefaultAction() == ActionType.SUMMON_SOULSHOT ? ShotType.SOULSHOTS : ((item.getId() == 6647) || (item.getId() == 20334)) ? ShotType.BLESSED_SPIRITSHOTS : ShotType.SPIRITSHOTS)) + { + final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_AUTOMATIC_USE_OF_S1_HAS_BEEN_ACTIVATED); + sm.addItemName(item); + client.sendPacket(sm); + } + // Charge pet.rechargeShots(isSoulshot, isSpiritshot, false); } - activeChar.getServitors().values().forEach(s -> + for (L2Summon summon : activeChar.getServitors().values()) { - s.rechargeShots(isSoulshot, isSpiritshot, false); - }); + // Send message + if (!summon.isChargedShot(item.getItem().getDefaultAction() == ActionType.SUMMON_SOULSHOT ? ShotType.SOULSHOTS : ((item.getId() == 6647) || (item.getId() == 20334)) ? ShotType.BLESSED_SPIRITSHOTS : ShotType.SPIRITSHOTS)) + { + final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_AUTOMATIC_USE_OF_S1_HAS_BEEN_ACTIVATED); + sm.addItemName(item); + client.sendPacket(sm); + } + // Charge + summon.rechargeShots(isSoulshot, isSpiritshot, false); + } } else {