From 5e836a200ae5a735c37c9e77627b96257b2e628d Mon Sep 17 00:00:00 2001 From: MobiusDev <8391001+MobiusDevelopment@users.noreply.github.com> Date: Thu, 3 Aug 2017 18:03:10 +0000 Subject: [PATCH] Minor update for missing html commands. --- .../handlers/admincommandhandlers/AdminGeodata.java | 8 ++++---- .../handlers/admincommandhandlers/AdminGeodata.java | 8 ++++---- .../handlers/admincommandhandlers/AdminGeodata.java | 8 ++++---- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java b/L2J_Mobius_Classic/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java index 789a9bfd7d..25cda9d1a5 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java +++ b/L2J_Mobius_Classic/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java @@ -156,10 +156,10 @@ public class AdminGeodata implements IAdminCommandHandler final List results = new ArrayList<>(); for (L2Object obj : L2World.getInstance().getVisibleObjects()) { - if (obj.isNpc() && !obj.isMonster()) + if (obj.isNpc() && !obj.isMonster() && !results.contains(obj.getId())) { final L2Npc npc = (L2Npc) obj; - if (!results.contains(npc.getId()) && (npc.getLocation().getX() > topLeftX) && (npc.getLocation().getX() < bottomRightX) && (npc.getLocation().getY() > topLeftY) && (npc.getLocation().getY() < bottomRightY) && npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) + if ((npc.getLocation().getX() > topLeftX) && (npc.getLocation().getX() < bottomRightX) && (npc.getLocation().getY() > topLeftY) && (npc.getLocation().getY() < bottomRightY) && npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) { results.add(npc.getId()); } @@ -179,10 +179,10 @@ public class AdminGeodata implements IAdminCommandHandler final List results = new ArrayList<>(); for (L2Object obj : L2World.getInstance().getVisibleObjects()) { - if (obj.isNpc() && !obj.isMonster()) + if (obj.isNpc() && !obj.isMonster() && !results.contains(obj.getId())) { final L2Npc npc = (L2Npc) obj; - if (!results.contains(npc.getId()) && npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) + if (npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) { results.add(npc.getId()); } diff --git a/L2J_Mobius_Helios/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java b/L2J_Mobius_Helios/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java index 789a9bfd7d..25cda9d1a5 100644 --- a/L2J_Mobius_Helios/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java +++ b/L2J_Mobius_Helios/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java @@ -156,10 +156,10 @@ public class AdminGeodata implements IAdminCommandHandler final List results = new ArrayList<>(); for (L2Object obj : L2World.getInstance().getVisibleObjects()) { - if (obj.isNpc() && !obj.isMonster()) + if (obj.isNpc() && !obj.isMonster() && !results.contains(obj.getId())) { final L2Npc npc = (L2Npc) obj; - if (!results.contains(npc.getId()) && (npc.getLocation().getX() > topLeftX) && (npc.getLocation().getX() < bottomRightX) && (npc.getLocation().getY() > topLeftY) && (npc.getLocation().getY() < bottomRightY) && npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) + if ((npc.getLocation().getX() > topLeftX) && (npc.getLocation().getX() < bottomRightX) && (npc.getLocation().getY() > topLeftY) && (npc.getLocation().getY() < bottomRightY) && npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) { results.add(npc.getId()); } @@ -179,10 +179,10 @@ public class AdminGeodata implements IAdminCommandHandler final List results = new ArrayList<>(); for (L2Object obj : L2World.getInstance().getVisibleObjects()) { - if (obj.isNpc() && !obj.isMonster()) + if (obj.isNpc() && !obj.isMonster() && !results.contains(obj.getId())) { final L2Npc npc = (L2Npc) obj; - if (!results.contains(npc.getId()) && npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) + if (npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) { results.add(npc.getId()); } diff --git a/L2J_Mobius_Underground/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java b/L2J_Mobius_Underground/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java index 789a9bfd7d..25cda9d1a5 100644 --- a/L2J_Mobius_Underground/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java +++ b/L2J_Mobius_Underground/dist/game/data/scripts/handlers/admincommandhandlers/AdminGeodata.java @@ -156,10 +156,10 @@ public class AdminGeodata implements IAdminCommandHandler final List results = new ArrayList<>(); for (L2Object obj : L2World.getInstance().getVisibleObjects()) { - if (obj.isNpc() && !obj.isMonster()) + if (obj.isNpc() && !obj.isMonster() && !results.contains(obj.getId())) { final L2Npc npc = (L2Npc) obj; - if (!results.contains(npc.getId()) && (npc.getLocation().getX() > topLeftX) && (npc.getLocation().getX() < bottomRightX) && (npc.getLocation().getY() > topLeftY) && (npc.getLocation().getY() < bottomRightY) && npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) + if ((npc.getLocation().getX() > topLeftX) && (npc.getLocation().getX() < bottomRightX) && (npc.getLocation().getY() > topLeftY) && (npc.getLocation().getY() < bottomRightY) && npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) { results.add(npc.getId()); } @@ -179,10 +179,10 @@ public class AdminGeodata implements IAdminCommandHandler final List results = new ArrayList<>(); for (L2Object obj : L2World.getInstance().getVisibleObjects()) { - if (obj.isNpc() && !obj.isMonster()) + if (obj.isNpc() && !obj.isMonster() && !results.contains(obj.getId())) { final L2Npc npc = (L2Npc) obj; - if (!results.contains(npc.getId()) && npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) + if (npc.isTalkable() && !npc.hasListener(EventType.ON_NPC_FIRST_TALK) && (npc.getHtmlPath(npc.getId(), 0) == "data/html/npcdefault.htm")) { results.add(npc.getId()); }