From 1711e192b6d50fe6aa168e50bc4d0ed960372c39 Mon Sep 17 00:00:00 2001 From: Rumen Nikiforov <unafraid89@gmail.com> Date: Sun, 20 May 2012 18:16:48 +0000 Subject: [PATCH] BETA: Visual glitch fix for pet owners that appeared to be healed when its pets received a heal. * ExRegMax packet was sent to the Owner of a pet/servitor when it get healed by overtime effect but it shouldn't. --- .../scripts/handlers/effecthandlers/HealOverTime.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/L2J_DataPack_BETA/dist/game/data/scripts/handlers/effecthandlers/HealOverTime.java b/L2J_DataPack_BETA/dist/game/data/scripts/handlers/effecthandlers/HealOverTime.java index c86effde59..4b5b83eb15 100644 --- a/L2J_DataPack_BETA/dist/game/data/scripts/handlers/effecthandlers/HealOverTime.java +++ b/L2J_DataPack_BETA/dist/game/data/scripts/handlers/effecthandlers/HealOverTime.java @@ -14,7 +14,6 @@ */ package handlers.effecthandlers; -import com.l2jserver.gameserver.model.actor.instance.L2DoorInstance; import com.l2jserver.gameserver.model.effects.EffectTemplate; import com.l2jserver.gameserver.model.effects.L2Effect; import com.l2jserver.gameserver.model.effects.L2EffectType; @@ -50,7 +49,10 @@ public class HealOverTime extends L2Effect @Override public boolean onStart() { - getEffected().sendPacket(new ExRegMax(calc(), getTotalCount() * getAbnormalTime(), getAbnormalTime())); + if (getEffected().isPlayer()) + { + getEffected().sendPacket(new ExRegMax(calc(), getTotalCount() * getAbnormalTime(), getAbnormalTime())); + } return true; } @@ -60,7 +62,7 @@ public class HealOverTime extends L2Effect if (getEffected().isDead()) return false; - if (getEffected() instanceof L2DoorInstance) + else if (getEffected().isDoor()) return false; double hp = getEffected().getCurrentHp(); -- GitLab