From 9b9e718efa0d57ba3f9c0c044b127dfcb25f458e Mon Sep 17 00:00:00 2001 From: MobiusDev <8391001+MobiusDevelopment@users.noreply.github.com> Date: Sat, 24 Nov 2018 23:48:07 +0000 Subject: [PATCH] Use restoreExp method for RequestRestartPoint experience restoration. --- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- .../gameserver/network/clientpackets/RequestRestartPoint.java | 4 ++-- 10 files changed, 20 insertions(+), 20 deletions(-) diff --git a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_1.0_Ertheia/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break; diff --git a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_2.5_Underground/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break; diff --git a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_3.0_Helios/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break; diff --git a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_4.0_GrandCrusade/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break; diff --git a/L2J_Mobius_5.0_Salvation/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_5.0_Salvation/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_5.0_Salvation/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_5.0_Salvation/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break; diff --git a/L2J_Mobius_5.5_EtinasFate/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_5.5_EtinasFate/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_5.5_EtinasFate/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_5.5_EtinasFate/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break; diff --git a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_Classic_2.0_Saviors/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break; diff --git a/L2J_Mobius_Classic_2.1_Zaken/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_Classic_2.1_Zaken/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_Classic_2.1_Zaken/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_Classic_2.1_Zaken/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break; diff --git a/L2J_Mobius_Classic_2.2_Antharas/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_Classic_2.2_Antharas/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_Classic_2.2_Antharas/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_Classic_2.2_Antharas/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break; diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java b/L2J_Mobius_Classic_2.3_SevenSigns/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java index 541c32f93c..696d1e077a 100644 --- a/L2J_Mobius_Classic_2.3_SevenSigns/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java +++ b/L2J_Mobius_Classic_2.3_SevenSigns/java/com/l2jmobius/gameserver/network/clientpackets/RequestRestartPoint.java @@ -195,7 +195,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final CastleFunction castleFunction = castle.getCastleFunction(Castle.FUNC_RESTORE_EXP); if (castleFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * castleFunction.getLvl()) / 100)); + activeChar.restoreExp(castleFunction.getLvl()); } } } @@ -217,7 +217,7 @@ public final class RequestRestartPoint implements IClientIncomingPacket final FortFunction fortFunction = fort.getFortFunction(Fort.FUNC_RESTORE_EXP); if (fortFunction != null) { - activeChar.getStat().addExp(Math.round(((activeChar.getExpBeforeDeath() - activeChar.getExp()) * fortFunction.getLvl()) / 100)); + activeChar.restoreExp(fortFunction.getLvl()); } } break;