From 0a03d1adb1e3671c99af82b981aa3ec41a8c1838 Mon Sep 17 00:00:00 2001 From: MobiusDev <8391001+MobiusDevelopment@users.noreply.github.com> Date: Sun, 10 Dec 2017 18:34:33 +0000 Subject: [PATCH] Enabled out of region tempfix. --- .../gameserver/model/actor/L2Character.java | 22 +++++++++++++++---- .../gameserver/model/actor/L2Character.java | 22 +++++++++++++++---- .../gameserver/model/actor/L2Character.java | 22 +++++++++++++++---- .../gameserver/model/actor/L2Character.java | 22 +++++++++++++++---- .../gameserver/model/actor/L2Character.java | 22 +++++++++++++++---- .../gameserver/model/actor/L2Character.java | 22 +++++++++++++++---- 6 files changed, 108 insertions(+), 24 deletions(-) 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 165ef19cea..bc4ae21385 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 @@ -3266,10 +3266,24 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe } // Temporary fix for character outside world region errors (should not happen) - /* - * if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) { _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); - * getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); if (isPlayer()) { getActingPlayer().logout(); } else if (isSummon()) { return; } else { onDecay(); } return; } - */ + if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) + { + _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); + getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); + if (isPlayer()) + { + getActingPlayer().logout(); + } + else if (isSummon()) + { + return; + } + else + { + onDecay(); + } + return; + } // location different if destination wasn't reached (or just z coord is different) final Location destiny = GeoEngine.getInstance().canMoveToTargetLoc(curX, curY, curZ, x, y, z, getInstanceWorld()); 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 165ef19cea..bc4ae21385 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 @@ -3266,10 +3266,24 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe } // Temporary fix for character outside world region errors (should not happen) - /* - * if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) { _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); - * getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); if (isPlayer()) { getActingPlayer().logout(); } else if (isSummon()) { return; } else { onDecay(); } return; } - */ + if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) + { + _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); + getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); + if (isPlayer()) + { + getActingPlayer().logout(); + } + else if (isSummon()) + { + return; + } + else + { + onDecay(); + } + return; + } // location different if destination wasn't reached (or just z coord is different) final Location destiny = GeoEngine.getInstance().canMoveToTargetLoc(curX, curY, curZ, x, y, z, getInstanceWorld()); 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 165ef19cea..bc4ae21385 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 @@ -3266,10 +3266,24 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe } // Temporary fix for character outside world region errors (should not happen) - /* - * if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) { _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); - * getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); if (isPlayer()) { getActingPlayer().logout(); } else if (isSummon()) { return; } else { onDecay(); } return; } - */ + if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) + { + _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); + getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); + if (isPlayer()) + { + getActingPlayer().logout(); + } + else if (isSummon()) + { + return; + } + else + { + onDecay(); + } + return; + } // location different if destination wasn't reached (or just z coord is different) final Location destiny = GeoEngine.getInstance().canMoveToTargetLoc(curX, curY, curZ, x, y, z, getInstanceWorld()); 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 165ef19cea..bc4ae21385 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 @@ -3266,10 +3266,24 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe } // Temporary fix for character outside world region errors (should not happen) - /* - * if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) { _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); - * getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); if (isPlayer()) { getActingPlayer().logout(); } else if (isSummon()) { return; } else { onDecay(); } return; } - */ + if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) + { + _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); + getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); + if (isPlayer()) + { + getActingPlayer().logout(); + } + else if (isSummon()) + { + return; + } + else + { + onDecay(); + } + return; + } // location different if destination wasn't reached (or just z coord is different) final Location destiny = GeoEngine.getInstance().canMoveToTargetLoc(curX, curY, curZ, x, y, z, getInstanceWorld()); diff --git a/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/model/actor/L2Character.java b/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/model/actor/L2Character.java index eaa45dcb9d..9594caaab0 100644 --- a/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/model/actor/L2Character.java +++ b/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/model/actor/L2Character.java @@ -4373,10 +4373,24 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe } // Temporary fix for character outside world region errors (should not happen) - /* - * if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) { _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); - * getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); if (isPlayer()) { getActingPlayer().logout(); } else if (isSummon()) { return; } else { onDecay(); } return; } - */ + if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) + { + _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); + getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); + if (isPlayer()) + { + getActingPlayer().logout(); + } + else if (isSummon()) + { + return; + } + else + { + onDecay(); + } + return; + } // location different if destination wasn't reached (or just z coord is different) final Location destiny = GeoEngine.getInstance().canMoveToTargetLoc(curX, curY, curZ, x, y, z, getInstanceId()); 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 165ef19cea..bc4ae21385 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 @@ -3266,10 +3266,24 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe } // Temporary fix for character outside world region errors (should not happen) - /* - * if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) { _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); - * getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); if (isPlayer()) { getActingPlayer().logout(); } else if (isSummon()) { return; } else { onDecay(); } return; } - */ + if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y)) + { + _log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY); + getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE); + if (isPlayer()) + { + getActingPlayer().logout(); + } + else if (isSummon()) + { + return; + } + else + { + onDecay(); + } + return; + } // location different if destination wasn't reached (or just z coord is different) final Location destiny = GeoEngine.getInstance().canMoveToTargetLoc(curX, curY, curZ, x, y, z, getInstanceWorld());