diff --git a/L2J_Mobius_01.0_Ertheia/dist/game/config/NPC.ini b/L2J_Mobius_01.0_Ertheia/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_01.0_Ertheia/dist/game/config/NPC.ini +++ b/L2J_Mobius_01.0_Ertheia/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_01.0_Ertheia/java/org/l2jmobius/Config.java b/L2J_Mobius_01.0_Ertheia/java/org/l2jmobius/Config.java index af0d32a9e0..613eb3c1d1 100644 --- a/L2J_Mobius_01.0_Ertheia/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_01.0_Ertheia/java/org/l2jmobius/Config.java @@ -627,6 +627,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2100,6 +2101,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_01.0_Ertheia/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_01.0_Ertheia/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_01.0_Ertheia/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_01.0_Ertheia/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_02.5_Underground/dist/game/config/NPC.ini b/L2J_Mobius_02.5_Underground/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_02.5_Underground/dist/game/config/NPC.ini +++ b/L2J_Mobius_02.5_Underground/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_02.5_Underground/java/org/l2jmobius/Config.java b/L2J_Mobius_02.5_Underground/java/org/l2jmobius/Config.java index c85f4a572e..2e4dea14d5 100644 --- a/L2J_Mobius_02.5_Underground/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_02.5_Underground/java/org/l2jmobius/Config.java @@ -637,6 +637,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2123,6 +2124,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_02.5_Underground/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_02.5_Underground/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_02.5_Underground/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_02.5_Underground/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_03.0_Helios/dist/game/config/NPC.ini b/L2J_Mobius_03.0_Helios/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_03.0_Helios/dist/game/config/NPC.ini +++ b/L2J_Mobius_03.0_Helios/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_03.0_Helios/java/org/l2jmobius/Config.java b/L2J_Mobius_03.0_Helios/java/org/l2jmobius/Config.java index 1be266e03f..aef3472cc4 100644 --- a/L2J_Mobius_03.0_Helios/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_03.0_Helios/java/org/l2jmobius/Config.java @@ -637,6 +637,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2136,6 +2137,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_03.0_Helios/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_03.0_Helios/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_03.0_Helios/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_03.0_Helios/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_04.0_GrandCrusade/dist/game/config/NPC.ini b/L2J_Mobius_04.0_GrandCrusade/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_04.0_GrandCrusade/dist/game/config/NPC.ini +++ b/L2J_Mobius_04.0_GrandCrusade/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_04.0_GrandCrusade/java/org/l2jmobius/Config.java b/L2J_Mobius_04.0_GrandCrusade/java/org/l2jmobius/Config.java index c2905936bc..9084aa319d 100644 --- a/L2J_Mobius_04.0_GrandCrusade/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_04.0_GrandCrusade/java/org/l2jmobius/Config.java @@ -624,6 +624,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2116,6 +2117,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_04.0_GrandCrusade/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_04.0_GrandCrusade/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_04.0_GrandCrusade/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_04.0_GrandCrusade/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_05.0_Salvation/dist/game/config/NPC.ini b/L2J_Mobius_05.0_Salvation/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_05.0_Salvation/dist/game/config/NPC.ini +++ b/L2J_Mobius_05.0_Salvation/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_05.0_Salvation/java/org/l2jmobius/Config.java b/L2J_Mobius_05.0_Salvation/java/org/l2jmobius/Config.java index 6dceba1a20..fd2cd8987b 100644 --- a/L2J_Mobius_05.0_Salvation/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_05.0_Salvation/java/org/l2jmobius/Config.java @@ -623,6 +623,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2125,6 +2126,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_05.0_Salvation/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_05.0_Salvation/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_05.0_Salvation/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_05.0_Salvation/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_05.5_EtinasFate/dist/game/config/NPC.ini b/L2J_Mobius_05.5_EtinasFate/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_05.5_EtinasFate/dist/game/config/NPC.ini +++ b/L2J_Mobius_05.5_EtinasFate/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_05.5_EtinasFate/java/org/l2jmobius/Config.java b/L2J_Mobius_05.5_EtinasFate/java/org/l2jmobius/Config.java index 80682a7d7a..b92cee4157 100644 --- a/L2J_Mobius_05.5_EtinasFate/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_05.5_EtinasFate/java/org/l2jmobius/Config.java @@ -623,6 +623,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2132,6 +2133,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_05.5_EtinasFate/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_05.5_EtinasFate/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_05.5_EtinasFate/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_05.5_EtinasFate/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_06.0_Fafurion/dist/game/config/NPC.ini b/L2J_Mobius_06.0_Fafurion/dist/game/config/NPC.ini index b1281d6f7c..7f5801e67e 100644 --- a/L2J_Mobius_06.0_Fafurion/dist/game/config/NPC.ini +++ b/L2J_Mobius_06.0_Fafurion/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_06.0_Fafurion/java/org/l2jmobius/Config.java b/L2J_Mobius_06.0_Fafurion/java/org/l2jmobius/Config.java index 0434310da7..ec1af79ce9 100644 --- a/L2J_Mobius_06.0_Fafurion/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_06.0_Fafurion/java/org/l2jmobius/Config.java @@ -624,6 +624,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2171,6 +2172,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_06.0_Fafurion/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_06.0_Fafurion/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_06.0_Fafurion/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_06.0_Fafurion/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_07.0_PreludeOfWar/dist/game/config/NPC.ini b/L2J_Mobius_07.0_PreludeOfWar/dist/game/config/NPC.ini index b0d9846524..3de9c5111d 100644 --- a/L2J_Mobius_07.0_PreludeOfWar/dist/game/config/NPC.ini +++ b/L2J_Mobius_07.0_PreludeOfWar/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_07.0_PreludeOfWar/java/org/l2jmobius/Config.java b/L2J_Mobius_07.0_PreludeOfWar/java/org/l2jmobius/Config.java index bc4bbd90cd..7004f1d72d 100644 --- a/L2J_Mobius_07.0_PreludeOfWar/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_07.0_PreludeOfWar/java/org/l2jmobius/Config.java @@ -630,6 +630,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2187,6 +2188,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_07.0_PreludeOfWar/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_07.0_PreludeOfWar/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_07.0_PreludeOfWar/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_07.0_PreludeOfWar/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_08.2_Homunculus/dist/game/config/NPC.ini b/L2J_Mobius_08.2_Homunculus/dist/game/config/NPC.ini index b0d9846524..3de9c5111d 100644 --- a/L2J_Mobius_08.2_Homunculus/dist/game/config/NPC.ini +++ b/L2J_Mobius_08.2_Homunculus/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_08.2_Homunculus/java/org/l2jmobius/Config.java b/L2J_Mobius_08.2_Homunculus/java/org/l2jmobius/Config.java index 8ac79f407d..2092256f24 100644 --- a/L2J_Mobius_08.2_Homunculus/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_08.2_Homunculus/java/org/l2jmobius/Config.java @@ -622,6 +622,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2163,6 +2164,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_08.2_Homunculus/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_08.2_Homunculus/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_08.2_Homunculus/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_08.2_Homunculus/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_09.2_ReturnOfTheQueenAnt/dist/game/config/NPC.ini b/L2J_Mobius_09.2_ReturnOfTheQueenAnt/dist/game/config/NPC.ini index b0d9846524..3de9c5111d 100644 --- a/L2J_Mobius_09.2_ReturnOfTheQueenAnt/dist/game/config/NPC.ini +++ b/L2J_Mobius_09.2_ReturnOfTheQueenAnt/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_09.2_ReturnOfTheQueenAnt/java/org/l2jmobius/Config.java b/L2J_Mobius_09.2_ReturnOfTheQueenAnt/java/org/l2jmobius/Config.java index e0d6f32452..fa1189ea94 100644 --- a/L2J_Mobius_09.2_ReturnOfTheQueenAnt/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_09.2_ReturnOfTheQueenAnt/java/org/l2jmobius/Config.java @@ -622,6 +622,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2199,6 +2200,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_09.2_ReturnOfTheQueenAnt/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_09.2_ReturnOfTheQueenAnt/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_09.2_ReturnOfTheQueenAnt/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_09.2_ReturnOfTheQueenAnt/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_10.1_MasterClass/dist/game/config/NPC.ini b/L2J_Mobius_10.1_MasterClass/dist/game/config/NPC.ini index b0d9846524..3de9c5111d 100644 --- a/L2J_Mobius_10.1_MasterClass/dist/game/config/NPC.ini +++ b/L2J_Mobius_10.1_MasterClass/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_10.1_MasterClass/java/org/l2jmobius/Config.java b/L2J_Mobius_10.1_MasterClass/java/org/l2jmobius/Config.java index e4bca5526a..8888f60dc1 100644 --- a/L2J_Mobius_10.1_MasterClass/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_10.1_MasterClass/java/org/l2jmobius/Config.java @@ -622,6 +622,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2199,6 +2200,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_10.1_MasterClass/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_10.1_MasterClass/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_10.1_MasterClass/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_10.1_MasterClass/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_10.2_MasterClass/dist/game/config/NPC.ini b/L2J_Mobius_10.2_MasterClass/dist/game/config/NPC.ini index b0d9846524..3de9c5111d 100644 --- a/L2J_Mobius_10.2_MasterClass/dist/game/config/NPC.ini +++ b/L2J_Mobius_10.2_MasterClass/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_10.2_MasterClass/java/org/l2jmobius/Config.java b/L2J_Mobius_10.2_MasterClass/java/org/l2jmobius/Config.java index e4bca5526a..8888f60dc1 100644 --- a/L2J_Mobius_10.2_MasterClass/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_10.2_MasterClass/java/org/l2jmobius/Config.java @@ -622,6 +622,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2199,6 +2200,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_10.2_MasterClass/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_10.2_MasterClass/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_10.2_MasterClass/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_10.2_MasterClass/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_C4_ScionsOfDestiny/dist/game/config/General.ini b/L2J_Mobius_C4_ScionsOfDestiny/dist/game/config/General.ini index 496802aeba..0fb7591d7e 100644 --- a/L2J_Mobius_C4_ScionsOfDestiny/dist/game/config/General.ini +++ b/L2J_Mobius_C4_ScionsOfDestiny/dist/game/config/General.ini @@ -605,17 +605,20 @@ MinMonsterAnimation = 5 MaxMonsterAnimation = 60 # Show the level of monsters. -# Default: false +# Default: False ShowNpcLevel = False # Show aggression of monsters. -# Default: false +# Default: False ShowNpcAggression = False # Show clan, alliance crests for territory NPCs. # Default: False ShowNpcClanCrest = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Record the location of the characters in the file before the off / restarting the server? ActivatePositionRecorder = False diff --git a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/Config.java b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/Config.java index 886480123f..d4ac3d84b0 100644 --- a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/Config.java @@ -178,6 +178,7 @@ public class Config public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; public static boolean SHOW_NPC_CLAN_CREST; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static int ZONE_TOWN; public static int DEFAULT_PUNISH; public static int DEFAULT_PUNISH_PARAM; @@ -1486,6 +1487,7 @@ public class Config SHOW_NPC_LEVEL = generalConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = generalConfig.getBoolean("ShowNpcAggression", false); SHOW_NPC_CLAN_CREST = generalConfig.getBoolean("ShowNpcClanCrest", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = generalConfig.getBoolean("AttackablesCampPlayerCorpses", false); FORCE_INVENTORY_UPDATE = generalConfig.getBoolean("ForceInventoryUpdate", false); FORCE_COMPLETE_STATUS_UPDATE = generalConfig.getBoolean("ForceCompletePlayerStatusUpdate", true); CHAR_DATA_STORE_INTERVAL = generalConfig.getInt("CharacterDataStoreInterval", 15) * 60 * 1000; diff --git a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 7050221b16..fd5da2d27d 100644 --- a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -492,7 +492,7 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || (getTarget().isPlayer() && (!getTarget().getActingPlayer().isAlikeDead() || getTarget().getActingPlayer().getAppearance().isInvisible())))) + if (!npc.isWalker() && ((getTarget() == null) || (getTarget().isPlayer() && ((!Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()) || getTarget().getActingPlayer().getAppearance().isInvisible())))) { npc.setWalking(); npc.returnHome(); diff --git a/L2J_Mobius_C6_Interlude/dist/game/config/General.ini b/L2J_Mobius_C6_Interlude/dist/game/config/General.ini index 39d3fc2a2c..be9a858f75 100644 --- a/L2J_Mobius_C6_Interlude/dist/game/config/General.ini +++ b/L2J_Mobius_C6_Interlude/dist/game/config/General.ini @@ -633,17 +633,20 @@ MinMonsterAnimation = 5 MaxMonsterAnimation = 60 # Show the level of monsters. -# Default: false +# Default: False ShowNpcLevel = False # Show aggression of monsters. -# Default: false +# Default: False ShowNpcAggression = False # Show clan, alliance crests for territory NPCs. # Default: False ShowNpcClanCrest = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Record the location of the characters in the file before the off / restarting the server? ActivatePositionRecorder = False diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/Config.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/Config.java index e87a978151..7a275e249a 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/Config.java @@ -195,6 +195,7 @@ public class Config public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; public static boolean SHOW_NPC_CLAN_CREST; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static int ZONE_TOWN; public static int DEFAULT_PUNISH; public static int DEFAULT_PUNISH_PARAM; @@ -1539,6 +1540,7 @@ public class Config SHOW_NPC_LEVEL = generalConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = generalConfig.getBoolean("ShowNpcAggression", false); SHOW_NPC_CLAN_CREST = generalConfig.getBoolean("ShowNpcClanCrest", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = generalConfig.getBoolean("AttackablesCampPlayerCorpses", false); FORCE_INVENTORY_UPDATE = generalConfig.getBoolean("ForceInventoryUpdate", false); FORCE_COMPLETE_STATUS_UPDATE = generalConfig.getBoolean("ForceCompletePlayerStatusUpdate", true); CHAR_DATA_STORE_INTERVAL = generalConfig.getInt("CharacterDataStoreInterval", 15) * 60 * 1000; diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 7050221b16..fd5da2d27d 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -492,7 +492,7 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || (getTarget().isPlayer() && (!getTarget().getActingPlayer().isAlikeDead() || getTarget().getActingPlayer().getAppearance().isInvisible())))) + if (!npc.isWalker() && ((getTarget() == null) || (getTarget().isPlayer() && ((!Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()) || getTarget().getActingPlayer().getAppearance().isInvisible())))) { npc.setWalking(); npc.returnHome(); diff --git a/L2J_Mobius_CT_0_Interlude/dist/game/config/NPC.ini b/L2J_Mobius_CT_0_Interlude/dist/game/config/NPC.ini index edc9bc94b6..7b17c78ace 100644 --- a/L2J_Mobius_CT_0_Interlude/dist/game/config/NPC.ini +++ b/L2J_Mobius_CT_0_Interlude/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_CT_0_Interlude/java/org/l2jmobius/Config.java b/L2J_Mobius_CT_0_Interlude/java/org/l2jmobius/Config.java index ea38b5348c..2389a396ed 100644 --- a/L2J_Mobius_CT_0_Interlude/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_CT_0_Interlude/java/org/l2jmobius/Config.java @@ -695,6 +695,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2122,6 +2123,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_CT_0_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_CT_0_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java index cc97419001..74f94a23ca 100644 --- a/L2J_Mobius_CT_0_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_CT_0_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -615,7 +615,7 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { npc.setWalking(); npc.returnHome(); diff --git a/L2J_Mobius_CT_2.4_Epilogue/dist/game/config/NPC.ini b/L2J_Mobius_CT_2.4_Epilogue/dist/game/config/NPC.ini index 59ca4e0ae4..41d6617583 100644 --- a/L2J_Mobius_CT_2.4_Epilogue/dist/game/config/NPC.ini +++ b/L2J_Mobius_CT_2.4_Epilogue/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_CT_2.4_Epilogue/java/org/l2jmobius/Config.java b/L2J_Mobius_CT_2.4_Epilogue/java/org/l2jmobius/Config.java index 45e9bcf086..f204400cec 100644 --- a/L2J_Mobius_CT_2.4_Epilogue/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_CT_2.4_Epilogue/java/org/l2jmobius/Config.java @@ -720,6 +720,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2212,6 +2213,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_CT_2.4_Epilogue/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_CT_2.4_Epilogue/java/org/l2jmobius/gameserver/ai/AttackableAI.java index cc97419001..74f94a23ca 100644 --- a/L2J_Mobius_CT_2.4_Epilogue/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_CT_2.4_Epilogue/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -615,7 +615,7 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { npc.setWalking(); npc.returnHome(); diff --git a/L2J_Mobius_CT_2.6_HighFive/dist/game/config/NPC.ini b/L2J_Mobius_CT_2.6_HighFive/dist/game/config/NPC.ini index 59ca4e0ae4..41d6617583 100644 --- a/L2J_Mobius_CT_2.6_HighFive/dist/game/config/NPC.ini +++ b/L2J_Mobius_CT_2.6_HighFive/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_CT_2.6_HighFive/java/org/l2jmobius/Config.java b/L2J_Mobius_CT_2.6_HighFive/java/org/l2jmobius/Config.java index e6e9fcfedd..0826d36f37 100644 --- a/L2J_Mobius_CT_2.6_HighFive/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_CT_2.6_HighFive/java/org/l2jmobius/Config.java @@ -725,6 +725,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2217,6 +2218,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_CT_2.6_HighFive/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_CT_2.6_HighFive/java/org/l2jmobius/gameserver/ai/AttackableAI.java index cc97419001..74f94a23ca 100644 --- a/L2J_Mobius_CT_2.6_HighFive/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_CT_2.6_HighFive/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -615,7 +615,7 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { npc.setWalking(); npc.returnHome(); diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/config/NPC.ini b/L2J_Mobius_Classic_2.0_Saviors/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/config/NPC.ini +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/org/l2jmobius/Config.java b/L2J_Mobius_Classic_2.0_Saviors/java/org/l2jmobius/Config.java index d27b0db0c4..62b2635335 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/org/l2jmobius/Config.java @@ -644,6 +644,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2068,6 +2069,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Classic_2.0_Saviors/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Classic_2.1_Zaken/dist/game/config/NPC.ini b/L2J_Mobius_Classic_2.1_Zaken/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Classic_2.1_Zaken/dist/game/config/NPC.ini +++ b/L2J_Mobius_Classic_2.1_Zaken/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Classic_2.1_Zaken/java/org/l2jmobius/Config.java b/L2J_Mobius_Classic_2.1_Zaken/java/org/l2jmobius/Config.java index f9bdf6230b..ec3400d74f 100644 --- a/L2J_Mobius_Classic_2.1_Zaken/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Classic_2.1_Zaken/java/org/l2jmobius/Config.java @@ -644,6 +644,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2072,6 +2073,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Classic_2.1_Zaken/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Classic_2.1_Zaken/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Classic_2.1_Zaken/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Classic_2.1_Zaken/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Classic_2.2_Antharas/dist/game/config/NPC.ini b/L2J_Mobius_Classic_2.2_Antharas/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Classic_2.2_Antharas/dist/game/config/NPC.ini +++ b/L2J_Mobius_Classic_2.2_Antharas/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Classic_2.2_Antharas/java/org/l2jmobius/Config.java b/L2J_Mobius_Classic_2.2_Antharas/java/org/l2jmobius/Config.java index f9bdf6230b..ec3400d74f 100644 --- a/L2J_Mobius_Classic_2.2_Antharas/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Classic_2.2_Antharas/java/org/l2jmobius/Config.java @@ -644,6 +644,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2072,6 +2073,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Classic_2.2_Antharas/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Classic_2.2_Antharas/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Classic_2.2_Antharas/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Classic_2.2_Antharas/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/config/NPC.ini b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/config/NPC.ini +++ b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/java/org/l2jmobius/Config.java b/L2J_Mobius_Classic_2.3_SevenSigns/java/org/l2jmobius/Config.java index f9bdf6230b..ec3400d74f 100644 --- a/L2J_Mobius_Classic_2.3_SevenSigns/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Classic_2.3_SevenSigns/java/org/l2jmobius/Config.java @@ -644,6 +644,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2072,6 +2073,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Classic_2.3_SevenSigns/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Classic_2.3_SevenSigns/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Classic_2.3_SevenSigns/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Classic_2.4_SecretOfEmpire/dist/game/config/NPC.ini b/L2J_Mobius_Classic_2.4_SecretOfEmpire/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Classic_2.4_SecretOfEmpire/dist/game/config/NPC.ini +++ b/L2J_Mobius_Classic_2.4_SecretOfEmpire/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Classic_2.4_SecretOfEmpire/java/org/l2jmobius/Config.java b/L2J_Mobius_Classic_2.4_SecretOfEmpire/java/org/l2jmobius/Config.java index d699075807..60aa5033a6 100644 --- a/L2J_Mobius_Classic_2.4_SecretOfEmpire/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Classic_2.4_SecretOfEmpire/java/org/l2jmobius/Config.java @@ -644,6 +644,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2081,6 +2082,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Classic_2.4_SecretOfEmpire/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Classic_2.4_SecretOfEmpire/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Classic_2.4_SecretOfEmpire/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Classic_2.4_SecretOfEmpire/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Classic_3.0_TheKamael/dist/game/config/NPC.ini b/L2J_Mobius_Classic_3.0_TheKamael/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Classic_3.0_TheKamael/dist/game/config/NPC.ini +++ b/L2J_Mobius_Classic_3.0_TheKamael/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Classic_3.0_TheKamael/java/org/l2jmobius/Config.java b/L2J_Mobius_Classic_3.0_TheKamael/java/org/l2jmobius/Config.java index 3e9e6fdace..9d18099e26 100644 --- a/L2J_Mobius_Classic_3.0_TheKamael/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Classic_3.0_TheKamael/java/org/l2jmobius/Config.java @@ -649,6 +649,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2126,6 +2127,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Classic_3.0_TheKamael/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Classic_3.0_TheKamael/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Classic_3.0_TheKamael/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Classic_3.0_TheKamael/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Classic_Interlude/dist/game/config/NPC.ini b/L2J_Mobius_Classic_Interlude/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Classic_Interlude/dist/game/config/NPC.ini +++ b/L2J_Mobius_Classic_Interlude/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Classic_Interlude/java/org/l2jmobius/Config.java b/L2J_Mobius_Classic_Interlude/java/org/l2jmobius/Config.java index 822cbc813d..5c7827b58c 100644 --- a/L2J_Mobius_Classic_Interlude/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Classic_Interlude/java/org/l2jmobius/Config.java @@ -651,6 +651,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2083,6 +2084,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Classic_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Classic_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 056633c7f6..dc6073c082 100644 --- a/L2J_Mobius_Classic_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Classic_Interlude/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/config/NPC.ini b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/config/NPC.ini +++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/java/org/l2jmobius/Config.java b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/java/org/l2jmobius/Config.java index 6d9b6a7f2e..25c4f90a17 100644 --- a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/java/org/l2jmobius/Config.java @@ -653,6 +653,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2166,6 +2167,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/config/NPC.ini b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/config/NPC.ini +++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Essence_5.2_FrostLord/java/org/l2jmobius/Config.java b/L2J_Mobius_Essence_5.2_FrostLord/java/org/l2jmobius/Config.java index dc0a9ee4cb..3c9ade00f9 100644 --- a/L2J_Mobius_Essence_5.2_FrostLord/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Essence_5.2_FrostLord/java/org/l2jmobius/Config.java @@ -655,6 +655,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2267,6 +2268,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Essence_5.2_FrostLord/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Essence_5.2_FrostLord/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Essence_5.2_FrostLord/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Essence_5.2_FrostLord/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Essence_6.1_BattleChronicle/dist/game/config/NPC.ini b/L2J_Mobius_Essence_6.1_BattleChronicle/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Essence_6.1_BattleChronicle/dist/game/config/NPC.ini +++ b/L2J_Mobius_Essence_6.1_BattleChronicle/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Essence_6.1_BattleChronicle/java/org/l2jmobius/Config.java b/L2J_Mobius_Essence_6.1_BattleChronicle/java/org/l2jmobius/Config.java index a4cba7b8a6..2b43dd504d 100644 --- a/L2J_Mobius_Essence_6.1_BattleChronicle/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Essence_6.1_BattleChronicle/java/org/l2jmobius/Config.java @@ -656,6 +656,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2274,6 +2275,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Essence_6.1_BattleChronicle/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Essence_6.1_BattleChronicle/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Essence_6.1_BattleChronicle/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Essence_6.1_BattleChronicle/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; } diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/config/NPC.ini b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/config/NPC.ini index 36f89eaf10..85abaac399 100644 --- a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/config/NPC.ini +++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/config/NPC.ini @@ -34,6 +34,9 @@ ShowNpcLevel = False # Default: False ShowNpcAggression = False +# Attackables do not leave player corpses. +AttackablesCampPlayerCorpses = False + # Show clan, alliance crests for territory NPCs without quests # Default: False ShowCrestWithoutQuest = False diff --git a/L2J_Mobius_Essence_6.2_Vanguard/java/org/l2jmobius/Config.java b/L2J_Mobius_Essence_6.2_Vanguard/java/org/l2jmobius/Config.java index 01c4e28640..3a1a302db0 100644 --- a/L2J_Mobius_Essence_6.2_Vanguard/java/org/l2jmobius/Config.java +++ b/L2J_Mobius_Essence_6.2_Vanguard/java/org/l2jmobius/Config.java @@ -656,6 +656,7 @@ public class Config public static boolean ALT_GAME_VIEWNPC; public static boolean SHOW_NPC_LEVEL; public static boolean SHOW_NPC_AGGRESSION; + public static boolean ATTACKABLES_CAMP_PLAYER_CORPSES; public static boolean SHOW_CREST_WITHOUT_QUEST; public static boolean ENABLE_RANDOM_ENCHANT_EFFECT; public static int MIN_NPC_LEVEL_DMG_PENALTY; @@ -2274,6 +2275,7 @@ public class Config ALT_GAME_VIEWNPC = npcConfig.getBoolean("AltGameViewNpc", false); SHOW_NPC_LEVEL = npcConfig.getBoolean("ShowNpcLevel", false); SHOW_NPC_AGGRESSION = npcConfig.getBoolean("ShowNpcAggression", false); + ATTACKABLES_CAMP_PLAYER_CORPSES = npcConfig.getBoolean("AttackablesCampPlayerCorpses", false); SHOW_CREST_WITHOUT_QUEST = npcConfig.getBoolean("ShowCrestWithoutQuest", false); ENABLE_RANDOM_ENCHANT_EFFECT = npcConfig.getBoolean("EnableRandomEnchantEffect", false); MIN_NPC_LEVEL_DMG_PENALTY = npcConfig.getInt("MinNPCLevelForDmgPenalty", 78); diff --git a/L2J_Mobius_Essence_6.2_Vanguard/java/org/l2jmobius/gameserver/ai/AttackableAI.java b/L2J_Mobius_Essence_6.2_Vanguard/java/org/l2jmobius/gameserver/ai/AttackableAI.java index 4d4ea353a8..e73e1a5f7a 100644 --- a/L2J_Mobius_Essence_6.2_Vanguard/java/org/l2jmobius/gameserver/ai/AttackableAI.java +++ b/L2J_Mobius_Essence_6.2_Vanguard/java/org/l2jmobius/gameserver/ai/AttackableAI.java @@ -474,8 +474,9 @@ public class AttackableAI extends CreatureAI } // Order this attackable to return to its spawn because there's no target to attack - if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !getTarget().getActingPlayer().isAlikeDead()))) + if (!npc.isWalker() && ((getTarget() == null) || getTarget().isInvisible() || (getTarget().isPlayer() && !Config.ATTACKABLES_CAMP_PLAYER_CORPSES && getTarget().getActingPlayer().isAlikeDead()))) { + npc.setWalking(); npc.returnHome(); return; }