Fixed spawn protection.
This commit is contained in:
+5
-10
@@ -678,7 +678,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
|
|
||||||
public boolean isSpawnProtected()
|
public boolean isSpawnProtected()
|
||||||
{
|
{
|
||||||
return false; // TODO this is bugged. _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
return _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
||||||
}
|
}
|
||||||
|
|
||||||
private long _teleportProtectEndTime = 0;
|
private long _teleportProtectEndTime = 0;
|
||||||
@@ -3873,10 +3873,6 @@ public final class L2PcInstance extends L2Playable
|
|||||||
return item;
|
return item;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Set _protectEndTime according settings.
|
|
||||||
* @param protect
|
|
||||||
*/
|
|
||||||
public void setProtection(boolean protect)
|
public void setProtection(boolean protect)
|
||||||
{
|
{
|
||||||
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
||||||
@@ -3898,7 +3894,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set protection from agro mobs when getting up from fake death, according settings.
|
* Set protection from aggro mobs when getting up from fake death, according settings.
|
||||||
* @param protect
|
* @param protect
|
||||||
*/
|
*/
|
||||||
public void setRecentFakeDeath(boolean protect)
|
public void setRecentFakeDeath(boolean protect)
|
||||||
@@ -6179,7 +6175,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
@Override
|
@Override
|
||||||
public boolean isInvul()
|
public boolean isInvul()
|
||||||
{
|
{
|
||||||
return super.isInvul() || (_teleportProtectEndTime > GameTimeController.getInstance().getGameTicks());
|
return super.isInvul() || isTeleportProtected();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -10269,8 +10265,8 @@ public final class L2PcInstance extends L2Playable
|
|||||||
{
|
{
|
||||||
if (isSpawnProtected())
|
if (isSpawnProtected())
|
||||||
{
|
{
|
||||||
|
setProtection(false);
|
||||||
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
||||||
|
|
||||||
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
||||||
{
|
{
|
||||||
CharSummonTable.getInstance().restoreServitor(this);
|
CharSummonTable.getInstance().restoreServitor(this);
|
||||||
@@ -10282,10 +10278,9 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
if (isTeleportProtected())
|
if (isTeleportProtected())
|
||||||
{
|
{
|
||||||
|
setTeleportProtection(false);
|
||||||
sendMessage("Teleport spawn protection ended.");
|
sendMessage("Teleport spawn protection ended.");
|
||||||
}
|
}
|
||||||
setProtection(false);
|
|
||||||
setTeleportProtection(false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+6
@@ -157,5 +157,11 @@ public class MoveBackwardToLocation implements IClientIncomingPacket
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Mobius: Check spawn protections.
|
||||||
|
if (activeChar.isSpawnProtected() || activeChar.isTeleportProtected())
|
||||||
|
{
|
||||||
|
activeChar.onActionRequest();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+5
-10
@@ -680,7 +680,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
|
|
||||||
public boolean isSpawnProtected()
|
public boolean isSpawnProtected()
|
||||||
{
|
{
|
||||||
return false; // TODO this is bugged. _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
return _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
||||||
}
|
}
|
||||||
|
|
||||||
private long _teleportProtectEndTime = 0;
|
private long _teleportProtectEndTime = 0;
|
||||||
@@ -3879,10 +3879,6 @@ public final class L2PcInstance extends L2Playable
|
|||||||
return item;
|
return item;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Set _protectEndTime according settings.
|
|
||||||
* @param protect
|
|
||||||
*/
|
|
||||||
public void setProtection(boolean protect)
|
public void setProtection(boolean protect)
|
||||||
{
|
{
|
||||||
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
||||||
@@ -3904,7 +3900,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set protection from agro mobs when getting up from fake death, according settings.
|
* Set protection from aggro mobs when getting up from fake death, according settings.
|
||||||
* @param protect
|
* @param protect
|
||||||
*/
|
*/
|
||||||
public void setRecentFakeDeath(boolean protect)
|
public void setRecentFakeDeath(boolean protect)
|
||||||
@@ -6185,7 +6181,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
@Override
|
@Override
|
||||||
public boolean isInvul()
|
public boolean isInvul()
|
||||||
{
|
{
|
||||||
return super.isInvul() || (_teleportProtectEndTime > GameTimeController.getInstance().getGameTicks());
|
return super.isInvul() || isTeleportProtected();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -10276,8 +10272,8 @@ public final class L2PcInstance extends L2Playable
|
|||||||
{
|
{
|
||||||
if (isSpawnProtected())
|
if (isSpawnProtected())
|
||||||
{
|
{
|
||||||
|
setProtection(false);
|
||||||
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
||||||
|
|
||||||
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
||||||
{
|
{
|
||||||
CharSummonTable.getInstance().restoreServitor(this);
|
CharSummonTable.getInstance().restoreServitor(this);
|
||||||
@@ -10289,10 +10285,9 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
if (isTeleportProtected())
|
if (isTeleportProtected())
|
||||||
{
|
{
|
||||||
|
setTeleportProtection(false);
|
||||||
sendMessage("Teleport spawn protection ended.");
|
sendMessage("Teleport spawn protection ended.");
|
||||||
}
|
}
|
||||||
setProtection(false);
|
|
||||||
setTeleportProtection(false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+6
@@ -157,5 +157,11 @@ public class MoveBackwardToLocation implements IClientIncomingPacket
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Mobius: Check spawn protections.
|
||||||
|
if (activeChar.isSpawnProtected() || activeChar.isTeleportProtected())
|
||||||
|
{
|
||||||
|
activeChar.onActionRequest();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+5
-10
@@ -682,7 +682,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
|
|
||||||
public boolean isSpawnProtected()
|
public boolean isSpawnProtected()
|
||||||
{
|
{
|
||||||
return false; // TODO this is bugged. _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
return _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
||||||
}
|
}
|
||||||
|
|
||||||
private long _teleportProtectEndTime = 0;
|
private long _teleportProtectEndTime = 0;
|
||||||
@@ -3881,10 +3881,6 @@ public final class L2PcInstance extends L2Playable
|
|||||||
return item;
|
return item;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Set _protectEndTime according settings.
|
|
||||||
* @param protect
|
|
||||||
*/
|
|
||||||
public void setProtection(boolean protect)
|
public void setProtection(boolean protect)
|
||||||
{
|
{
|
||||||
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
||||||
@@ -3906,7 +3902,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set protection from agro mobs when getting up from fake death, according settings.
|
* Set protection from aggro mobs when getting up from fake death, according settings.
|
||||||
* @param protect
|
* @param protect
|
||||||
*/
|
*/
|
||||||
public void setRecentFakeDeath(boolean protect)
|
public void setRecentFakeDeath(boolean protect)
|
||||||
@@ -6187,7 +6183,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
@Override
|
@Override
|
||||||
public boolean isInvul()
|
public boolean isInvul()
|
||||||
{
|
{
|
||||||
return super.isInvul() || (_teleportProtectEndTime > GameTimeController.getInstance().getGameTicks());
|
return super.isInvul() || isTeleportProtected();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -10286,8 +10282,8 @@ public final class L2PcInstance extends L2Playable
|
|||||||
{
|
{
|
||||||
if (isSpawnProtected())
|
if (isSpawnProtected())
|
||||||
{
|
{
|
||||||
|
setProtection(false);
|
||||||
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
||||||
|
|
||||||
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
||||||
{
|
{
|
||||||
CharSummonTable.getInstance().restoreServitor(this);
|
CharSummonTable.getInstance().restoreServitor(this);
|
||||||
@@ -10299,10 +10295,9 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
if (isTeleportProtected())
|
if (isTeleportProtected())
|
||||||
{
|
{
|
||||||
|
setTeleportProtection(false);
|
||||||
sendMessage("Teleport spawn protection ended.");
|
sendMessage("Teleport spawn protection ended.");
|
||||||
}
|
}
|
||||||
setProtection(false);
|
|
||||||
setTeleportProtection(false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+6
@@ -157,5 +157,11 @@ public class MoveBackwardToLocation implements IClientIncomingPacket
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Mobius: Check spawn protections.
|
||||||
|
if (activeChar.isSpawnProtected() || activeChar.isTeleportProtected())
|
||||||
|
{
|
||||||
|
activeChar.onActionRequest();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+5
-10
@@ -685,7 +685,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
|
|
||||||
public boolean isSpawnProtected()
|
public boolean isSpawnProtected()
|
||||||
{
|
{
|
||||||
return false; // TODO this is bugged. _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
return _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
||||||
}
|
}
|
||||||
|
|
||||||
private long _teleportProtectEndTime = 0;
|
private long _teleportProtectEndTime = 0;
|
||||||
@@ -3872,10 +3872,6 @@ public final class L2PcInstance extends L2Playable
|
|||||||
return item;
|
return item;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Set _protectEndTime according settings.
|
|
||||||
* @param protect
|
|
||||||
*/
|
|
||||||
public void setProtection(boolean protect)
|
public void setProtection(boolean protect)
|
||||||
{
|
{
|
||||||
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
||||||
@@ -3897,7 +3893,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set protection from agro mobs when getting up from fake death, according settings.
|
* Set protection from aggro mobs when getting up from fake death, according settings.
|
||||||
* @param protect
|
* @param protect
|
||||||
*/
|
*/
|
||||||
public void setRecentFakeDeath(boolean protect)
|
public void setRecentFakeDeath(boolean protect)
|
||||||
@@ -6184,7 +6180,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
@Override
|
@Override
|
||||||
public boolean isInvul()
|
public boolean isInvul()
|
||||||
{
|
{
|
||||||
return super.isInvul() || (_teleportProtectEndTime > GameTimeController.getInstance().getGameTicks());
|
return super.isInvul() || isTeleportProtected();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -10279,8 +10275,8 @@ public final class L2PcInstance extends L2Playable
|
|||||||
{
|
{
|
||||||
if (isSpawnProtected())
|
if (isSpawnProtected())
|
||||||
{
|
{
|
||||||
|
setProtection(false);
|
||||||
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
||||||
|
|
||||||
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
||||||
{
|
{
|
||||||
CharSummonTable.getInstance().restoreServitor(this);
|
CharSummonTable.getInstance().restoreServitor(this);
|
||||||
@@ -10292,10 +10288,9 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
if (isTeleportProtected())
|
if (isTeleportProtected())
|
||||||
{
|
{
|
||||||
|
setTeleportProtection(false);
|
||||||
sendMessage("Teleport spawn protection ended.");
|
sendMessage("Teleport spawn protection ended.");
|
||||||
}
|
}
|
||||||
setProtection(false);
|
|
||||||
setTeleportProtection(false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+6
@@ -157,5 +157,11 @@ public class MoveBackwardToLocation implements IClientIncomingPacket
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Mobius: Check spawn protections.
|
||||||
|
if (activeChar.isSpawnProtected() || activeChar.isTeleportProtected())
|
||||||
|
{
|
||||||
|
activeChar.onActionRequest();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+5
-10
@@ -677,7 +677,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
|
|
||||||
public boolean isSpawnProtected()
|
public boolean isSpawnProtected()
|
||||||
{
|
{
|
||||||
return false; // TODO this is bugged. _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
return _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
||||||
}
|
}
|
||||||
|
|
||||||
private long _teleportProtectEndTime = 0;
|
private long _teleportProtectEndTime = 0;
|
||||||
@@ -3849,10 +3849,6 @@ public final class L2PcInstance extends L2Playable
|
|||||||
return item;
|
return item;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Set _protectEndTime according settings.
|
|
||||||
* @param protect
|
|
||||||
*/
|
|
||||||
public void setProtection(boolean protect)
|
public void setProtection(boolean protect)
|
||||||
{
|
{
|
||||||
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
||||||
@@ -3874,7 +3870,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set protection from agro mobs when getting up from fake death, according settings.
|
* Set protection from aggro mobs when getting up from fake death, according settings.
|
||||||
* @param protect
|
* @param protect
|
||||||
*/
|
*/
|
||||||
public void setRecentFakeDeath(boolean protect)
|
public void setRecentFakeDeath(boolean protect)
|
||||||
@@ -6155,7 +6151,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
@Override
|
@Override
|
||||||
public boolean isInvul()
|
public boolean isInvul()
|
||||||
{
|
{
|
||||||
return super.isInvul() || (_teleportProtectEndTime > GameTimeController.getInstance().getGameTicks());
|
return super.isInvul() || isTeleportProtected();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -10214,8 +10210,8 @@ public final class L2PcInstance extends L2Playable
|
|||||||
{
|
{
|
||||||
if (isSpawnProtected())
|
if (isSpawnProtected())
|
||||||
{
|
{
|
||||||
|
setProtection(false);
|
||||||
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
||||||
|
|
||||||
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
||||||
{
|
{
|
||||||
CharSummonTable.getInstance().restoreServitor(this);
|
CharSummonTable.getInstance().restoreServitor(this);
|
||||||
@@ -10227,10 +10223,9 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
if (isTeleportProtected())
|
if (isTeleportProtected())
|
||||||
{
|
{
|
||||||
|
setTeleportProtection(false);
|
||||||
sendMessage("Teleport spawn protection ended.");
|
sendMessage("Teleport spawn protection ended.");
|
||||||
}
|
}
|
||||||
setProtection(false);
|
|
||||||
setTeleportProtection(false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+6
@@ -157,5 +157,11 @@ public class MoveBackwardToLocation implements IClientIncomingPacket
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Mobius: Check spawn protections.
|
||||||
|
if (activeChar.isSpawnProtected() || activeChar.isTeleportProtected())
|
||||||
|
{
|
||||||
|
activeChar.onActionRequest();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+5
-10
@@ -677,7 +677,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
|
|
||||||
public boolean isSpawnProtected()
|
public boolean isSpawnProtected()
|
||||||
{
|
{
|
||||||
return false; // TODO this is bugged. _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
return _protectEndTime > GameTimeController.getInstance().getGameTicks();
|
||||||
}
|
}
|
||||||
|
|
||||||
private long _teleportProtectEndTime = 0;
|
private long _teleportProtectEndTime = 0;
|
||||||
@@ -3849,10 +3849,6 @@ public final class L2PcInstance extends L2Playable
|
|||||||
return item;
|
return item;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Set _protectEndTime according settings.
|
|
||||||
* @param protect
|
|
||||||
*/
|
|
||||||
public void setProtection(boolean protect)
|
public void setProtection(boolean protect)
|
||||||
{
|
{
|
||||||
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
|
||||||
@@ -3874,7 +3870,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set protection from agro mobs when getting up from fake death, according settings.
|
* Set protection from aggro mobs when getting up from fake death, according settings.
|
||||||
* @param protect
|
* @param protect
|
||||||
*/
|
*/
|
||||||
public void setRecentFakeDeath(boolean protect)
|
public void setRecentFakeDeath(boolean protect)
|
||||||
@@ -6155,7 +6151,7 @@ public final class L2PcInstance extends L2Playable
|
|||||||
@Override
|
@Override
|
||||||
public boolean isInvul()
|
public boolean isInvul()
|
||||||
{
|
{
|
||||||
return super.isInvul() || (_teleportProtectEndTime > GameTimeController.getInstance().getGameTicks());
|
return super.isInvul() || isTeleportProtected();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -10214,8 +10210,8 @@ public final class L2PcInstance extends L2Playable
|
|||||||
{
|
{
|
||||||
if (isSpawnProtected())
|
if (isSpawnProtected())
|
||||||
{
|
{
|
||||||
|
setProtection(false);
|
||||||
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
sendPacket(SystemMessageId.YOU_ARE_NO_LONGER_PROTECTED_FROM_AGGRESSIVE_MONSTERS);
|
||||||
|
|
||||||
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
if (Config.RESTORE_SERVITOR_ON_RECONNECT && !hasSummon() && CharSummonTable.getInstance().getServitors().containsKey(getObjectId()))
|
||||||
{
|
{
|
||||||
CharSummonTable.getInstance().restoreServitor(this);
|
CharSummonTable.getInstance().restoreServitor(this);
|
||||||
@@ -10227,10 +10223,9 @@ public final class L2PcInstance extends L2Playable
|
|||||||
}
|
}
|
||||||
if (isTeleportProtected())
|
if (isTeleportProtected())
|
||||||
{
|
{
|
||||||
|
setTeleportProtection(false);
|
||||||
sendMessage("Teleport spawn protection ended.");
|
sendMessage("Teleport spawn protection ended.");
|
||||||
}
|
}
|
||||||
setProtection(false);
|
|
||||||
setTeleportProtection(false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+6
@@ -157,5 +157,11 @@ public class MoveBackwardToLocation implements IClientIncomingPacket
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Mobius: Check spawn protections.
|
||||||
|
if (activeChar.isSpawnProtected() || activeChar.isTeleportProtected())
|
||||||
|
{
|
||||||
|
activeChar.onActionRequest();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user