From bdba87dec2c996b61bbd8c3d73d171cde7acddd7 Mon Sep 17 00:00:00 2001 From: MobiusDev <8391001+MobiusDevelopment@users.noreply.github.com> Date: Fri, 8 Dec 2017 20:54:24 +0000 Subject: [PATCH] Removed admin debug command. --- .../dist/game/config/AdminCommands.xml | 3 - .../data/scripts/handlers/MasterHandler.java | 4 - .../admincommandhandlers/AdminDebug.java | 85 ------------------- .../handlers/effecthandlers/ResistSkill.java | 3 - .../handlers/voicedcommandhandlers/Debug.java | 59 ------------- .../instancemanager/WalkingManager.java | 23 ----- .../l2jmobius/gameserver/model/WalkInfo.java | 2 - .../gameserver/model/actor/L2Character.java | 46 ---------- .../gameserver/model/actor/L2Npc.java | 14 --- .../model/actor/instance/L2PcInstance.java | 1 - .../gameserver/model/entity/Hero.java | 10 --- .../model/items/enchant/EnchantScroll.java | 30 ------- .../model/olympiad/OlympiadManager.java | 8 -- .../gameserver/model/options/Options.java | 12 --- .../gameserver/model/quest/Quest.java | 5 -- .../gameserver/model/skills/Skill.java | 3 - .../gameserver/model/stats/Formulas.java | 67 --------------- .../clientpackets/RequestBypassToServer.java | 4 - .../clientpackets/RequestLinkHtml.java | 5 -- .../dist/game/config/AdminCommands.xml | 3 - .../data/scripts/handlers/MasterHandler.java | 4 - .../admincommandhandlers/AdminDebug.java | 85 ------------------- .../handlers/effecthandlers/ResistSkill.java | 3 - .../handlers/voicedcommandhandlers/Debug.java | 59 ------------- .../instancemanager/WalkingManager.java | 23 ----- .../l2jmobius/gameserver/model/WalkInfo.java | 2 - .../gameserver/model/actor/L2Character.java | 46 ---------- .../gameserver/model/actor/L2Npc.java | 14 --- .../model/actor/instance/L2PcInstance.java | 1 - .../gameserver/model/entity/Hero.java | 10 --- .../model/items/enchant/EnchantScroll.java | 30 ------- .../model/olympiad/OlympiadManager.java | 8 -- .../gameserver/model/options/Options.java | 12 --- .../gameserver/model/quest/Quest.java | 5 -- .../gameserver/model/skills/Skill.java | 3 - .../gameserver/model/stats/Formulas.java | 67 --------------- .../clientpackets/RequestBypassToServer.java | 4 - .../clientpackets/RequestLinkHtml.java | 5 -- .../dist/game/config/AdminCommands.xml | 3 - .../data/scripts/handlers/MasterHandler.java | 4 - .../admincommandhandlers/AdminDebug.java | 85 ------------------- .../handlers/effecthandlers/ResistSkill.java | 3 - .../handlers/voicedcommandhandlers/Debug.java | 59 ------------- .../instancemanager/WalkingManager.java | 23 ----- .../l2jmobius/gameserver/model/WalkInfo.java | 2 - .../gameserver/model/actor/L2Character.java | 46 ---------- .../gameserver/model/actor/L2Npc.java | 14 --- .../model/actor/instance/L2PcInstance.java | 1 - .../gameserver/model/entity/Hero.java | 10 --- .../model/items/enchant/EnchantScroll.java | 30 ------- .../model/olympiad/OlympiadManager.java | 8 -- .../gameserver/model/options/Options.java | 12 --- .../gameserver/model/quest/Quest.java | 5 -- .../gameserver/model/skills/Skill.java | 3 - .../gameserver/model/stats/Formulas.java | 67 --------------- .../clientpackets/RequestBypassToServer.java | 4 - .../clientpackets/RequestLinkHtml.java | 5 -- .../dist/game/config/AdminCommands.xml | 3 - .../data/scripts/handlers/MasterHandler.java | 4 - .../admincommandhandlers/AdminDebug.java | 85 ------------------- .../handlers/effecthandlers/ResistSkill.java | 3 - .../handlers/voicedcommandhandlers/Debug.java | 59 ------------- .../instancemanager/WalkingManager.java | 23 ----- .../l2jmobius/gameserver/model/WalkInfo.java | 2 - .../gameserver/model/actor/L2Character.java | 46 ---------- .../gameserver/model/actor/L2Npc.java | 14 --- .../model/actor/instance/L2PcInstance.java | 1 - .../gameserver/model/entity/Hero.java | 10 --- .../model/items/enchant/EnchantScroll.java | 30 ------- .../model/olympiad/OlympiadManager.java | 8 -- .../gameserver/model/options/Options.java | 12 --- .../gameserver/model/quest/Quest.java | 5 -- .../gameserver/model/skills/Skill.java | 3 - .../gameserver/model/stats/Formulas.java | 67 --------------- .../clientpackets/RequestBypassToServer.java | 4 - .../clientpackets/RequestLinkHtml.java | 5 -- .../dist/game/config/AdminCommands.xml | 3 - .../data/scripts/handlers/MasterHandler.java | 4 - .../admincommandhandlers/AdminDebug.java | 85 ------------------- .../handlers/effecthandlers/ResistSkill.java | 3 - .../handlers/voicedcommandhandlers/Debug.java | 59 ------------- .../instancemanager/WalkingManager.java | 23 ----- .../l2jmobius/gameserver/model/WalkInfo.java | 2 - .../gameserver/model/actor/L2Character.java | 46 ---------- .../gameserver/model/actor/L2Npc.java | 14 --- .../model/actor/instance/L2PcInstance.java | 1 - .../gameserver/model/entity/Hero.java | 10 --- .../model/items/enchant/EnchantScroll.java | 30 ------- .../model/olympiad/OlympiadManager.java | 8 -- .../gameserver/model/options/Options.java | 12 --- .../gameserver/model/quest/Quest.java | 5 -- .../gameserver/model/skills/Skill.java | 3 - .../gameserver/model/stats/Formulas.java | 67 --------------- .../clientpackets/RequestBypassToServer.java | 4 - .../clientpackets/RequestLinkHtml.java | 5 -- 95 files changed, 1920 deletions(-) delete mode 100644 L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java delete mode 100644 L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java delete mode 100644 L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java delete mode 100644 L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java delete mode 100644 L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java delete mode 100644 L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java delete mode 100644 L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java delete mode 100644 L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java delete mode 100644 L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java delete mode 100644 L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/config/AdminCommands.xml b/L2J_Mobius_1.0_Ertheia/dist/game/config/AdminCommands.xml index f9067f1377..14882ea07a 100644 --- a/L2J_Mobius_1.0_Ertheia/dist/game/config/AdminCommands.xml +++ b/L2J_Mobius_1.0_Ertheia/dist/game/config/AdminCommands.xml @@ -95,9 +95,6 @@ - - - diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/MasterHandler.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/MasterHandler.java index ec9218857e..6e38ce1d0c 100644 --- a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/MasterHandler.java +++ b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/MasterHandler.java @@ -68,7 +68,6 @@ import handlers.admincommandhandlers.AdminClan; import handlers.admincommandhandlers.AdminClanHall; import handlers.admincommandhandlers.AdminCreateItem; import handlers.admincommandhandlers.AdminCursedWeapons; -import handlers.admincommandhandlers.AdminDebug; import handlers.admincommandhandlers.AdminDelete; import handlers.admincommandhandlers.AdminDisconnect; import handlers.admincommandhandlers.AdminDoorControl; @@ -329,7 +328,6 @@ import handlers.usercommandhandlers.Unstuck; import handlers.voicedcommandhandlers.Banking; import handlers.voicedcommandhandlers.ChangePassword; import handlers.voicedcommandhandlers.ChatAdmin; -import handlers.voicedcommandhandlers.Debug; import handlers.voicedcommandhandlers.Lang; import handlers.voicedcommandhandlers.Premium; import handlers.voicedcommandhandlers.StatsVCmd; @@ -398,7 +396,6 @@ public class MasterHandler AdminPcCondOverride.class, AdminCreateItem.class, AdminCursedWeapons.class, - AdminDebug.class, AdminDelete.class, AdminDisconnect.class, AdminDoorControl.class, @@ -585,7 +582,6 @@ public class MasterHandler Config.BANKING_SYSTEM_ENABLED ? Banking.class : null, Config.CHAT_ADMIN ? ChatAdmin.class : null, Config.MULTILANG_ENABLE && Config.MULTILANG_VOICED_ALLOW ? Lang.class : null, - Config.DEBUG_VOICE_COMMAND ? Debug.class : null, Config.ALLOW_CHANGE_PASSWORD ? ChangePassword.class : null, Config.PREMIUM_SYSTEM_ENABLED ? Premium.class : null, }, diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java deleted file mode 100644 index e24b2654c0..0000000000 --- a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java +++ /dev/null @@ -1,85 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.admincommandhandlers; - -import com.l2jmobius.gameserver.handler.IAdminCommandHandler; -import com.l2jmobius.gameserver.model.L2Object; -import com.l2jmobius.gameserver.model.L2World; -import com.l2jmobius.gameserver.model.actor.L2Character; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; -import com.l2jmobius.gameserver.network.SystemMessageId; - -public class AdminDebug implements IAdminCommandHandler -{ - private static final String[] ADMIN_COMMANDS = - { - "admin_debug" - }; - - @Override - public final boolean useAdminCommand(String command, L2PcInstance activeChar) - { - final String[] commandSplit = command.split(" "); - if (ADMIN_COMMANDS[0].equalsIgnoreCase(commandSplit[0])) - { - L2Object target; - if (commandSplit.length > 1) - { - target = L2World.getInstance().getPlayer(commandSplit[1].trim()); - if (target == null) - { - activeChar.sendPacket(SystemMessageId.THAT_PLAYER_IS_NOT_ONLINE); - return true; - } - } - else - { - target = activeChar.getTarget(); - } - - if (target instanceof L2Character) - { - setDebug(activeChar, (L2Character) target); - } - else - { - setDebug(activeChar, activeChar); - } - } - return true; - } - - @Override - public final String[] getAdminCommandList() - { - return ADMIN_COMMANDS; - } - - private final void setDebug(L2PcInstance activeChar, L2Character target) - { - if (target.isDebug()) - { - target.setDebug(null); - activeChar.sendMessage("Stop debugging " + target.getName()); - } - else - { - target.setDebug(activeChar); - activeChar.sendMessage("Start debugging " + target.getName()); - } - } -} diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java index 6bfefc9c73..01cafb9d92 100644 --- a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java +++ b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java @@ -59,18 +59,15 @@ public final class ResistSkill extends AbstractEffect for (SkillHolder holder : _skills) { effected.addIgnoreSkillEffects(holder); - effected.sendDebugMessage("Applying invul against " + holder.getSkill()); } } @Override public void onExit(BuffInfo info) { - final L2Character effected = info.getEffected(); for (SkillHolder holder : _skills) { info.getEffected().removeIgnoreSkillEffects(holder); - effected.sendDebugMessage("Removing invul against " + holder.getSkill()); } } } diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java deleted file mode 100644 index 5ead4cc7d9..0000000000 --- a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.voicedcommandhandlers; - -import com.l2jmobius.gameserver.data.xml.impl.AdminData; -import com.l2jmobius.gameserver.handler.IVoicedCommandHandler; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; - -public class Debug implements IVoicedCommandHandler -{ - private static final String[] VOICED_COMMANDS = - { - "debug" - }; - - @Override - public boolean useVoicedCommand(String command, L2PcInstance activeChar, String params) - { - if (!AdminData.getInstance().hasAccess(command, activeChar.getAccessLevel())) - { - return false; - } - - if (VOICED_COMMANDS[0].equalsIgnoreCase(command)) - { - if (activeChar.isDebug()) - { - activeChar.setDebug(null); - activeChar.sendMessage("Debugging disabled."); - } - else - { - activeChar.setDebug(activeChar); - activeChar.sendMessage("Debugging enabled."); - } - } - return true; - } - - @Override - public String[] getVoicedCommandList() - { - return VOICED_COMMANDS; - } -} \ No newline at end of file diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java index b56e5922f7..e9c54b975a 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java @@ -274,12 +274,6 @@ public final class WalkingManager implements IGameXmlReader if ((npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_ACTIVE) || (npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)) { final WalkInfo walk = new WalkInfo(routeName); - - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - L2NpcWalkerNode node = walk.getCurrentNode(); // adjust next waypoint, if NPC spawns at first waypoint @@ -287,18 +281,15 @@ public final class WalkingManager implements IGameXmlReader { walk.calculateNextNode(npc); node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "': spawn point is same with first waypoint, adjusted to next"); } if (!npc.isInsideRadius(node, 3000, true, false)) { final String message = "Route '" + routeName + "': NPC (id=" + npc.getId() + ", x=" + npc.getX() + ", y=" + npc.getY() + ", z=" + npc.getZ() + ") is too far from starting point (node x=" + node.getX() + ", y=" + node.getY() + ", z=" + node.getZ() + ", range=" + npc.calculateDistance(node, true, true) + "), walking will not start"; LOGGER.warning(message); - npc.sendDebugMessage(message); return; } - npc.sendDebugMessage("Starting to move at route '" + routeName + "'"); if (node.runToLocation()) { npc.setRunning(); @@ -314,7 +305,6 @@ public final class WalkingManager implements IGameXmlReader } else { - npc.sendDebugMessage("Failed to start moving along route '" + routeName + "', scheduled"); ThreadPoolManager.schedule(new StartMovingTask(npc, routeName), 60000); } } @@ -332,13 +322,11 @@ public final class WalkingManager implements IGameXmlReader // Prevent call simultaneously from scheduled task and onArrived() or temporarily stop walking for resuming in future if (walk.isBlocked() || walk.isSuspended()) { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (operation is blocked)"); return; } walk.setBlocked(true); final L2NpcWalkerNode node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "', continuing to node " + walk.getCurrentNodeId()); if (node.runToLocation()) { npc.setRunning(); @@ -351,10 +339,6 @@ public final class WalkingManager implements IGameXmlReader walk.setBlocked(false); walk.setStoppedByAttack(false); } - else - { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (wrong AI state - " + npc.getAI().getIntention() + ")"); - } } } } @@ -450,8 +434,6 @@ public final class WalkingManager implements IGameXmlReader final L2NpcWalkerNode node = walk.getRoute().getNodeList().get(walk.getCurrentNodeId()); if (npc.isInsideRadius(node, 10, false, false)) { - npc.sendDebugMessage("Route '" + walk.getRoute().getName() + "', arrived to node " + walk.getCurrentNodeId()); - npc.sendDebugMessage("Done in " + ((System.currentTimeMillis() - walk.getLastAction()) / 1000) + " s"); walk.calculateNextNode(npc); walk.setBlocked(true); // prevents to be ran from walk check task, if there is delay in this node. @@ -464,11 +446,6 @@ public final class WalkingManager implements IGameXmlReader npc.broadcastSay(ChatType.NPC_GENERAL, node.getChatText()); } - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - ThreadPoolManager.schedule(new ArrivedTask(npc, walk), 100 + (node.getDelay() * 1000L)); } } diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/WalkInfo.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/WalkInfo.java index 89a519f7fb..22cfd07cc9 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/WalkInfo.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/WalkInfo.java @@ -77,7 +77,6 @@ public class WalkInfo } _currentNode = newNode; - npc.sendDebugMessage("Route: " + getRoute().getName() + ", next random node is " + _currentNode); } else { @@ -94,7 +93,6 @@ public class WalkInfo { // Notify quest EventDispatcher.getInstance().notifyEventAsync(new OnNpcMoveRouteFinished(npc), npc); - npc.sendDebugMessage("Route: " + getRoute().getName() + ", last node arrived"); if (!getRoute().repeatWalk()) { diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/L2Character.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/L2Character.java index c65da7865f..b678f99e09 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/L2Character.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/L2Character.java @@ -220,8 +220,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe private final byte[] _zones = new byte[ZoneId.getZoneCount()]; protected byte _zoneValidateCounter = 4; - private L2Character _debugger = null; - private final ReentrantLock _teleportLock = new ReentrantLock(); private final Object _attackLock = new Object(); @@ -353,48 +351,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe return _effectList; } - /** - * Verify if this character is under debug. - * @return {@code true} if this character is under debug, {@code false} otherwise - */ - public boolean isDebug() - { - return _debugger != null; - } - - /** - * Sets character instance, to which debug packets will be send. - * @param debugger the character debugging this character - */ - public void setDebug(L2Character debugger) - { - _debugger = debugger; - } - - /** - * Send debug packet. - * @param pkt - */ - public void sendDebugPacket(IClientOutgoingPacket pkt) - { - if (_debugger != null) - { - _debugger.sendPacket(pkt); - } - } - - /** - * Send debug text string - * @param msg - */ - public void sendDebugMessage(String msg) - { - if (_debugger != null) - { - _debugger.sendMessage(msg); - } - } - /** * @return character inventory, default null, overridden in L2Playable types and in L2NPcInstance */ @@ -1712,8 +1668,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe @Override public boolean deleteMe() { - setDebug(null); - if (hasAI()) { getAI().stopAITask(); diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/L2Npc.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/L2Npc.java index 7a72301465..e11872575b 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/L2Npc.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/L2Npc.java @@ -728,10 +728,6 @@ public class L2Npc extends L2Character { html = html.replaceAll("%objectId%", String.valueOf(getObjectId())); player.sendPacket(new NpcHtmlMessage(getObjectId(), html)); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML : data/html/" + type + "/" + getId() + "-pk.htm"); - } player.sendPacket(ActionFailed.STATIC_PACKET); return true; } @@ -857,11 +853,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } @@ -879,11 +870,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java index 465ee0f1d4..85accd252a 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java @@ -10757,7 +10757,6 @@ public final class L2PcInstance extends L2Playable abortAttack(); abortCast(); stopMove(null); - setDebug(null); } catch (Exception e) { diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/entity/Hero.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/entity/Hero.java index d0c33ad058..d62385e1b8 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/entity/Hero.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/entity/Hero.java @@ -520,11 +520,6 @@ public class Hero } activeChar.sendPacket(DiaryReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herodiary.htm"); - } } } } @@ -617,11 +612,6 @@ public class Hero FightReply.replace("%loos%", String.valueOf(_loss)); activeChar.sendPacket(FightReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herohistory.htm"); - } } } } diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java index 7b3bdb6b14..06040c0806 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java @@ -26,8 +26,6 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; import com.l2jmobius.gameserver.model.items.type.EtcItemType; import com.l2jmobius.gameserver.model.items.type.ItemType; -import com.l2jmobius.gameserver.network.Debug; -import com.l2jmobius.gameserver.util.Util; /** * @author UnAfraid @@ -183,34 +181,6 @@ public final class EnchantScroll extends AbstractEnchantItem final double random = 100 * Rnd.nextDouble(); boolean success = (random < finalChance) || player.tryLuck(); - if (player.isDebug()) - { - final EnchantItemGroup group = EnchantItemGroupsData.getInstance().getItemGroup(enchantItem.getItem(), _scrollGroupId); - final StatsSet set = new StatsSet(); - if (isBlessed()) - { - set.set("isBlessed", isBlessed()); - } - if (isSafe()) - { - set.set("isSafe", isSafe()); - } - set.set("chance", Util.formatDouble(chance, "#.##")); - if (bonusRate > 0) - { - set.set("bonusRate", Util.formatDouble(bonusRate, "#.##")); - } - if (supportBonusRate > 0) - { - set.set("supportBonusRate", Util.formatDouble(supportBonusRate, "#.##")); - } - set.set("finalChance", Util.formatDouble(finalChance, "#.##")); - set.set("random", Util.formatDouble(random, "#.##")); - set.set("success", success); - set.set("item group", group.getName()); - set.set("scroll group", _scrollGroupId); - Debug.sendItemDebug(player, enchantItem, set); - } return success ? EnchantResultType.SUCCESS : EnchantResultType.FAILURE; } } diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java index b1a3037b05..bebb98e19b 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java @@ -209,10 +209,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } @@ -240,10 +236,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/options/Options.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/options/Options.java index 660c49c76e..475f2a94d8 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/options/Options.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/options/Options.java @@ -159,7 +159,6 @@ public class Options public void apply(L2PcInstance player) { - player.sendDebugMessage("Activating option id: " + _id); if (hasEffects()) { final BuffInfo info = new BuffInfo(player, player, null, true, null, this); @@ -171,7 +170,6 @@ public class Options { effect.instant(info.getEffector(), info.getEffected(), info.getSkill(), info.getItem()); } - player.sendDebugMessage("Appling instant effect: " + effect.getClass().getSimpleName()); } else { @@ -182,8 +180,6 @@ public class Options { info.addEffect(effect); } - - player.sendDebugMessage("Appling continious effect: " + effect.getClass().getSimpleName()); } } if (!info.getEffects().isEmpty()) @@ -196,7 +192,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -204,7 +199,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -212,7 +206,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.addTriggerSkill(holder); - player.sendDebugMessage("Adding trigger skill: " + holder); } } @@ -222,14 +215,12 @@ public class Options public void remove(L2PcInstance player) { - player.sendDebugMessage("Deactivating option id: " + _id); if (hasEffects()) { for (BuffInfo info : player.getEffectList().getOptions()) { if (info.getOption() == this) { - player.sendDebugMessage("Removing effects: " + info.getEffects()); player.getEffectList().remove(info, false, true, true); } } @@ -239,7 +230,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { player.removeSkill(holder.getSkill(), false, false); - player.sendDebugMessage("Removing active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -247,7 +237,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { player.removeSkill(holder.getSkill(), false, true); - player.sendDebugMessage("Removing passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -255,7 +244,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.removeTriggerSkill(holder); - player.sendDebugMessage("Removing trigger skill: " + holder); } } diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/quest/Quest.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/quest/Quest.java index db12f1f2ee..1f7b6d4547 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/quest/Quest.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/quest/Quest.java @@ -2770,11 +2770,6 @@ public class Quest extends AbstractScript implements IIdentifiable player.sendPacket(npcReply); } player.sendPacket(ActionFailed.STATIC_PACKET); - - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + (filename.startsWith("data/") ? filename : "data/scripts/" + getPath().toLowerCase() + "/" + getName() + "/" + filename)); - } } return content; diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/skills/Skill.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/skills/Skill.java index 7505001c60..164957d7a5 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/skills/Skill.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/skills/Skill.java @@ -1159,7 +1159,6 @@ public final class Skill implements IIdentifiable { return null; } - activeChar.sendDebugMessage("-> " + this + "\n TT: " + getTargetType() + "\n AS: " + getAffectScope() + "\n AO: " + getAffectObject()); final IAffectScopeHandler handler = AffectScopeHandler.getInstance().getHandler(getAffectScope()); if (handler != null) { @@ -1338,7 +1337,6 @@ public final class Skill implements IIdentifiable if (effected.isIgnoringSkillEffects(getId(), getLevel())) { - effected.sendDebugMessage("Skill " + toString() + " has been ignored (ignoring skill effects)"); return; } @@ -1376,7 +1374,6 @@ public final class Skill implements IIdentifiable { final BasicPropertyResist resist = effected.getBasicPropertyResist(getBasicProperty()); resist.increaseResistLevel(); - effected.sendDebugMessage(toString() + " has increased your " + getBasicProperty() + " debuff resistance to " + resist.getResistLevel() + " level for " + resist.getRemainTime().toMillis() + " milliseconds."); } } diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/stats/Formulas.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/stats/Formulas.java index 2442dac54d..d5f04ac1d3 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/stats/Formulas.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/model/stats/Formulas.java @@ -29,7 +29,6 @@ import com.l2jmobius.gameserver.enums.BasicProperty; import com.l2jmobius.gameserver.enums.DispelSlotType; import com.l2jmobius.gameserver.enums.Position; import com.l2jmobius.gameserver.enums.ShotType; -import com.l2jmobius.gameserver.model.StatsSet; import com.l2jmobius.gameserver.model.actor.L2Character; import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.actor.instance.L2SiegeFlagInstance; @@ -46,7 +45,6 @@ import com.l2jmobius.gameserver.model.skills.AbnormalType; import com.l2jmobius.gameserver.model.skills.BuffInfo; import com.l2jmobius.gameserver.model.skills.Skill; import com.l2jmobius.gameserver.model.skills.SkillCaster; -import com.l2jmobius.gameserver.network.Debug; import com.l2jmobius.gameserver.network.SystemMessageId; import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; @@ -124,26 +122,6 @@ public final class Formulas final double baseMod = ((77 * (((power + attacker.getPAtk()) * 0.666 * ssmod * cdMult) + (isPosition * (power + (attacker.getPAtk() * ssmod)) * randomMod) + (6 * cdPatk))) / defence); final double damage = baseMod * weaponTraitMod * generalTraitMod * attributeMod * randomMod * pvpPveMod; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("skillPower", power); - set.set("ssboost", ssmod); - set.set("isPosition", isPosition); - set.set("baseMod", baseMod); - set.set("criticalMod", criticalMod); - set.set("criticalVulnMod", criticalVulnMod); - set.set("criticalAddMod", criticalAddMod); - set.set("criticalAddVuln", criticalAddVuln); - set.set("weaponTraitMod", weaponTraitMod); - set.set("generalTraitMod", generalTraitMod); - set.set("attributeMod", attributeMod); - set.set("weaponMod", randomMod); - set.set("penaltyMod", pvpPveMod); - set.set("damage", (int) damage); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return damage; } @@ -706,18 +684,6 @@ public final class Formulas final double rate = baseMod * elementMod * traitMod * buffDebuffMod; final double finalRate = traitMod > 0 ? CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist : 0; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseMod); - set.set("elementMod", elementMod); - set.set("traitMod", traitMod); - set.set("buffDebuffMod", buffDebuffMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - if ((finalRate <= Rnd.get(100)) && (target != attacker)) { final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_RESISTED_YOUR_S2); @@ -786,19 +752,6 @@ public final class Formulas // Check the Rate Limits. final double finalRate = CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist; - if (attacker.getOwner().isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseRate); - set.set("resMod", resMod); - set.set("statMod", statMod); - set.set("elementMod", elementMod); - set.set("lvlBonusMod", lvlBonusMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker.getOwner(), target, skill, set); - } - return Rnd.get(100) < finalRate; } @@ -824,17 +777,6 @@ public final class Formulas final double resModifier = target.getStat().getValue(Stats.MAGIC_SUCCESS_RES, 1); final int rate = 100 - Math.round((float) (lvlModifier * targetModifier * resModifier)); - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("lvlDifference", lvlDifference); - set.set("lvlModifier", lvlModifier); - set.set("resModifier", resModifier); - set.set("targetModifier", targetModifier); - set.set("rate", rate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return (Rnd.get(100) < rate); } @@ -1102,15 +1044,6 @@ public final class Formulas { // Resist Modifier. final int cancelMagicLvl = skill.getMagicLevel(); - if (activeChar.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", rate); - set.set("magicLevel", cancelMagicLvl); - set.set("resMod", target.getStat().getValue(Stats.RESIST_DISPEL_BUFF, 1)); - set.set("rate", rate); - Debug.sendSkillDebug(activeChar, target, skill, set); - } // Prevent initialization. final List buffs = target.getEffectList().getBuffs(); diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java index 3f95262f76..bb06f1bfcc 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java @@ -164,10 +164,6 @@ public final class RequestBypassToServer implements IClientIncomingPacket ((L2Npc) object).onBypassFeedback(activeChar, _command.substring(endOfId + 1)); } } - else - { - activeChar.sendDebugMessage("ObjectId of npc bypass is not digit: " + id); - } activeChar.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java index 4f25b1bbf4..d8a598fa60 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java @@ -76,10 +76,5 @@ public final class RequestLinkHtml implements IClientIncomingPacket final NpcHtmlMessage msg = new NpcHtmlMessage(htmlObjectId); msg.setFile(actor.getHtmlPrefix(), filename); actor.sendPacket(msg); - - if (actor.isGM() && actor.isDebug()) - { - actor.sendMessage("HTML: " + filename); - } } } diff --git a/L2J_Mobius_2.5_Underground/dist/game/config/AdminCommands.xml b/L2J_Mobius_2.5_Underground/dist/game/config/AdminCommands.xml index f9067f1377..14882ea07a 100644 --- a/L2J_Mobius_2.5_Underground/dist/game/config/AdminCommands.xml +++ b/L2J_Mobius_2.5_Underground/dist/game/config/AdminCommands.xml @@ -95,9 +95,6 @@ - - - diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/MasterHandler.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/MasterHandler.java index fd223930e4..ad8653530d 100644 --- a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/MasterHandler.java +++ b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/MasterHandler.java @@ -68,7 +68,6 @@ import handlers.admincommandhandlers.AdminClan; import handlers.admincommandhandlers.AdminClanHall; import handlers.admincommandhandlers.AdminCreateItem; import handlers.admincommandhandlers.AdminCursedWeapons; -import handlers.admincommandhandlers.AdminDebug; import handlers.admincommandhandlers.AdminDelete; import handlers.admincommandhandlers.AdminDisconnect; import handlers.admincommandhandlers.AdminDoorControl; @@ -330,7 +329,6 @@ import handlers.usercommandhandlers.Unstuck; import handlers.voicedcommandhandlers.Banking; import handlers.voicedcommandhandlers.ChangePassword; import handlers.voicedcommandhandlers.ChatAdmin; -import handlers.voicedcommandhandlers.Debug; import handlers.voicedcommandhandlers.Lang; import handlers.voicedcommandhandlers.Premium; import handlers.voicedcommandhandlers.StatsVCmd; @@ -399,7 +397,6 @@ public class MasterHandler AdminPcCondOverride.class, AdminCreateItem.class, AdminCursedWeapons.class, - AdminDebug.class, AdminDelete.class, AdminDisconnect.class, AdminDoorControl.class, @@ -587,7 +584,6 @@ public class MasterHandler Config.BANKING_SYSTEM_ENABLED ? Banking.class : null, Config.CHAT_ADMIN ? ChatAdmin.class : null, Config.MULTILANG_ENABLE && Config.MULTILANG_VOICED_ALLOW ? Lang.class : null, - Config.DEBUG_VOICE_COMMAND ? Debug.class : null, Config.ALLOW_CHANGE_PASSWORD ? ChangePassword.class : null, Config.PREMIUM_SYSTEM_ENABLED ? Premium.class : null, }, diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java deleted file mode 100644 index e24b2654c0..0000000000 --- a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java +++ /dev/null @@ -1,85 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.admincommandhandlers; - -import com.l2jmobius.gameserver.handler.IAdminCommandHandler; -import com.l2jmobius.gameserver.model.L2Object; -import com.l2jmobius.gameserver.model.L2World; -import com.l2jmobius.gameserver.model.actor.L2Character; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; -import com.l2jmobius.gameserver.network.SystemMessageId; - -public class AdminDebug implements IAdminCommandHandler -{ - private static final String[] ADMIN_COMMANDS = - { - "admin_debug" - }; - - @Override - public final boolean useAdminCommand(String command, L2PcInstance activeChar) - { - final String[] commandSplit = command.split(" "); - if (ADMIN_COMMANDS[0].equalsIgnoreCase(commandSplit[0])) - { - L2Object target; - if (commandSplit.length > 1) - { - target = L2World.getInstance().getPlayer(commandSplit[1].trim()); - if (target == null) - { - activeChar.sendPacket(SystemMessageId.THAT_PLAYER_IS_NOT_ONLINE); - return true; - } - } - else - { - target = activeChar.getTarget(); - } - - if (target instanceof L2Character) - { - setDebug(activeChar, (L2Character) target); - } - else - { - setDebug(activeChar, activeChar); - } - } - return true; - } - - @Override - public final String[] getAdminCommandList() - { - return ADMIN_COMMANDS; - } - - private final void setDebug(L2PcInstance activeChar, L2Character target) - { - if (target.isDebug()) - { - target.setDebug(null); - activeChar.sendMessage("Stop debugging " + target.getName()); - } - else - { - target.setDebug(activeChar); - activeChar.sendMessage("Start debugging " + target.getName()); - } - } -} diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java index 6bfefc9c73..01cafb9d92 100644 --- a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java +++ b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java @@ -59,18 +59,15 @@ public final class ResistSkill extends AbstractEffect for (SkillHolder holder : _skills) { effected.addIgnoreSkillEffects(holder); - effected.sendDebugMessage("Applying invul against " + holder.getSkill()); } } @Override public void onExit(BuffInfo info) { - final L2Character effected = info.getEffected(); for (SkillHolder holder : _skills) { info.getEffected().removeIgnoreSkillEffects(holder); - effected.sendDebugMessage("Removing invul against " + holder.getSkill()); } } } diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java deleted file mode 100644 index 5ead4cc7d9..0000000000 --- a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.voicedcommandhandlers; - -import com.l2jmobius.gameserver.data.xml.impl.AdminData; -import com.l2jmobius.gameserver.handler.IVoicedCommandHandler; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; - -public class Debug implements IVoicedCommandHandler -{ - private static final String[] VOICED_COMMANDS = - { - "debug" - }; - - @Override - public boolean useVoicedCommand(String command, L2PcInstance activeChar, String params) - { - if (!AdminData.getInstance().hasAccess(command, activeChar.getAccessLevel())) - { - return false; - } - - if (VOICED_COMMANDS[0].equalsIgnoreCase(command)) - { - if (activeChar.isDebug()) - { - activeChar.setDebug(null); - activeChar.sendMessage("Debugging disabled."); - } - else - { - activeChar.setDebug(activeChar); - activeChar.sendMessage("Debugging enabled."); - } - } - return true; - } - - @Override - public String[] getVoicedCommandList() - { - return VOICED_COMMANDS; - } -} \ No newline at end of file diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java index b56e5922f7..e9c54b975a 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java @@ -274,12 +274,6 @@ public final class WalkingManager implements IGameXmlReader if ((npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_ACTIVE) || (npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)) { final WalkInfo walk = new WalkInfo(routeName); - - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - L2NpcWalkerNode node = walk.getCurrentNode(); // adjust next waypoint, if NPC spawns at first waypoint @@ -287,18 +281,15 @@ public final class WalkingManager implements IGameXmlReader { walk.calculateNextNode(npc); node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "': spawn point is same with first waypoint, adjusted to next"); } if (!npc.isInsideRadius(node, 3000, true, false)) { final String message = "Route '" + routeName + "': NPC (id=" + npc.getId() + ", x=" + npc.getX() + ", y=" + npc.getY() + ", z=" + npc.getZ() + ") is too far from starting point (node x=" + node.getX() + ", y=" + node.getY() + ", z=" + node.getZ() + ", range=" + npc.calculateDistance(node, true, true) + "), walking will not start"; LOGGER.warning(message); - npc.sendDebugMessage(message); return; } - npc.sendDebugMessage("Starting to move at route '" + routeName + "'"); if (node.runToLocation()) { npc.setRunning(); @@ -314,7 +305,6 @@ public final class WalkingManager implements IGameXmlReader } else { - npc.sendDebugMessage("Failed to start moving along route '" + routeName + "', scheduled"); ThreadPoolManager.schedule(new StartMovingTask(npc, routeName), 60000); } } @@ -332,13 +322,11 @@ public final class WalkingManager implements IGameXmlReader // Prevent call simultaneously from scheduled task and onArrived() or temporarily stop walking for resuming in future if (walk.isBlocked() || walk.isSuspended()) { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (operation is blocked)"); return; } walk.setBlocked(true); final L2NpcWalkerNode node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "', continuing to node " + walk.getCurrentNodeId()); if (node.runToLocation()) { npc.setRunning(); @@ -351,10 +339,6 @@ public final class WalkingManager implements IGameXmlReader walk.setBlocked(false); walk.setStoppedByAttack(false); } - else - { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (wrong AI state - " + npc.getAI().getIntention() + ")"); - } } } } @@ -450,8 +434,6 @@ public final class WalkingManager implements IGameXmlReader final L2NpcWalkerNode node = walk.getRoute().getNodeList().get(walk.getCurrentNodeId()); if (npc.isInsideRadius(node, 10, false, false)) { - npc.sendDebugMessage("Route '" + walk.getRoute().getName() + "', arrived to node " + walk.getCurrentNodeId()); - npc.sendDebugMessage("Done in " + ((System.currentTimeMillis() - walk.getLastAction()) / 1000) + " s"); walk.calculateNextNode(npc); walk.setBlocked(true); // prevents to be ran from walk check task, if there is delay in this node. @@ -464,11 +446,6 @@ public final class WalkingManager implements IGameXmlReader npc.broadcastSay(ChatType.NPC_GENERAL, node.getChatText()); } - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - ThreadPoolManager.schedule(new ArrivedTask(npc, walk), 100 + (node.getDelay() * 1000L)); } } diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/WalkInfo.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/WalkInfo.java index 89a519f7fb..22cfd07cc9 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/WalkInfo.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/WalkInfo.java @@ -77,7 +77,6 @@ public class WalkInfo } _currentNode = newNode; - npc.sendDebugMessage("Route: " + getRoute().getName() + ", next random node is " + _currentNode); } else { @@ -94,7 +93,6 @@ public class WalkInfo { // Notify quest EventDispatcher.getInstance().notifyEventAsync(new OnNpcMoveRouteFinished(npc), npc); - npc.sendDebugMessage("Route: " + getRoute().getName() + ", last node arrived"); if (!getRoute().repeatWalk()) { diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/L2Character.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/L2Character.java index c65da7865f..b678f99e09 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/L2Character.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/L2Character.java @@ -220,8 +220,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe private final byte[] _zones = new byte[ZoneId.getZoneCount()]; protected byte _zoneValidateCounter = 4; - private L2Character _debugger = null; - private final ReentrantLock _teleportLock = new ReentrantLock(); private final Object _attackLock = new Object(); @@ -353,48 +351,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe return _effectList; } - /** - * Verify if this character is under debug. - * @return {@code true} if this character is under debug, {@code false} otherwise - */ - public boolean isDebug() - { - return _debugger != null; - } - - /** - * Sets character instance, to which debug packets will be send. - * @param debugger the character debugging this character - */ - public void setDebug(L2Character debugger) - { - _debugger = debugger; - } - - /** - * Send debug packet. - * @param pkt - */ - public void sendDebugPacket(IClientOutgoingPacket pkt) - { - if (_debugger != null) - { - _debugger.sendPacket(pkt); - } - } - - /** - * Send debug text string - * @param msg - */ - public void sendDebugMessage(String msg) - { - if (_debugger != null) - { - _debugger.sendMessage(msg); - } - } - /** * @return character inventory, default null, overridden in L2Playable types and in L2NPcInstance */ @@ -1712,8 +1668,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe @Override public boolean deleteMe() { - setDebug(null); - if (hasAI()) { getAI().stopAITask(); diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/L2Npc.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/L2Npc.java index f93be6c22b..c1216af688 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/L2Npc.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/L2Npc.java @@ -728,10 +728,6 @@ public class L2Npc extends L2Character { html = html.replaceAll("%objectId%", String.valueOf(getObjectId())); player.sendPacket(new NpcHtmlMessage(getObjectId(), html)); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML : data/html/" + type + "/" + getId() + "-pk.htm"); - } player.sendPacket(ActionFailed.STATIC_PACKET); return true; } @@ -857,11 +853,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } @@ -879,11 +870,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java index 3504209a9a..3b60595841 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java @@ -10758,7 +10758,6 @@ public final class L2PcInstance extends L2Playable abortAttack(); abortCast(); stopMove(null); - setDebug(null); } catch (Exception e) { diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/entity/Hero.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/entity/Hero.java index d0c33ad058..d62385e1b8 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/entity/Hero.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/entity/Hero.java @@ -520,11 +520,6 @@ public class Hero } activeChar.sendPacket(DiaryReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herodiary.htm"); - } } } } @@ -617,11 +612,6 @@ public class Hero FightReply.replace("%loos%", String.valueOf(_loss)); activeChar.sendPacket(FightReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herohistory.htm"); - } } } } diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java index 7b3bdb6b14..06040c0806 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java @@ -26,8 +26,6 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; import com.l2jmobius.gameserver.model.items.type.EtcItemType; import com.l2jmobius.gameserver.model.items.type.ItemType; -import com.l2jmobius.gameserver.network.Debug; -import com.l2jmobius.gameserver.util.Util; /** * @author UnAfraid @@ -183,34 +181,6 @@ public final class EnchantScroll extends AbstractEnchantItem final double random = 100 * Rnd.nextDouble(); boolean success = (random < finalChance) || player.tryLuck(); - if (player.isDebug()) - { - final EnchantItemGroup group = EnchantItemGroupsData.getInstance().getItemGroup(enchantItem.getItem(), _scrollGroupId); - final StatsSet set = new StatsSet(); - if (isBlessed()) - { - set.set("isBlessed", isBlessed()); - } - if (isSafe()) - { - set.set("isSafe", isSafe()); - } - set.set("chance", Util.formatDouble(chance, "#.##")); - if (bonusRate > 0) - { - set.set("bonusRate", Util.formatDouble(bonusRate, "#.##")); - } - if (supportBonusRate > 0) - { - set.set("supportBonusRate", Util.formatDouble(supportBonusRate, "#.##")); - } - set.set("finalChance", Util.formatDouble(finalChance, "#.##")); - set.set("random", Util.formatDouble(random, "#.##")); - set.set("success", success); - set.set("item group", group.getName()); - set.set("scroll group", _scrollGroupId); - Debug.sendItemDebug(player, enchantItem, set); - } return success ? EnchantResultType.SUCCESS : EnchantResultType.FAILURE; } } diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java index 84a104a610..dee9fd482b 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java @@ -209,10 +209,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } @@ -240,10 +236,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/options/Options.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/options/Options.java index 660c49c76e..475f2a94d8 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/options/Options.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/options/Options.java @@ -159,7 +159,6 @@ public class Options public void apply(L2PcInstance player) { - player.sendDebugMessage("Activating option id: " + _id); if (hasEffects()) { final BuffInfo info = new BuffInfo(player, player, null, true, null, this); @@ -171,7 +170,6 @@ public class Options { effect.instant(info.getEffector(), info.getEffected(), info.getSkill(), info.getItem()); } - player.sendDebugMessage("Appling instant effect: " + effect.getClass().getSimpleName()); } else { @@ -182,8 +180,6 @@ public class Options { info.addEffect(effect); } - - player.sendDebugMessage("Appling continious effect: " + effect.getClass().getSimpleName()); } } if (!info.getEffects().isEmpty()) @@ -196,7 +192,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -204,7 +199,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -212,7 +206,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.addTriggerSkill(holder); - player.sendDebugMessage("Adding trigger skill: " + holder); } } @@ -222,14 +215,12 @@ public class Options public void remove(L2PcInstance player) { - player.sendDebugMessage("Deactivating option id: " + _id); if (hasEffects()) { for (BuffInfo info : player.getEffectList().getOptions()) { if (info.getOption() == this) { - player.sendDebugMessage("Removing effects: " + info.getEffects()); player.getEffectList().remove(info, false, true, true); } } @@ -239,7 +230,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { player.removeSkill(holder.getSkill(), false, false); - player.sendDebugMessage("Removing active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -247,7 +237,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { player.removeSkill(holder.getSkill(), false, true); - player.sendDebugMessage("Removing passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -255,7 +244,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.removeTriggerSkill(holder); - player.sendDebugMessage("Removing trigger skill: " + holder); } } diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/quest/Quest.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/quest/Quest.java index 27b1975a95..e4c151a8ec 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/quest/Quest.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/quest/Quest.java @@ -2772,11 +2772,6 @@ public class Quest extends AbstractScript implements IIdentifiable player.sendPacket(npcReply); } player.sendPacket(ActionFailed.STATIC_PACKET); - - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + (filename.startsWith("data/") ? filename : "data/scripts/" + getPath().toLowerCase() + "/" + getName() + "/" + filename)); - } } return content; diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/skills/Skill.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/skills/Skill.java index 7505001c60..164957d7a5 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/skills/Skill.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/skills/Skill.java @@ -1159,7 +1159,6 @@ public final class Skill implements IIdentifiable { return null; } - activeChar.sendDebugMessage("-> " + this + "\n TT: " + getTargetType() + "\n AS: " + getAffectScope() + "\n AO: " + getAffectObject()); final IAffectScopeHandler handler = AffectScopeHandler.getInstance().getHandler(getAffectScope()); if (handler != null) { @@ -1338,7 +1337,6 @@ public final class Skill implements IIdentifiable if (effected.isIgnoringSkillEffects(getId(), getLevel())) { - effected.sendDebugMessage("Skill " + toString() + " has been ignored (ignoring skill effects)"); return; } @@ -1376,7 +1374,6 @@ public final class Skill implements IIdentifiable { final BasicPropertyResist resist = effected.getBasicPropertyResist(getBasicProperty()); resist.increaseResistLevel(); - effected.sendDebugMessage(toString() + " has increased your " + getBasicProperty() + " debuff resistance to " + resist.getResistLevel() + " level for " + resist.getRemainTime().toMillis() + " milliseconds."); } } diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/stats/Formulas.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/stats/Formulas.java index 2442dac54d..d5f04ac1d3 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/stats/Formulas.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/model/stats/Formulas.java @@ -29,7 +29,6 @@ import com.l2jmobius.gameserver.enums.BasicProperty; import com.l2jmobius.gameserver.enums.DispelSlotType; import com.l2jmobius.gameserver.enums.Position; import com.l2jmobius.gameserver.enums.ShotType; -import com.l2jmobius.gameserver.model.StatsSet; import com.l2jmobius.gameserver.model.actor.L2Character; import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.actor.instance.L2SiegeFlagInstance; @@ -46,7 +45,6 @@ import com.l2jmobius.gameserver.model.skills.AbnormalType; import com.l2jmobius.gameserver.model.skills.BuffInfo; import com.l2jmobius.gameserver.model.skills.Skill; import com.l2jmobius.gameserver.model.skills.SkillCaster; -import com.l2jmobius.gameserver.network.Debug; import com.l2jmobius.gameserver.network.SystemMessageId; import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; @@ -124,26 +122,6 @@ public final class Formulas final double baseMod = ((77 * (((power + attacker.getPAtk()) * 0.666 * ssmod * cdMult) + (isPosition * (power + (attacker.getPAtk() * ssmod)) * randomMod) + (6 * cdPatk))) / defence); final double damage = baseMod * weaponTraitMod * generalTraitMod * attributeMod * randomMod * pvpPveMod; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("skillPower", power); - set.set("ssboost", ssmod); - set.set("isPosition", isPosition); - set.set("baseMod", baseMod); - set.set("criticalMod", criticalMod); - set.set("criticalVulnMod", criticalVulnMod); - set.set("criticalAddMod", criticalAddMod); - set.set("criticalAddVuln", criticalAddVuln); - set.set("weaponTraitMod", weaponTraitMod); - set.set("generalTraitMod", generalTraitMod); - set.set("attributeMod", attributeMod); - set.set("weaponMod", randomMod); - set.set("penaltyMod", pvpPveMod); - set.set("damage", (int) damage); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return damage; } @@ -706,18 +684,6 @@ public final class Formulas final double rate = baseMod * elementMod * traitMod * buffDebuffMod; final double finalRate = traitMod > 0 ? CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist : 0; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseMod); - set.set("elementMod", elementMod); - set.set("traitMod", traitMod); - set.set("buffDebuffMod", buffDebuffMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - if ((finalRate <= Rnd.get(100)) && (target != attacker)) { final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_RESISTED_YOUR_S2); @@ -786,19 +752,6 @@ public final class Formulas // Check the Rate Limits. final double finalRate = CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist; - if (attacker.getOwner().isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseRate); - set.set("resMod", resMod); - set.set("statMod", statMod); - set.set("elementMod", elementMod); - set.set("lvlBonusMod", lvlBonusMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker.getOwner(), target, skill, set); - } - return Rnd.get(100) < finalRate; } @@ -824,17 +777,6 @@ public final class Formulas final double resModifier = target.getStat().getValue(Stats.MAGIC_SUCCESS_RES, 1); final int rate = 100 - Math.round((float) (lvlModifier * targetModifier * resModifier)); - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("lvlDifference", lvlDifference); - set.set("lvlModifier", lvlModifier); - set.set("resModifier", resModifier); - set.set("targetModifier", targetModifier); - set.set("rate", rate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return (Rnd.get(100) < rate); } @@ -1102,15 +1044,6 @@ public final class Formulas { // Resist Modifier. final int cancelMagicLvl = skill.getMagicLevel(); - if (activeChar.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", rate); - set.set("magicLevel", cancelMagicLvl); - set.set("resMod", target.getStat().getValue(Stats.RESIST_DISPEL_BUFF, 1)); - set.set("rate", rate); - Debug.sendSkillDebug(activeChar, target, skill, set); - } // Prevent initialization. final List buffs = target.getEffectList().getBuffs(); diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java index 3f95262f76..bb06f1bfcc 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java @@ -164,10 +164,6 @@ public final class RequestBypassToServer implements IClientIncomingPacket ((L2Npc) object).onBypassFeedback(activeChar, _command.substring(endOfId + 1)); } } - else - { - activeChar.sendDebugMessage("ObjectId of npc bypass is not digit: " + id); - } activeChar.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java index 4f25b1bbf4..d8a598fa60 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java @@ -76,10 +76,5 @@ public final class RequestLinkHtml implements IClientIncomingPacket final NpcHtmlMessage msg = new NpcHtmlMessage(htmlObjectId); msg.setFile(actor.getHtmlPrefix(), filename); actor.sendPacket(msg); - - if (actor.isGM() && actor.isDebug()) - { - actor.sendMessage("HTML: " + filename); - } } } diff --git a/L2J_Mobius_3.0_Helios/dist/game/config/AdminCommands.xml b/L2J_Mobius_3.0_Helios/dist/game/config/AdminCommands.xml index f9067f1377..14882ea07a 100644 --- a/L2J_Mobius_3.0_Helios/dist/game/config/AdminCommands.xml +++ b/L2J_Mobius_3.0_Helios/dist/game/config/AdminCommands.xml @@ -95,9 +95,6 @@ - - - diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/MasterHandler.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/MasterHandler.java index 3228e5fe09..f407232e2e 100644 --- a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/MasterHandler.java +++ b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/MasterHandler.java @@ -68,7 +68,6 @@ import handlers.admincommandhandlers.AdminClan; import handlers.admincommandhandlers.AdminClanHall; import handlers.admincommandhandlers.AdminCreateItem; import handlers.admincommandhandlers.AdminCursedWeapons; -import handlers.admincommandhandlers.AdminDebug; import handlers.admincommandhandlers.AdminDelete; import handlers.admincommandhandlers.AdminDisconnect; import handlers.admincommandhandlers.AdminDoorControl; @@ -331,7 +330,6 @@ import handlers.usercommandhandlers.Unstuck; import handlers.voicedcommandhandlers.Banking; import handlers.voicedcommandhandlers.ChangePassword; import handlers.voicedcommandhandlers.ChatAdmin; -import handlers.voicedcommandhandlers.Debug; import handlers.voicedcommandhandlers.Lang; import handlers.voicedcommandhandlers.Premium; import handlers.voicedcommandhandlers.StatsVCmd; @@ -400,7 +398,6 @@ public class MasterHandler AdminPcCondOverride.class, AdminCreateItem.class, AdminCursedWeapons.class, - AdminDebug.class, AdminDelete.class, AdminDisconnect.class, AdminDoorControl.class, @@ -589,7 +586,6 @@ public class MasterHandler Config.BANKING_SYSTEM_ENABLED ? Banking.class : null, Config.CHAT_ADMIN ? ChatAdmin.class : null, Config.MULTILANG_ENABLE && Config.MULTILANG_VOICED_ALLOW ? Lang.class : null, - Config.DEBUG_VOICE_COMMAND ? Debug.class : null, Config.ALLOW_CHANGE_PASSWORD ? ChangePassword.class : null, Config.PREMIUM_SYSTEM_ENABLED ? Premium.class : null, }, diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java deleted file mode 100644 index e24b2654c0..0000000000 --- a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java +++ /dev/null @@ -1,85 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.admincommandhandlers; - -import com.l2jmobius.gameserver.handler.IAdminCommandHandler; -import com.l2jmobius.gameserver.model.L2Object; -import com.l2jmobius.gameserver.model.L2World; -import com.l2jmobius.gameserver.model.actor.L2Character; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; -import com.l2jmobius.gameserver.network.SystemMessageId; - -public class AdminDebug implements IAdminCommandHandler -{ - private static final String[] ADMIN_COMMANDS = - { - "admin_debug" - }; - - @Override - public final boolean useAdminCommand(String command, L2PcInstance activeChar) - { - final String[] commandSplit = command.split(" "); - if (ADMIN_COMMANDS[0].equalsIgnoreCase(commandSplit[0])) - { - L2Object target; - if (commandSplit.length > 1) - { - target = L2World.getInstance().getPlayer(commandSplit[1].trim()); - if (target == null) - { - activeChar.sendPacket(SystemMessageId.THAT_PLAYER_IS_NOT_ONLINE); - return true; - } - } - else - { - target = activeChar.getTarget(); - } - - if (target instanceof L2Character) - { - setDebug(activeChar, (L2Character) target); - } - else - { - setDebug(activeChar, activeChar); - } - } - return true; - } - - @Override - public final String[] getAdminCommandList() - { - return ADMIN_COMMANDS; - } - - private final void setDebug(L2PcInstance activeChar, L2Character target) - { - if (target.isDebug()) - { - target.setDebug(null); - activeChar.sendMessage("Stop debugging " + target.getName()); - } - else - { - target.setDebug(activeChar); - activeChar.sendMessage("Start debugging " + target.getName()); - } - } -} diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java index 6bfefc9c73..01cafb9d92 100644 --- a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java +++ b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java @@ -59,18 +59,15 @@ public final class ResistSkill extends AbstractEffect for (SkillHolder holder : _skills) { effected.addIgnoreSkillEffects(holder); - effected.sendDebugMessage("Applying invul against " + holder.getSkill()); } } @Override public void onExit(BuffInfo info) { - final L2Character effected = info.getEffected(); for (SkillHolder holder : _skills) { info.getEffected().removeIgnoreSkillEffects(holder); - effected.sendDebugMessage("Removing invul against " + holder.getSkill()); } } } diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java deleted file mode 100644 index 5ead4cc7d9..0000000000 --- a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.voicedcommandhandlers; - -import com.l2jmobius.gameserver.data.xml.impl.AdminData; -import com.l2jmobius.gameserver.handler.IVoicedCommandHandler; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; - -public class Debug implements IVoicedCommandHandler -{ - private static final String[] VOICED_COMMANDS = - { - "debug" - }; - - @Override - public boolean useVoicedCommand(String command, L2PcInstance activeChar, String params) - { - if (!AdminData.getInstance().hasAccess(command, activeChar.getAccessLevel())) - { - return false; - } - - if (VOICED_COMMANDS[0].equalsIgnoreCase(command)) - { - if (activeChar.isDebug()) - { - activeChar.setDebug(null); - activeChar.sendMessage("Debugging disabled."); - } - else - { - activeChar.setDebug(activeChar); - activeChar.sendMessage("Debugging enabled."); - } - } - return true; - } - - @Override - public String[] getVoicedCommandList() - { - return VOICED_COMMANDS; - } -} \ No newline at end of file diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java index b56e5922f7..e9c54b975a 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java @@ -274,12 +274,6 @@ public final class WalkingManager implements IGameXmlReader if ((npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_ACTIVE) || (npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)) { final WalkInfo walk = new WalkInfo(routeName); - - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - L2NpcWalkerNode node = walk.getCurrentNode(); // adjust next waypoint, if NPC spawns at first waypoint @@ -287,18 +281,15 @@ public final class WalkingManager implements IGameXmlReader { walk.calculateNextNode(npc); node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "': spawn point is same with first waypoint, adjusted to next"); } if (!npc.isInsideRadius(node, 3000, true, false)) { final String message = "Route '" + routeName + "': NPC (id=" + npc.getId() + ", x=" + npc.getX() + ", y=" + npc.getY() + ", z=" + npc.getZ() + ") is too far from starting point (node x=" + node.getX() + ", y=" + node.getY() + ", z=" + node.getZ() + ", range=" + npc.calculateDistance(node, true, true) + "), walking will not start"; LOGGER.warning(message); - npc.sendDebugMessage(message); return; } - npc.sendDebugMessage("Starting to move at route '" + routeName + "'"); if (node.runToLocation()) { npc.setRunning(); @@ -314,7 +305,6 @@ public final class WalkingManager implements IGameXmlReader } else { - npc.sendDebugMessage("Failed to start moving along route '" + routeName + "', scheduled"); ThreadPoolManager.schedule(new StartMovingTask(npc, routeName), 60000); } } @@ -332,13 +322,11 @@ public final class WalkingManager implements IGameXmlReader // Prevent call simultaneously from scheduled task and onArrived() or temporarily stop walking for resuming in future if (walk.isBlocked() || walk.isSuspended()) { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (operation is blocked)"); return; } walk.setBlocked(true); final L2NpcWalkerNode node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "', continuing to node " + walk.getCurrentNodeId()); if (node.runToLocation()) { npc.setRunning(); @@ -351,10 +339,6 @@ public final class WalkingManager implements IGameXmlReader walk.setBlocked(false); walk.setStoppedByAttack(false); } - else - { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (wrong AI state - " + npc.getAI().getIntention() + ")"); - } } } } @@ -450,8 +434,6 @@ public final class WalkingManager implements IGameXmlReader final L2NpcWalkerNode node = walk.getRoute().getNodeList().get(walk.getCurrentNodeId()); if (npc.isInsideRadius(node, 10, false, false)) { - npc.sendDebugMessage("Route '" + walk.getRoute().getName() + "', arrived to node " + walk.getCurrentNodeId()); - npc.sendDebugMessage("Done in " + ((System.currentTimeMillis() - walk.getLastAction()) / 1000) + " s"); walk.calculateNextNode(npc); walk.setBlocked(true); // prevents to be ran from walk check task, if there is delay in this node. @@ -464,11 +446,6 @@ public final class WalkingManager implements IGameXmlReader npc.broadcastSay(ChatType.NPC_GENERAL, node.getChatText()); } - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - ThreadPoolManager.schedule(new ArrivedTask(npc, walk), 100 + (node.getDelay() * 1000L)); } } diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/WalkInfo.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/WalkInfo.java index 89a519f7fb..22cfd07cc9 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/WalkInfo.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/WalkInfo.java @@ -77,7 +77,6 @@ public class WalkInfo } _currentNode = newNode; - npc.sendDebugMessage("Route: " + getRoute().getName() + ", next random node is " + _currentNode); } else { @@ -94,7 +93,6 @@ public class WalkInfo { // Notify quest EventDispatcher.getInstance().notifyEventAsync(new OnNpcMoveRouteFinished(npc), npc); - npc.sendDebugMessage("Route: " + getRoute().getName() + ", last node arrived"); if (!getRoute().repeatWalk()) { diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/L2Character.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/L2Character.java index c65da7865f..b678f99e09 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/L2Character.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/L2Character.java @@ -220,8 +220,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe private final byte[] _zones = new byte[ZoneId.getZoneCount()]; protected byte _zoneValidateCounter = 4; - private L2Character _debugger = null; - private final ReentrantLock _teleportLock = new ReentrantLock(); private final Object _attackLock = new Object(); @@ -353,48 +351,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe return _effectList; } - /** - * Verify if this character is under debug. - * @return {@code true} if this character is under debug, {@code false} otherwise - */ - public boolean isDebug() - { - return _debugger != null; - } - - /** - * Sets character instance, to which debug packets will be send. - * @param debugger the character debugging this character - */ - public void setDebug(L2Character debugger) - { - _debugger = debugger; - } - - /** - * Send debug packet. - * @param pkt - */ - public void sendDebugPacket(IClientOutgoingPacket pkt) - { - if (_debugger != null) - { - _debugger.sendPacket(pkt); - } - } - - /** - * Send debug text string - * @param msg - */ - public void sendDebugMessage(String msg) - { - if (_debugger != null) - { - _debugger.sendMessage(msg); - } - } - /** * @return character inventory, default null, overridden in L2Playable types and in L2NPcInstance */ @@ -1712,8 +1668,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe @Override public boolean deleteMe() { - setDebug(null); - if (hasAI()) { getAI().stopAITask(); diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/L2Npc.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/L2Npc.java index f93be6c22b..c1216af688 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/L2Npc.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/L2Npc.java @@ -728,10 +728,6 @@ public class L2Npc extends L2Character { html = html.replaceAll("%objectId%", String.valueOf(getObjectId())); player.sendPacket(new NpcHtmlMessage(getObjectId(), html)); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML : data/html/" + type + "/" + getId() + "-pk.htm"); - } player.sendPacket(ActionFailed.STATIC_PACKET); return true; } @@ -857,11 +853,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } @@ -879,11 +870,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java index 17f81fc40d..706ba94033 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java @@ -10768,7 +10768,6 @@ public final class L2PcInstance extends L2Playable abortAttack(); abortCast(); stopMove(null); - setDebug(null); } catch (Exception e) { diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/entity/Hero.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/entity/Hero.java index d0c33ad058..d62385e1b8 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/entity/Hero.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/entity/Hero.java @@ -520,11 +520,6 @@ public class Hero } activeChar.sendPacket(DiaryReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herodiary.htm"); - } } } } @@ -617,11 +612,6 @@ public class Hero FightReply.replace("%loos%", String.valueOf(_loss)); activeChar.sendPacket(FightReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herohistory.htm"); - } } } } diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java index 7b3bdb6b14..06040c0806 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java @@ -26,8 +26,6 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; import com.l2jmobius.gameserver.model.items.type.EtcItemType; import com.l2jmobius.gameserver.model.items.type.ItemType; -import com.l2jmobius.gameserver.network.Debug; -import com.l2jmobius.gameserver.util.Util; /** * @author UnAfraid @@ -183,34 +181,6 @@ public final class EnchantScroll extends AbstractEnchantItem final double random = 100 * Rnd.nextDouble(); boolean success = (random < finalChance) || player.tryLuck(); - if (player.isDebug()) - { - final EnchantItemGroup group = EnchantItemGroupsData.getInstance().getItemGroup(enchantItem.getItem(), _scrollGroupId); - final StatsSet set = new StatsSet(); - if (isBlessed()) - { - set.set("isBlessed", isBlessed()); - } - if (isSafe()) - { - set.set("isSafe", isSafe()); - } - set.set("chance", Util.formatDouble(chance, "#.##")); - if (bonusRate > 0) - { - set.set("bonusRate", Util.formatDouble(bonusRate, "#.##")); - } - if (supportBonusRate > 0) - { - set.set("supportBonusRate", Util.formatDouble(supportBonusRate, "#.##")); - } - set.set("finalChance", Util.formatDouble(finalChance, "#.##")); - set.set("random", Util.formatDouble(random, "#.##")); - set.set("success", success); - set.set("item group", group.getName()); - set.set("scroll group", _scrollGroupId); - Debug.sendItemDebug(player, enchantItem, set); - } return success ? EnchantResultType.SUCCESS : EnchantResultType.FAILURE; } } diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java index 84a104a610..dee9fd482b 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java @@ -209,10 +209,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } @@ -240,10 +236,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/options/Options.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/options/Options.java index 660c49c76e..475f2a94d8 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/options/Options.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/options/Options.java @@ -159,7 +159,6 @@ public class Options public void apply(L2PcInstance player) { - player.sendDebugMessage("Activating option id: " + _id); if (hasEffects()) { final BuffInfo info = new BuffInfo(player, player, null, true, null, this); @@ -171,7 +170,6 @@ public class Options { effect.instant(info.getEffector(), info.getEffected(), info.getSkill(), info.getItem()); } - player.sendDebugMessage("Appling instant effect: " + effect.getClass().getSimpleName()); } else { @@ -182,8 +180,6 @@ public class Options { info.addEffect(effect); } - - player.sendDebugMessage("Appling continious effect: " + effect.getClass().getSimpleName()); } } if (!info.getEffects().isEmpty()) @@ -196,7 +192,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -204,7 +199,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -212,7 +206,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.addTriggerSkill(holder); - player.sendDebugMessage("Adding trigger skill: " + holder); } } @@ -222,14 +215,12 @@ public class Options public void remove(L2PcInstance player) { - player.sendDebugMessage("Deactivating option id: " + _id); if (hasEffects()) { for (BuffInfo info : player.getEffectList().getOptions()) { if (info.getOption() == this) { - player.sendDebugMessage("Removing effects: " + info.getEffects()); player.getEffectList().remove(info, false, true, true); } } @@ -239,7 +230,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { player.removeSkill(holder.getSkill(), false, false); - player.sendDebugMessage("Removing active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -247,7 +237,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { player.removeSkill(holder.getSkill(), false, true); - player.sendDebugMessage("Removing passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -255,7 +244,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.removeTriggerSkill(holder); - player.sendDebugMessage("Removing trigger skill: " + holder); } } diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/quest/Quest.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/quest/Quest.java index 144704b1d0..622abfbe7f 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/quest/Quest.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/quest/Quest.java @@ -2773,11 +2773,6 @@ public class Quest extends AbstractScript implements IIdentifiable player.sendPacket(npcReply); } player.sendPacket(ActionFailed.STATIC_PACKET); - - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + (filename.startsWith("data/") ? filename : "data/scripts/" + getPath().toLowerCase() + "/" + getName() + "/" + filename)); - } } return content; diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/skills/Skill.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/skills/Skill.java index 7505001c60..164957d7a5 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/skills/Skill.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/skills/Skill.java @@ -1159,7 +1159,6 @@ public final class Skill implements IIdentifiable { return null; } - activeChar.sendDebugMessage("-> " + this + "\n TT: " + getTargetType() + "\n AS: " + getAffectScope() + "\n AO: " + getAffectObject()); final IAffectScopeHandler handler = AffectScopeHandler.getInstance().getHandler(getAffectScope()); if (handler != null) { @@ -1338,7 +1337,6 @@ public final class Skill implements IIdentifiable if (effected.isIgnoringSkillEffects(getId(), getLevel())) { - effected.sendDebugMessage("Skill " + toString() + " has been ignored (ignoring skill effects)"); return; } @@ -1376,7 +1374,6 @@ public final class Skill implements IIdentifiable { final BasicPropertyResist resist = effected.getBasicPropertyResist(getBasicProperty()); resist.increaseResistLevel(); - effected.sendDebugMessage(toString() + " has increased your " + getBasicProperty() + " debuff resistance to " + resist.getResistLevel() + " level for " + resist.getRemainTime().toMillis() + " milliseconds."); } } diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/stats/Formulas.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/stats/Formulas.java index 2442dac54d..d5f04ac1d3 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/stats/Formulas.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/model/stats/Formulas.java @@ -29,7 +29,6 @@ import com.l2jmobius.gameserver.enums.BasicProperty; import com.l2jmobius.gameserver.enums.DispelSlotType; import com.l2jmobius.gameserver.enums.Position; import com.l2jmobius.gameserver.enums.ShotType; -import com.l2jmobius.gameserver.model.StatsSet; import com.l2jmobius.gameserver.model.actor.L2Character; import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.actor.instance.L2SiegeFlagInstance; @@ -46,7 +45,6 @@ import com.l2jmobius.gameserver.model.skills.AbnormalType; import com.l2jmobius.gameserver.model.skills.BuffInfo; import com.l2jmobius.gameserver.model.skills.Skill; import com.l2jmobius.gameserver.model.skills.SkillCaster; -import com.l2jmobius.gameserver.network.Debug; import com.l2jmobius.gameserver.network.SystemMessageId; import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; @@ -124,26 +122,6 @@ public final class Formulas final double baseMod = ((77 * (((power + attacker.getPAtk()) * 0.666 * ssmod * cdMult) + (isPosition * (power + (attacker.getPAtk() * ssmod)) * randomMod) + (6 * cdPatk))) / defence); final double damage = baseMod * weaponTraitMod * generalTraitMod * attributeMod * randomMod * pvpPveMod; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("skillPower", power); - set.set("ssboost", ssmod); - set.set("isPosition", isPosition); - set.set("baseMod", baseMod); - set.set("criticalMod", criticalMod); - set.set("criticalVulnMod", criticalVulnMod); - set.set("criticalAddMod", criticalAddMod); - set.set("criticalAddVuln", criticalAddVuln); - set.set("weaponTraitMod", weaponTraitMod); - set.set("generalTraitMod", generalTraitMod); - set.set("attributeMod", attributeMod); - set.set("weaponMod", randomMod); - set.set("penaltyMod", pvpPveMod); - set.set("damage", (int) damage); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return damage; } @@ -706,18 +684,6 @@ public final class Formulas final double rate = baseMod * elementMod * traitMod * buffDebuffMod; final double finalRate = traitMod > 0 ? CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist : 0; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseMod); - set.set("elementMod", elementMod); - set.set("traitMod", traitMod); - set.set("buffDebuffMod", buffDebuffMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - if ((finalRate <= Rnd.get(100)) && (target != attacker)) { final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_RESISTED_YOUR_S2); @@ -786,19 +752,6 @@ public final class Formulas // Check the Rate Limits. final double finalRate = CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist; - if (attacker.getOwner().isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseRate); - set.set("resMod", resMod); - set.set("statMod", statMod); - set.set("elementMod", elementMod); - set.set("lvlBonusMod", lvlBonusMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker.getOwner(), target, skill, set); - } - return Rnd.get(100) < finalRate; } @@ -824,17 +777,6 @@ public final class Formulas final double resModifier = target.getStat().getValue(Stats.MAGIC_SUCCESS_RES, 1); final int rate = 100 - Math.round((float) (lvlModifier * targetModifier * resModifier)); - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("lvlDifference", lvlDifference); - set.set("lvlModifier", lvlModifier); - set.set("resModifier", resModifier); - set.set("targetModifier", targetModifier); - set.set("rate", rate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return (Rnd.get(100) < rate); } @@ -1102,15 +1044,6 @@ public final class Formulas { // Resist Modifier. final int cancelMagicLvl = skill.getMagicLevel(); - if (activeChar.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", rate); - set.set("magicLevel", cancelMagicLvl); - set.set("resMod", target.getStat().getValue(Stats.RESIST_DISPEL_BUFF, 1)); - set.set("rate", rate); - Debug.sendSkillDebug(activeChar, target, skill, set); - } // Prevent initialization. final List buffs = target.getEffectList().getBuffs(); diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java index 3f95262f76..bb06f1bfcc 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java @@ -164,10 +164,6 @@ public final class RequestBypassToServer implements IClientIncomingPacket ((L2Npc) object).onBypassFeedback(activeChar, _command.substring(endOfId + 1)); } } - else - { - activeChar.sendDebugMessage("ObjectId of npc bypass is not digit: " + id); - } activeChar.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java index 4f25b1bbf4..d8a598fa60 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java @@ -76,10 +76,5 @@ public final class RequestLinkHtml implements IClientIncomingPacket final NpcHtmlMessage msg = new NpcHtmlMessage(htmlObjectId); msg.setFile(actor.getHtmlPrefix(), filename); actor.sendPacket(msg); - - if (actor.isGM() && actor.isDebug()) - { - actor.sendMessage("HTML: " + filename); - } } } diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/config/AdminCommands.xml b/L2J_Mobius_4.0_GrandCrusade/dist/game/config/AdminCommands.xml index f9067f1377..14882ea07a 100644 --- a/L2J_Mobius_4.0_GrandCrusade/dist/game/config/AdminCommands.xml +++ b/L2J_Mobius_4.0_GrandCrusade/dist/game/config/AdminCommands.xml @@ -95,9 +95,6 @@ - - - diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/MasterHandler.java b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/MasterHandler.java index 3228e5fe09..f407232e2e 100644 --- a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/MasterHandler.java +++ b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/MasterHandler.java @@ -68,7 +68,6 @@ import handlers.admincommandhandlers.AdminClan; import handlers.admincommandhandlers.AdminClanHall; import handlers.admincommandhandlers.AdminCreateItem; import handlers.admincommandhandlers.AdminCursedWeapons; -import handlers.admincommandhandlers.AdminDebug; import handlers.admincommandhandlers.AdminDelete; import handlers.admincommandhandlers.AdminDisconnect; import handlers.admincommandhandlers.AdminDoorControl; @@ -331,7 +330,6 @@ import handlers.usercommandhandlers.Unstuck; import handlers.voicedcommandhandlers.Banking; import handlers.voicedcommandhandlers.ChangePassword; import handlers.voicedcommandhandlers.ChatAdmin; -import handlers.voicedcommandhandlers.Debug; import handlers.voicedcommandhandlers.Lang; import handlers.voicedcommandhandlers.Premium; import handlers.voicedcommandhandlers.StatsVCmd; @@ -400,7 +398,6 @@ public class MasterHandler AdminPcCondOverride.class, AdminCreateItem.class, AdminCursedWeapons.class, - AdminDebug.class, AdminDelete.class, AdminDisconnect.class, AdminDoorControl.class, @@ -589,7 +586,6 @@ public class MasterHandler Config.BANKING_SYSTEM_ENABLED ? Banking.class : null, Config.CHAT_ADMIN ? ChatAdmin.class : null, Config.MULTILANG_ENABLE && Config.MULTILANG_VOICED_ALLOW ? Lang.class : null, - Config.DEBUG_VOICE_COMMAND ? Debug.class : null, Config.ALLOW_CHANGE_PASSWORD ? ChangePassword.class : null, Config.PREMIUM_SYSTEM_ENABLED ? Premium.class : null, }, diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java deleted file mode 100644 index e24b2654c0..0000000000 --- a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java +++ /dev/null @@ -1,85 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.admincommandhandlers; - -import com.l2jmobius.gameserver.handler.IAdminCommandHandler; -import com.l2jmobius.gameserver.model.L2Object; -import com.l2jmobius.gameserver.model.L2World; -import com.l2jmobius.gameserver.model.actor.L2Character; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; -import com.l2jmobius.gameserver.network.SystemMessageId; - -public class AdminDebug implements IAdminCommandHandler -{ - private static final String[] ADMIN_COMMANDS = - { - "admin_debug" - }; - - @Override - public final boolean useAdminCommand(String command, L2PcInstance activeChar) - { - final String[] commandSplit = command.split(" "); - if (ADMIN_COMMANDS[0].equalsIgnoreCase(commandSplit[0])) - { - L2Object target; - if (commandSplit.length > 1) - { - target = L2World.getInstance().getPlayer(commandSplit[1].trim()); - if (target == null) - { - activeChar.sendPacket(SystemMessageId.THAT_PLAYER_IS_NOT_ONLINE); - return true; - } - } - else - { - target = activeChar.getTarget(); - } - - if (target instanceof L2Character) - { - setDebug(activeChar, (L2Character) target); - } - else - { - setDebug(activeChar, activeChar); - } - } - return true; - } - - @Override - public final String[] getAdminCommandList() - { - return ADMIN_COMMANDS; - } - - private final void setDebug(L2PcInstance activeChar, L2Character target) - { - if (target.isDebug()) - { - target.setDebug(null); - activeChar.sendMessage("Stop debugging " + target.getName()); - } - else - { - target.setDebug(activeChar); - activeChar.sendMessage("Start debugging " + target.getName()); - } - } -} diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java index 6bfefc9c73..01cafb9d92 100644 --- a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java +++ b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java @@ -59,18 +59,15 @@ public final class ResistSkill extends AbstractEffect for (SkillHolder holder : _skills) { effected.addIgnoreSkillEffects(holder); - effected.sendDebugMessage("Applying invul against " + holder.getSkill()); } } @Override public void onExit(BuffInfo info) { - final L2Character effected = info.getEffected(); for (SkillHolder holder : _skills) { info.getEffected().removeIgnoreSkillEffects(holder); - effected.sendDebugMessage("Removing invul against " + holder.getSkill()); } } } diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java deleted file mode 100644 index 5ead4cc7d9..0000000000 --- a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.voicedcommandhandlers; - -import com.l2jmobius.gameserver.data.xml.impl.AdminData; -import com.l2jmobius.gameserver.handler.IVoicedCommandHandler; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; - -public class Debug implements IVoicedCommandHandler -{ - private static final String[] VOICED_COMMANDS = - { - "debug" - }; - - @Override - public boolean useVoicedCommand(String command, L2PcInstance activeChar, String params) - { - if (!AdminData.getInstance().hasAccess(command, activeChar.getAccessLevel())) - { - return false; - } - - if (VOICED_COMMANDS[0].equalsIgnoreCase(command)) - { - if (activeChar.isDebug()) - { - activeChar.setDebug(null); - activeChar.sendMessage("Debugging disabled."); - } - else - { - activeChar.setDebug(activeChar); - activeChar.sendMessage("Debugging enabled."); - } - } - return true; - } - - @Override - public String[] getVoicedCommandList() - { - return VOICED_COMMANDS; - } -} \ No newline at end of file diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java index b56e5922f7..e9c54b975a 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java @@ -274,12 +274,6 @@ public final class WalkingManager implements IGameXmlReader if ((npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_ACTIVE) || (npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)) { final WalkInfo walk = new WalkInfo(routeName); - - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - L2NpcWalkerNode node = walk.getCurrentNode(); // adjust next waypoint, if NPC spawns at first waypoint @@ -287,18 +281,15 @@ public final class WalkingManager implements IGameXmlReader { walk.calculateNextNode(npc); node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "': spawn point is same with first waypoint, adjusted to next"); } if (!npc.isInsideRadius(node, 3000, true, false)) { final String message = "Route '" + routeName + "': NPC (id=" + npc.getId() + ", x=" + npc.getX() + ", y=" + npc.getY() + ", z=" + npc.getZ() + ") is too far from starting point (node x=" + node.getX() + ", y=" + node.getY() + ", z=" + node.getZ() + ", range=" + npc.calculateDistance(node, true, true) + "), walking will not start"; LOGGER.warning(message); - npc.sendDebugMessage(message); return; } - npc.sendDebugMessage("Starting to move at route '" + routeName + "'"); if (node.runToLocation()) { npc.setRunning(); @@ -314,7 +305,6 @@ public final class WalkingManager implements IGameXmlReader } else { - npc.sendDebugMessage("Failed to start moving along route '" + routeName + "', scheduled"); ThreadPoolManager.schedule(new StartMovingTask(npc, routeName), 60000); } } @@ -332,13 +322,11 @@ public final class WalkingManager implements IGameXmlReader // Prevent call simultaneously from scheduled task and onArrived() or temporarily stop walking for resuming in future if (walk.isBlocked() || walk.isSuspended()) { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (operation is blocked)"); return; } walk.setBlocked(true); final L2NpcWalkerNode node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "', continuing to node " + walk.getCurrentNodeId()); if (node.runToLocation()) { npc.setRunning(); @@ -351,10 +339,6 @@ public final class WalkingManager implements IGameXmlReader walk.setBlocked(false); walk.setStoppedByAttack(false); } - else - { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (wrong AI state - " + npc.getAI().getIntention() + ")"); - } } } } @@ -450,8 +434,6 @@ public final class WalkingManager implements IGameXmlReader final L2NpcWalkerNode node = walk.getRoute().getNodeList().get(walk.getCurrentNodeId()); if (npc.isInsideRadius(node, 10, false, false)) { - npc.sendDebugMessage("Route '" + walk.getRoute().getName() + "', arrived to node " + walk.getCurrentNodeId()); - npc.sendDebugMessage("Done in " + ((System.currentTimeMillis() - walk.getLastAction()) / 1000) + " s"); walk.calculateNextNode(npc); walk.setBlocked(true); // prevents to be ran from walk check task, if there is delay in this node. @@ -464,11 +446,6 @@ public final class WalkingManager implements IGameXmlReader npc.broadcastSay(ChatType.NPC_GENERAL, node.getChatText()); } - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - ThreadPoolManager.schedule(new ArrivedTask(npc, walk), 100 + (node.getDelay() * 1000L)); } } diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/WalkInfo.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/WalkInfo.java index 89a519f7fb..22cfd07cc9 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/WalkInfo.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/WalkInfo.java @@ -77,7 +77,6 @@ public class WalkInfo } _currentNode = newNode; - npc.sendDebugMessage("Route: " + getRoute().getName() + ", next random node is " + _currentNode); } else { @@ -94,7 +93,6 @@ public class WalkInfo { // Notify quest EventDispatcher.getInstance().notifyEventAsync(new OnNpcMoveRouteFinished(npc), npc); - npc.sendDebugMessage("Route: " + getRoute().getName() + ", last node arrived"); if (!getRoute().repeatWalk()) { diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/L2Character.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/L2Character.java index c65da7865f..b678f99e09 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/L2Character.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/L2Character.java @@ -220,8 +220,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe private final byte[] _zones = new byte[ZoneId.getZoneCount()]; protected byte _zoneValidateCounter = 4; - private L2Character _debugger = null; - private final ReentrantLock _teleportLock = new ReentrantLock(); private final Object _attackLock = new Object(); @@ -353,48 +351,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe return _effectList; } - /** - * Verify if this character is under debug. - * @return {@code true} if this character is under debug, {@code false} otherwise - */ - public boolean isDebug() - { - return _debugger != null; - } - - /** - * Sets character instance, to which debug packets will be send. - * @param debugger the character debugging this character - */ - public void setDebug(L2Character debugger) - { - _debugger = debugger; - } - - /** - * Send debug packet. - * @param pkt - */ - public void sendDebugPacket(IClientOutgoingPacket pkt) - { - if (_debugger != null) - { - _debugger.sendPacket(pkt); - } - } - - /** - * Send debug text string - * @param msg - */ - public void sendDebugMessage(String msg) - { - if (_debugger != null) - { - _debugger.sendMessage(msg); - } - } - /** * @return character inventory, default null, overridden in L2Playable types and in L2NPcInstance */ @@ -1712,8 +1668,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe @Override public boolean deleteMe() { - setDebug(null); - if (hasAI()) { getAI().stopAITask(); diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/L2Npc.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/L2Npc.java index f93be6c22b..c1216af688 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/L2Npc.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/L2Npc.java @@ -728,10 +728,6 @@ public class L2Npc extends L2Character { html = html.replaceAll("%objectId%", String.valueOf(getObjectId())); player.sendPacket(new NpcHtmlMessage(getObjectId(), html)); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML : data/html/" + type + "/" + getId() + "-pk.htm"); - } player.sendPacket(ActionFailed.STATIC_PACKET); return true; } @@ -857,11 +853,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } @@ -879,11 +870,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java index f3a695311a..06edf6f425 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java @@ -10761,7 +10761,6 @@ public final class L2PcInstance extends L2Playable abortAttack(); abortCast(); stopMove(null); - setDebug(null); } catch (Exception e) { diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/entity/Hero.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/entity/Hero.java index d0c33ad058..d62385e1b8 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/entity/Hero.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/entity/Hero.java @@ -520,11 +520,6 @@ public class Hero } activeChar.sendPacket(DiaryReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herodiary.htm"); - } } } } @@ -617,11 +612,6 @@ public class Hero FightReply.replace("%loos%", String.valueOf(_loss)); activeChar.sendPacket(FightReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herohistory.htm"); - } } } } diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java index 7b3bdb6b14..06040c0806 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java @@ -26,8 +26,6 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; import com.l2jmobius.gameserver.model.items.type.EtcItemType; import com.l2jmobius.gameserver.model.items.type.ItemType; -import com.l2jmobius.gameserver.network.Debug; -import com.l2jmobius.gameserver.util.Util; /** * @author UnAfraid @@ -183,34 +181,6 @@ public final class EnchantScroll extends AbstractEnchantItem final double random = 100 * Rnd.nextDouble(); boolean success = (random < finalChance) || player.tryLuck(); - if (player.isDebug()) - { - final EnchantItemGroup group = EnchantItemGroupsData.getInstance().getItemGroup(enchantItem.getItem(), _scrollGroupId); - final StatsSet set = new StatsSet(); - if (isBlessed()) - { - set.set("isBlessed", isBlessed()); - } - if (isSafe()) - { - set.set("isSafe", isSafe()); - } - set.set("chance", Util.formatDouble(chance, "#.##")); - if (bonusRate > 0) - { - set.set("bonusRate", Util.formatDouble(bonusRate, "#.##")); - } - if (supportBonusRate > 0) - { - set.set("supportBonusRate", Util.formatDouble(supportBonusRate, "#.##")); - } - set.set("finalChance", Util.formatDouble(finalChance, "#.##")); - set.set("random", Util.formatDouble(random, "#.##")); - set.set("success", success); - set.set("item group", group.getName()); - set.set("scroll group", _scrollGroupId); - Debug.sendItemDebug(player, enchantItem, set); - } return success ? EnchantResultType.SUCCESS : EnchantResultType.FAILURE; } } diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java index 84a104a610..dee9fd482b 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java @@ -209,10 +209,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } @@ -240,10 +236,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/options/Options.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/options/Options.java index 660c49c76e..475f2a94d8 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/options/Options.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/options/Options.java @@ -159,7 +159,6 @@ public class Options public void apply(L2PcInstance player) { - player.sendDebugMessage("Activating option id: " + _id); if (hasEffects()) { final BuffInfo info = new BuffInfo(player, player, null, true, null, this); @@ -171,7 +170,6 @@ public class Options { effect.instant(info.getEffector(), info.getEffected(), info.getSkill(), info.getItem()); } - player.sendDebugMessage("Appling instant effect: " + effect.getClass().getSimpleName()); } else { @@ -182,8 +180,6 @@ public class Options { info.addEffect(effect); } - - player.sendDebugMessage("Appling continious effect: " + effect.getClass().getSimpleName()); } } if (!info.getEffects().isEmpty()) @@ -196,7 +192,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -204,7 +199,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -212,7 +206,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.addTriggerSkill(holder); - player.sendDebugMessage("Adding trigger skill: " + holder); } } @@ -222,14 +215,12 @@ public class Options public void remove(L2PcInstance player) { - player.sendDebugMessage("Deactivating option id: " + _id); if (hasEffects()) { for (BuffInfo info : player.getEffectList().getOptions()) { if (info.getOption() == this) { - player.sendDebugMessage("Removing effects: " + info.getEffects()); player.getEffectList().remove(info, false, true, true); } } @@ -239,7 +230,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { player.removeSkill(holder.getSkill(), false, false); - player.sendDebugMessage("Removing active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -247,7 +237,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { player.removeSkill(holder.getSkill(), false, true); - player.sendDebugMessage("Removing passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -255,7 +244,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.removeTriggerSkill(holder); - player.sendDebugMessage("Removing trigger skill: " + holder); } } diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/quest/Quest.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/quest/Quest.java index 4bd1e734a4..63099321da 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/quest/Quest.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/quest/Quest.java @@ -2773,11 +2773,6 @@ public class Quest extends AbstractScript implements IIdentifiable player.sendPacket(npcReply); } player.sendPacket(ActionFailed.STATIC_PACKET); - - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + (filename.startsWith("data/") ? filename : "data/scripts/" + getPath().toLowerCase() + "/" + getName() + "/" + filename)); - } } return content; diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/skills/Skill.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/skills/Skill.java index 7505001c60..164957d7a5 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/skills/Skill.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/skills/Skill.java @@ -1159,7 +1159,6 @@ public final class Skill implements IIdentifiable { return null; } - activeChar.sendDebugMessage("-> " + this + "\n TT: " + getTargetType() + "\n AS: " + getAffectScope() + "\n AO: " + getAffectObject()); final IAffectScopeHandler handler = AffectScopeHandler.getInstance().getHandler(getAffectScope()); if (handler != null) { @@ -1338,7 +1337,6 @@ public final class Skill implements IIdentifiable if (effected.isIgnoringSkillEffects(getId(), getLevel())) { - effected.sendDebugMessage("Skill " + toString() + " has been ignored (ignoring skill effects)"); return; } @@ -1376,7 +1374,6 @@ public final class Skill implements IIdentifiable { final BasicPropertyResist resist = effected.getBasicPropertyResist(getBasicProperty()); resist.increaseResistLevel(); - effected.sendDebugMessage(toString() + " has increased your " + getBasicProperty() + " debuff resistance to " + resist.getResistLevel() + " level for " + resist.getRemainTime().toMillis() + " milliseconds."); } } diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/stats/Formulas.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/stats/Formulas.java index 442fbd88de..5acce4493e 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/stats/Formulas.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/model/stats/Formulas.java @@ -29,7 +29,6 @@ import com.l2jmobius.gameserver.enums.BasicProperty; import com.l2jmobius.gameserver.enums.DispelSlotType; import com.l2jmobius.gameserver.enums.Position; import com.l2jmobius.gameserver.enums.ShotType; -import com.l2jmobius.gameserver.model.StatsSet; import com.l2jmobius.gameserver.model.actor.L2Character; import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.actor.instance.L2SiegeFlagInstance; @@ -46,7 +45,6 @@ import com.l2jmobius.gameserver.model.skills.AbnormalType; import com.l2jmobius.gameserver.model.skills.BuffInfo; import com.l2jmobius.gameserver.model.skills.Skill; import com.l2jmobius.gameserver.model.skills.SkillCaster; -import com.l2jmobius.gameserver.network.Debug; import com.l2jmobius.gameserver.network.SystemMessageId; import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; @@ -124,26 +122,6 @@ public final class Formulas final double baseMod = ((77 * (((power + attacker.getPAtk()) * 0.666 * ssmod * cdMult) + (isPosition * (power + (attacker.getPAtk() * ssmod)) * randomMod) + (6 * cdPatk))) / defence); final double damage = baseMod * weaponTraitMod * generalTraitMod * attributeMod * randomMod * pvpPveMod; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("skillPower", power); - set.set("ssboost", ssmod); - set.set("isPosition", isPosition); - set.set("baseMod", baseMod); - set.set("criticalMod", criticalMod); - set.set("criticalVulnMod", criticalVulnMod); - set.set("criticalAddMod", criticalAddMod); - set.set("criticalAddVuln", criticalAddVuln); - set.set("weaponTraitMod", weaponTraitMod); - set.set("generalTraitMod", generalTraitMod); - set.set("attributeMod", attributeMod); - set.set("weaponMod", randomMod); - set.set("penaltyMod", pvpPveMod); - set.set("damage", (int) damage); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return damage; } @@ -706,18 +684,6 @@ public final class Formulas final double rate = baseMod * elementMod * traitMod * buffDebuffMod; final double finalRate = traitMod > 0 ? CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist : 0; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseMod); - set.set("elementMod", elementMod); - set.set("traitMod", traitMod); - set.set("buffDebuffMod", buffDebuffMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - if ((finalRate <= Rnd.get(100)) && (target != attacker)) { final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_RESISTED_YOUR_S2); @@ -786,19 +752,6 @@ public final class Formulas // Check the Rate Limits. final double finalRate = CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist; - if (attacker.getOwner().isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseRate); - set.set("resMod", resMod); - set.set("statMod", statMod); - set.set("elementMod", elementMod); - set.set("lvlBonusMod", lvlBonusMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker.getOwner(), target, skill, set); - } - return Rnd.get(100) < finalRate; } @@ -824,17 +777,6 @@ public final class Formulas final double resModifier = target.getStat().getValue(Stats.MAGIC_SUCCESS_RES, 1); final int rate = 100 - Math.round((float) (lvlModifier * targetModifier * resModifier)); - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("lvlDifference", lvlDifference); - set.set("lvlModifier", lvlModifier); - set.set("resModifier", resModifier); - set.set("targetModifier", targetModifier); - set.set("rate", rate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return (Rnd.get(100) < rate); } @@ -1102,15 +1044,6 @@ public final class Formulas { // Resist Modifier. final int cancelMagicLvl = skill.getMagicLevel(); - if (activeChar.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", rate); - set.set("magicLevel", cancelMagicLvl); - set.set("resMod", target.getStat().getValue(Stats.RESIST_DISPEL_BUFF, 1)); - set.set("rate", rate); - Debug.sendSkillDebug(activeChar, target, skill, set); - } // Prevent initialization. final List buffs = target.getEffectList().getBuffs(); diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java index 3f95262f76..bb06f1bfcc 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java @@ -164,10 +164,6 @@ public final class RequestBypassToServer implements IClientIncomingPacket ((L2Npc) object).onBypassFeedback(activeChar, _command.substring(endOfId + 1)); } } - else - { - activeChar.sendDebugMessage("ObjectId of npc bypass is not digit: " + id); - } activeChar.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java index 4f25b1bbf4..d8a598fa60 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java @@ -76,10 +76,5 @@ public final class RequestLinkHtml implements IClientIncomingPacket final NpcHtmlMessage msg = new NpcHtmlMessage(htmlObjectId); msg.setFile(actor.getHtmlPrefix(), filename); actor.sendPacket(msg); - - if (actor.isGM() && actor.isDebug()) - { - actor.sendMessage("HTML: " + filename); - } } } diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/config/AdminCommands.xml b/L2J_Mobius_Classic_2.0_Saviors/dist/game/config/AdminCommands.xml index d74ab987f6..cda7d5cced 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/config/AdminCommands.xml +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/config/AdminCommands.xml @@ -95,9 +95,6 @@ - - - diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/MasterHandler.java b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/MasterHandler.java index b2e61af8eb..567c257ad0 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/MasterHandler.java +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/MasterHandler.java @@ -68,7 +68,6 @@ import handlers.admincommandhandlers.AdminClan; import handlers.admincommandhandlers.AdminClanHall; import handlers.admincommandhandlers.AdminCreateItem; import handlers.admincommandhandlers.AdminCursedWeapons; -import handlers.admincommandhandlers.AdminDebug; import handlers.admincommandhandlers.AdminDelete; import handlers.admincommandhandlers.AdminDisconnect; import handlers.admincommandhandlers.AdminDoorControl; @@ -331,7 +330,6 @@ import handlers.usercommandhandlers.Unstuck; import handlers.voicedcommandhandlers.Banking; import handlers.voicedcommandhandlers.ChangePassword; import handlers.voicedcommandhandlers.ChatAdmin; -import handlers.voicedcommandhandlers.Debug; import handlers.voicedcommandhandlers.Lang; import handlers.voicedcommandhandlers.Premium; import handlers.voicedcommandhandlers.StatsVCmd; @@ -400,7 +398,6 @@ public class MasterHandler AdminPcCondOverride.class, AdminCreateItem.class, AdminCursedWeapons.class, - AdminDebug.class, AdminDelete.class, AdminDisconnect.class, AdminDoorControl.class, @@ -589,7 +586,6 @@ public class MasterHandler Config.BANKING_SYSTEM_ENABLED ? Banking.class : null, Config.CHAT_ADMIN ? ChatAdmin.class : null, Config.MULTILANG_ENABLE && Config.MULTILANG_VOICED_ALLOW ? Lang.class : null, - Config.DEBUG_VOICE_COMMAND ? Debug.class : null, Config.ALLOW_CHANGE_PASSWORD ? ChangePassword.class : null, Config.PREMIUM_SYSTEM_ENABLED ? Premium.class : null, }, diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java deleted file mode 100644 index e24b2654c0..0000000000 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/admincommandhandlers/AdminDebug.java +++ /dev/null @@ -1,85 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.admincommandhandlers; - -import com.l2jmobius.gameserver.handler.IAdminCommandHandler; -import com.l2jmobius.gameserver.model.L2Object; -import com.l2jmobius.gameserver.model.L2World; -import com.l2jmobius.gameserver.model.actor.L2Character; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; -import com.l2jmobius.gameserver.network.SystemMessageId; - -public class AdminDebug implements IAdminCommandHandler -{ - private static final String[] ADMIN_COMMANDS = - { - "admin_debug" - }; - - @Override - public final boolean useAdminCommand(String command, L2PcInstance activeChar) - { - final String[] commandSplit = command.split(" "); - if (ADMIN_COMMANDS[0].equalsIgnoreCase(commandSplit[0])) - { - L2Object target; - if (commandSplit.length > 1) - { - target = L2World.getInstance().getPlayer(commandSplit[1].trim()); - if (target == null) - { - activeChar.sendPacket(SystemMessageId.THAT_PLAYER_IS_NOT_ONLINE); - return true; - } - } - else - { - target = activeChar.getTarget(); - } - - if (target instanceof L2Character) - { - setDebug(activeChar, (L2Character) target); - } - else - { - setDebug(activeChar, activeChar); - } - } - return true; - } - - @Override - public final String[] getAdminCommandList() - { - return ADMIN_COMMANDS; - } - - private final void setDebug(L2PcInstance activeChar, L2Character target) - { - if (target.isDebug()) - { - target.setDebug(null); - activeChar.sendMessage("Stop debugging " + target.getName()); - } - else - { - target.setDebug(activeChar); - activeChar.sendMessage("Start debugging " + target.getName()); - } - } -} diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java index 6bfefc9c73..01cafb9d92 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/effecthandlers/ResistSkill.java @@ -59,18 +59,15 @@ public final class ResistSkill extends AbstractEffect for (SkillHolder holder : _skills) { effected.addIgnoreSkillEffects(holder); - effected.sendDebugMessage("Applying invul against " + holder.getSkill()); } } @Override public void onExit(BuffInfo info) { - final L2Character effected = info.getEffected(); for (SkillHolder holder : _skills) { info.getEffected().removeIgnoreSkillEffects(holder); - effected.sendDebugMessage("Removing invul against " + holder.getSkill()); } } } diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java deleted file mode 100644 index 5ead4cc7d9..0000000000 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/voicedcommandhandlers/Debug.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package handlers.voicedcommandhandlers; - -import com.l2jmobius.gameserver.data.xml.impl.AdminData; -import com.l2jmobius.gameserver.handler.IVoicedCommandHandler; -import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; - -public class Debug implements IVoicedCommandHandler -{ - private static final String[] VOICED_COMMANDS = - { - "debug" - }; - - @Override - public boolean useVoicedCommand(String command, L2PcInstance activeChar, String params) - { - if (!AdminData.getInstance().hasAccess(command, activeChar.getAccessLevel())) - { - return false; - } - - if (VOICED_COMMANDS[0].equalsIgnoreCase(command)) - { - if (activeChar.isDebug()) - { - activeChar.setDebug(null); - activeChar.sendMessage("Debugging disabled."); - } - else - { - activeChar.setDebug(activeChar); - activeChar.sendMessage("Debugging enabled."); - } - } - return true; - } - - @Override - public String[] getVoicedCommandList() - { - return VOICED_COMMANDS; - } -} \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java index b56e5922f7..e9c54b975a 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/instancemanager/WalkingManager.java @@ -274,12 +274,6 @@ public final class WalkingManager implements IGameXmlReader if ((npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_ACTIVE) || (npc.getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)) { final WalkInfo walk = new WalkInfo(routeName); - - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - L2NpcWalkerNode node = walk.getCurrentNode(); // adjust next waypoint, if NPC spawns at first waypoint @@ -287,18 +281,15 @@ public final class WalkingManager implements IGameXmlReader { walk.calculateNextNode(npc); node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "': spawn point is same with first waypoint, adjusted to next"); } if (!npc.isInsideRadius(node, 3000, true, false)) { final String message = "Route '" + routeName + "': NPC (id=" + npc.getId() + ", x=" + npc.getX() + ", y=" + npc.getY() + ", z=" + npc.getZ() + ") is too far from starting point (node x=" + node.getX() + ", y=" + node.getY() + ", z=" + node.getZ() + ", range=" + npc.calculateDistance(node, true, true) + "), walking will not start"; LOGGER.warning(message); - npc.sendDebugMessage(message); return; } - npc.sendDebugMessage("Starting to move at route '" + routeName + "'"); if (node.runToLocation()) { npc.setRunning(); @@ -314,7 +305,6 @@ public final class WalkingManager implements IGameXmlReader } else { - npc.sendDebugMessage("Failed to start moving along route '" + routeName + "', scheduled"); ThreadPoolManager.schedule(new StartMovingTask(npc, routeName), 60000); } } @@ -332,13 +322,11 @@ public final class WalkingManager implements IGameXmlReader // Prevent call simultaneously from scheduled task and onArrived() or temporarily stop walking for resuming in future if (walk.isBlocked() || walk.isSuspended()) { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (operation is blocked)"); return; } walk.setBlocked(true); final L2NpcWalkerNode node = walk.getCurrentNode(); - npc.sendDebugMessage("Route '" + routeName + "', continuing to node " + walk.getCurrentNodeId()); if (node.runToLocation()) { npc.setRunning(); @@ -351,10 +339,6 @@ public final class WalkingManager implements IGameXmlReader walk.setBlocked(false); walk.setStoppedByAttack(false); } - else - { - npc.sendDebugMessage("Failed to continue moving along route '" + routeName + "' (wrong AI state - " + npc.getAI().getIntention() + ")"); - } } } } @@ -450,8 +434,6 @@ public final class WalkingManager implements IGameXmlReader final L2NpcWalkerNode node = walk.getRoute().getNodeList().get(walk.getCurrentNodeId()); if (npc.isInsideRadius(node, 10, false, false)) { - npc.sendDebugMessage("Route '" + walk.getRoute().getName() + "', arrived to node " + walk.getCurrentNodeId()); - npc.sendDebugMessage("Done in " + ((System.currentTimeMillis() - walk.getLastAction()) / 1000) + " s"); walk.calculateNextNode(npc); walk.setBlocked(true); // prevents to be ran from walk check task, if there is delay in this node. @@ -464,11 +446,6 @@ public final class WalkingManager implements IGameXmlReader npc.broadcastSay(ChatType.NPC_GENERAL, node.getChatText()); } - if (npc.isDebug()) - { - walk.setLastAction(System.currentTimeMillis()); - } - ThreadPoolManager.schedule(new ArrivedTask(npc, walk), 100 + (node.getDelay() * 1000L)); } } diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/WalkInfo.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/WalkInfo.java index 89a519f7fb..22cfd07cc9 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/WalkInfo.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/WalkInfo.java @@ -77,7 +77,6 @@ public class WalkInfo } _currentNode = newNode; - npc.sendDebugMessage("Route: " + getRoute().getName() + ", next random node is " + _currentNode); } else { @@ -94,7 +93,6 @@ public class WalkInfo { // Notify quest EventDispatcher.getInstance().notifyEventAsync(new OnNpcMoveRouteFinished(npc), npc); - npc.sendDebugMessage("Route: " + getRoute().getName() + ", last node arrived"); if (!getRoute().repeatWalk()) { diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/L2Character.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/L2Character.java index c65da7865f..b678f99e09 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/L2Character.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/L2Character.java @@ -220,8 +220,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe private final byte[] _zones = new byte[ZoneId.getZoneCount()]; protected byte _zoneValidateCounter = 4; - private L2Character _debugger = null; - private final ReentrantLock _teleportLock = new ReentrantLock(); private final Object _attackLock = new Object(); @@ -353,48 +351,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe return _effectList; } - /** - * Verify if this character is under debug. - * @return {@code true} if this character is under debug, {@code false} otherwise - */ - public boolean isDebug() - { - return _debugger != null; - } - - /** - * Sets character instance, to which debug packets will be send. - * @param debugger the character debugging this character - */ - public void setDebug(L2Character debugger) - { - _debugger = debugger; - } - - /** - * Send debug packet. - * @param pkt - */ - public void sendDebugPacket(IClientOutgoingPacket pkt) - { - if (_debugger != null) - { - _debugger.sendPacket(pkt); - } - } - - /** - * Send debug text string - * @param msg - */ - public void sendDebugMessage(String msg) - { - if (_debugger != null) - { - _debugger.sendMessage(msg); - } - } - /** * @return character inventory, default null, overridden in L2Playable types and in L2NPcInstance */ @@ -1712,8 +1668,6 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe @Override public boolean deleteMe() { - setDebug(null); - if (hasAI()) { getAI().stopAITask(); diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/L2Npc.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/L2Npc.java index 16ddff8ee6..2def7d55d8 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/L2Npc.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/L2Npc.java @@ -728,10 +728,6 @@ public class L2Npc extends L2Character { html = html.replaceAll("%objectId%", String.valueOf(getObjectId())); player.sendPacket(new NpcHtmlMessage(getObjectId(), html)); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML : data/html/" + type + "/" + getId() + "-pk.htm"); - } player.sendPacket(ActionFailed.STATIC_PACKET); return true; } @@ -857,11 +853,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } @@ -879,11 +870,6 @@ public class L2Npc extends L2Character html.replace("%objectId%", String.valueOf(getObjectId())); player.sendPacket(html); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + filename); - } - // Send a Server->Client ActionFailed to the L2PcInstance in order to avoid that the client wait another packet player.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java index ad4e6545ad..7a4b9ea552 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/actor/instance/L2PcInstance.java @@ -10701,7 +10701,6 @@ public final class L2PcInstance extends L2Playable abortAttack(); abortCast(); stopMove(null); - setDebug(null); } catch (Exception e) { diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/entity/Hero.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/entity/Hero.java index d0c33ad058..d62385e1b8 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/entity/Hero.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/entity/Hero.java @@ -520,11 +520,6 @@ public class Hero } activeChar.sendPacket(DiaryReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herodiary.htm"); - } } } } @@ -617,11 +612,6 @@ public class Hero FightReply.replace("%loos%", String.valueOf(_loss)); activeChar.sendPacket(FightReply); - - if (activeChar.isGM() && activeChar.isDebug()) - { - activeChar.sendMessage("HTML: data/html/olympiad/herohistory.htm"); - } } } } diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java index f61f5ecb1e..b93772addc 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/items/enchant/EnchantScroll.java @@ -26,8 +26,6 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; import com.l2jmobius.gameserver.model.items.type.EtcItemType; import com.l2jmobius.gameserver.model.items.type.ItemType; -import com.l2jmobius.gameserver.network.Debug; -import com.l2jmobius.gameserver.util.Util; /** * @author UnAfraid @@ -183,34 +181,6 @@ public final class EnchantScroll extends AbstractEnchantItem final double random = 100 * Rnd.nextDouble(); final boolean success = (random < finalChance); - if (player.isDebug()) - { - final EnchantItemGroup group = EnchantItemGroupsData.getInstance().getItemGroup(enchantItem.getItem(), _scrollGroupId); - final StatsSet set = new StatsSet(); - if (isBlessed()) - { - set.set("isBlessed", isBlessed()); - } - if (isSafe()) - { - set.set("isSafe", isSafe()); - } - set.set("chance", Util.formatDouble(chance, "#.##")); - if (bonusRate > 0) - { - set.set("bonusRate", Util.formatDouble(bonusRate, "#.##")); - } - if (supportBonusRate > 0) - { - set.set("supportBonusRate", Util.formatDouble(supportBonusRate, "#.##")); - } - set.set("finalChance", Util.formatDouble(finalChance, "#.##")); - set.set("random", Util.formatDouble(random, "#.##")); - set.set("success", success); - set.set("item group", group.getName()); - set.set("scroll group", _scrollGroupId); - Debug.sendItemDebug(player, enchantItem, set); - } return success ? EnchantResultType.SUCCESS : EnchantResultType.FAILURE; } } diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java index b1a3037b05..bebb98e19b 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/olympiad/OlympiadManager.java @@ -209,10 +209,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } @@ -240,10 +236,6 @@ public class OlympiadManager message.setFile(player.getHtmlPrefix(), "data/html/mods/OlympiadIPRestriction.htm"); message.replace("%max%", String.valueOf(AntiFeedManager.getInstance().getLimit(player, Config.DUALBOX_CHECK_MAX_OLYMPIAD_PARTICIPANTS_PER_IP))); player.sendPacket(message); - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: data/html/mods/OlympiadIPRestriction.htm"); - } return false; } diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/options/Options.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/options/Options.java index 660c49c76e..475f2a94d8 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/options/Options.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/options/Options.java @@ -159,7 +159,6 @@ public class Options public void apply(L2PcInstance player) { - player.sendDebugMessage("Activating option id: " + _id); if (hasEffects()) { final BuffInfo info = new BuffInfo(player, player, null, true, null, this); @@ -171,7 +170,6 @@ public class Options { effect.instant(info.getEffector(), info.getEffected(), info.getSkill(), info.getItem()); } - player.sendDebugMessage("Appling instant effect: " + effect.getClass().getSimpleName()); } else { @@ -182,8 +180,6 @@ public class Options { info.addEffect(effect); } - - player.sendDebugMessage("Appling continious effect: " + effect.getClass().getSimpleName()); } } if (!info.getEffects().isEmpty()) @@ -196,7 +192,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -204,7 +199,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { addSkill(player, holder.getSkill()); - player.sendDebugMessage("Adding passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -212,7 +206,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.addTriggerSkill(holder); - player.sendDebugMessage("Adding trigger skill: " + holder); } } @@ -222,14 +215,12 @@ public class Options public void remove(L2PcInstance player) { - player.sendDebugMessage("Deactivating option id: " + _id); if (hasEffects()) { for (BuffInfo info : player.getEffectList().getOptions()) { if (info.getOption() == this) { - player.sendDebugMessage("Removing effects: " + info.getEffects()); player.getEffectList().remove(info, false, true, true); } } @@ -239,7 +230,6 @@ public class Options for (SkillHolder holder : getActiveSkills()) { player.removeSkill(holder.getSkill(), false, false); - player.sendDebugMessage("Removing active skill: " + getActiveSkills()); } } if (hasPassiveSkills()) @@ -247,7 +237,6 @@ public class Options for (SkillHolder holder : getPassiveSkills()) { player.removeSkill(holder.getSkill(), false, true); - player.sendDebugMessage("Removing passive skill: " + getPassiveSkills()); } } if (hasActivationSkills()) @@ -255,7 +244,6 @@ public class Options for (OptionsSkillHolder holder : _activationSkills) { player.removeTriggerSkill(holder); - player.sendDebugMessage("Removing trigger skill: " + holder); } } diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/quest/Quest.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/quest/Quest.java index 5a2a52293e..8f802007b8 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/quest/Quest.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/quest/Quest.java @@ -2772,11 +2772,6 @@ public class Quest extends AbstractScript implements IIdentifiable player.sendPacket(npcReply); } player.sendPacket(ActionFailed.STATIC_PACKET); - - if (player.isGM() && player.isDebug()) - { - player.sendMessage("HTML: " + (filename.startsWith("data/") ? filename : "data/scripts/" + getPath().toLowerCase() + "/" + getName() + "/" + filename)); - } } return content; diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/skills/Skill.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/skills/Skill.java index 7505001c60..164957d7a5 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/skills/Skill.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/skills/Skill.java @@ -1159,7 +1159,6 @@ public final class Skill implements IIdentifiable { return null; } - activeChar.sendDebugMessage("-> " + this + "\n TT: " + getTargetType() + "\n AS: " + getAffectScope() + "\n AO: " + getAffectObject()); final IAffectScopeHandler handler = AffectScopeHandler.getInstance().getHandler(getAffectScope()); if (handler != null) { @@ -1338,7 +1337,6 @@ public final class Skill implements IIdentifiable if (effected.isIgnoringSkillEffects(getId(), getLevel())) { - effected.sendDebugMessage("Skill " + toString() + " has been ignored (ignoring skill effects)"); return; } @@ -1376,7 +1374,6 @@ public final class Skill implements IIdentifiable { final BasicPropertyResist resist = effected.getBasicPropertyResist(getBasicProperty()); resist.increaseResistLevel(); - effected.sendDebugMessage(toString() + " has increased your " + getBasicProperty() + " debuff resistance to " + resist.getResistLevel() + " level for " + resist.getRemainTime().toMillis() + " milliseconds."); } } diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/stats/Formulas.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/stats/Formulas.java index 2442dac54d..d5f04ac1d3 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/stats/Formulas.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/model/stats/Formulas.java @@ -29,7 +29,6 @@ import com.l2jmobius.gameserver.enums.BasicProperty; import com.l2jmobius.gameserver.enums.DispelSlotType; import com.l2jmobius.gameserver.enums.Position; import com.l2jmobius.gameserver.enums.ShotType; -import com.l2jmobius.gameserver.model.StatsSet; import com.l2jmobius.gameserver.model.actor.L2Character; import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; import com.l2jmobius.gameserver.model.actor.instance.L2SiegeFlagInstance; @@ -46,7 +45,6 @@ import com.l2jmobius.gameserver.model.skills.AbnormalType; import com.l2jmobius.gameserver.model.skills.BuffInfo; import com.l2jmobius.gameserver.model.skills.Skill; import com.l2jmobius.gameserver.model.skills.SkillCaster; -import com.l2jmobius.gameserver.network.Debug; import com.l2jmobius.gameserver.network.SystemMessageId; import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; @@ -124,26 +122,6 @@ public final class Formulas final double baseMod = ((77 * (((power + attacker.getPAtk()) * 0.666 * ssmod * cdMult) + (isPosition * (power + (attacker.getPAtk() * ssmod)) * randomMod) + (6 * cdPatk))) / defence); final double damage = baseMod * weaponTraitMod * generalTraitMod * attributeMod * randomMod * pvpPveMod; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("skillPower", power); - set.set("ssboost", ssmod); - set.set("isPosition", isPosition); - set.set("baseMod", baseMod); - set.set("criticalMod", criticalMod); - set.set("criticalVulnMod", criticalVulnMod); - set.set("criticalAddMod", criticalAddMod); - set.set("criticalAddVuln", criticalAddVuln); - set.set("weaponTraitMod", weaponTraitMod); - set.set("generalTraitMod", generalTraitMod); - set.set("attributeMod", attributeMod); - set.set("weaponMod", randomMod); - set.set("penaltyMod", pvpPveMod); - set.set("damage", (int) damage); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return damage; } @@ -706,18 +684,6 @@ public final class Formulas final double rate = baseMod * elementMod * traitMod * buffDebuffMod; final double finalRate = traitMod > 0 ? CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist : 0; - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseMod); - set.set("elementMod", elementMod); - set.set("traitMod", traitMod); - set.set("buffDebuffMod", buffDebuffMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - if ((finalRate <= Rnd.get(100)) && (target != attacker)) { final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_HAS_RESISTED_YOUR_S2); @@ -786,19 +752,6 @@ public final class Formulas // Check the Rate Limits. final double finalRate = CommonUtil.constrain(rate, skill.getMinChance(), skill.getMaxChance()) * basicPropertyResist; - if (attacker.getOwner().isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", baseRate); - set.set("resMod", resMod); - set.set("statMod", statMod); - set.set("elementMod", elementMod); - set.set("lvlBonusMod", lvlBonusMod); - set.set("rate", rate); - set.set("finalRate", finalRate); - Debug.sendSkillDebug(attacker.getOwner(), target, skill, set); - } - return Rnd.get(100) < finalRate; } @@ -824,17 +777,6 @@ public final class Formulas final double resModifier = target.getStat().getValue(Stats.MAGIC_SUCCESS_RES, 1); final int rate = 100 - Math.round((float) (lvlModifier * targetModifier * resModifier)); - if (attacker.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("lvlDifference", lvlDifference); - set.set("lvlModifier", lvlModifier); - set.set("resModifier", resModifier); - set.set("targetModifier", targetModifier); - set.set("rate", rate); - Debug.sendSkillDebug(attacker, target, skill, set); - } - return (Rnd.get(100) < rate); } @@ -1102,15 +1044,6 @@ public final class Formulas { // Resist Modifier. final int cancelMagicLvl = skill.getMagicLevel(); - if (activeChar.isDebug()) - { - final StatsSet set = new StatsSet(); - set.set("baseMod", rate); - set.set("magicLevel", cancelMagicLvl); - set.set("resMod", target.getStat().getValue(Stats.RESIST_DISPEL_BUFF, 1)); - set.set("rate", rate); - Debug.sendSkillDebug(activeChar, target, skill, set); - } // Prevent initialization. final List buffs = target.getEffectList().getBuffs(); diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java index 3f95262f76..bb06f1bfcc 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestBypassToServer.java @@ -164,10 +164,6 @@ public final class RequestBypassToServer implements IClientIncomingPacket ((L2Npc) object).onBypassFeedback(activeChar, _command.substring(endOfId + 1)); } } - else - { - activeChar.sendDebugMessage("ObjectId of npc bypass is not digit: " + id); - } activeChar.sendPacket(ActionFailed.STATIC_PACKET); } diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java index 4f25b1bbf4..d8a598fa60 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestLinkHtml.java @@ -76,10 +76,5 @@ public final class RequestLinkHtml implements IClientIncomingPacket final NpcHtmlMessage msg = new NpcHtmlMessage(htmlObjectId); msg.setFile(actor.getHtmlPrefix(), filename); actor.sendPacket(msg); - - if (actor.isGM() && actor.isDebug()) - { - actor.sendMessage("HTML: " + filename); - } } }