From c0184f6233965b219ebb955137165de5ebf36a04 Mon Sep 17 00:00:00 2001 From: MobiusDevelopment <8391001+MobiusDevelopment@users.noreply.github.com> Date: Fri, 15 Mar 2019 13:12:17 +0000 Subject: [PATCH] Dimensional Blessing addition. Contributed by Iris and quangnguyen. --- .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/skills/documentation.txt | 1 + .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/skills/documentation.txt | 1 + .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/skills/documentation.txt | 1 + .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/skills/documentation.txt | 1 + .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/skills/documentation.txt | 1 + .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/skills/documentation.txt | 1 + .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/skills/documentation.txt | 1 + .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/items/90000-90099.xml | 18 +- .../game/data/stats/skills/39200-39299.xml | 89 ++++- .../game/data/stats/skills/documentation.txt | 1 + .../dist/game/data/xsd/skills.xsd | 15 + .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/items/90000-90099.xml | 18 +- .../game/data/stats/skills/39200-39299.xml | 89 ++++- .../game/data/stats/skills/documentation.txt | 1 + .../dist/game/data/xsd/skills.xsd | 15 + .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/items/90000-90099.xml | 18 +- .../game/data/stats/skills/39200-39299.xml | 89 ++++- .../game/data/stats/skills/documentation.txt | 1 + .../dist/game/data/xsd/skills.xsd | 307 +++++++++--------- .../scripts/handlers/EffectMasterHandler.java | 1 + .../handlers/effecthandlers/GiveExpAndSp.java | 70 ++++ .../game/data/stats/items/90000-90099.xml | 18 +- .../game/data/stats/skills/39200-39299.xml | 89 ++++- .../game/data/stats/skills/documentation.txt | 1 + .../dist/game/data/xsd/skills.xsd | 307 +++++++++--------- 45 files changed, 1540 insertions(+), 324 deletions(-) create mode 100644 L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_Classic_2.1_Zaken/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_Classic_2.2_Antharas/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java create mode 100644 L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/EffectMasterHandler.java index 95ef4fdf30..f6a548186c 100644 --- a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -148,6 +148,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_1.0_Ertheia/dist/game/data/stats/skills/documentation.txt index 40e7528e10..16a19b6c06 100644 --- a/L2J_Mobius_1.0_Ertheia/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_1.0_Ertheia/dist/game/data/stats/skills/documentation.txt @@ -118,6 +118,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/EffectMasterHandler.java index 95ef4fdf30..f6a548186c 100644 --- a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -148,6 +148,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_2.5_Underground/dist/game/data/stats/skills/documentation.txt index 40e7528e10..16a19b6c06 100644 --- a/L2J_Mobius_2.5_Underground/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_2.5_Underground/dist/game/data/stats/skills/documentation.txt @@ -118,6 +118,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/EffectMasterHandler.java index 95ef4fdf30..f6a548186c 100644 --- a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -148,6 +148,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_3.0_Helios/dist/game/data/stats/skills/documentation.txt index 40e7528e10..16a19b6c06 100644 --- a/L2J_Mobius_3.0_Helios/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_3.0_Helios/dist/game/data/stats/skills/documentation.txt @@ -118,6 +118,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/EffectMasterHandler.java index 90372275fa..b1c0190b2d 100644 --- a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -152,6 +152,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/stats/skills/documentation.txt index b7a874a364..474bb4fa89 100644 --- a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/stats/skills/documentation.txt @@ -122,6 +122,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/EffectMasterHandler.java index fc3f8ace61..24c491705c 100644 --- a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -155,6 +155,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_5.0_Salvation/dist/game/data/stats/skills/documentation.txt index dc230c75af..9626945b75 100644 --- a/L2J_Mobius_5.0_Salvation/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_5.0_Salvation/dist/game/data/stats/skills/documentation.txt @@ -125,6 +125,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/EffectMasterHandler.java index 10ab12269f..bf2ca853d9 100644 --- a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -156,6 +156,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_5.5_EtinasFate/dist/game/data/stats/skills/documentation.txt index 71822d60f2..2a13b19789 100644 --- a/L2J_Mobius_5.5_EtinasFate/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/stats/skills/documentation.txt @@ -126,6 +126,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/EffectMasterHandler.java index 10ab12269f..bf2ca853d9 100644 --- a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -156,6 +156,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_6.0_Fafurion/dist/game/data/stats/skills/documentation.txt index 71822d60f2..2a13b19789 100644 --- a/L2J_Mobius_6.0_Fafurion/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/stats/skills/documentation.txt @@ -126,6 +126,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/EffectMasterHandler.java index adc79c4e91..aea7146792 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -147,6 +147,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/items/90000-90099.xml b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/items/90000-90099.xml index c2b40f86cc..6c0bebab5b 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/items/90000-90099.xml +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/items/90000-90099.xml @@ -448,24 +448,38 @@ + - + + + + + + + - + + + + + + + + diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/skills/39200-39299.xml b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/skills/39200-39299.xml index e281a96fd0..fb80a1c7d8 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/skills/39200-39299.xml +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/skills/39200-39299.xml @@ -44,12 +44,97 @@ icon.BranchSys.icon.br_lucky_bag_i00 - A1 + 200 + 2 + 1 + 90044 + 1 + A1 + 1000 + 5 + 0 + SELF + SINGLE + + + + 37000000 + + + 1110000 + + + icon.empty_bottle - A1 + 1 + 900 + CHANGEBODY + DARK_ASSASSIN_SUIT + true + 1 + 4 + 56 + A2 + 900000 + 600 + true + true + NONE + 5 + 0 + SELF + SINGLE + 90043 + 1 + + + 5 + PER + + + 5 + PER + + + 4 + DIFF + + + 3 + PER + + + 1 + DIFF + + + 1 + DIFF + + + 10 + DIFF + + + 2 + PER + + + 2 + PER + + + 2 + PER + + + 2 + PER + + diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/skills/documentation.txt index 70730cd225..dccc51036a 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/stats/skills/documentation.txt @@ -117,6 +117,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/xsd/skills.xsd b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/xsd/skills.xsd index 5124275fcc..2d6f7d73bf 100644 --- a/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/xsd/skills.xsd +++ b/L2J_Mobius_Classic_2.0_Saviors/dist/game/data/xsd/skills.xsd @@ -1447,6 +1447,21 @@ + + + + + + + + + + + + + + + diff --git a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/scripts/handlers/EffectMasterHandler.java index adc79c4e91..aea7146792 100644 --- a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -147,6 +147,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/items/90000-90099.xml b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/items/90000-90099.xml index 1e5f2e1a3c..c7d2a9ea8c 100644 --- a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/items/90000-90099.xml +++ b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/items/90000-90099.xml @@ -448,24 +448,38 @@ + - + + + + + + + - + + + + + + + + diff --git a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/skills/39200-39299.xml b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/skills/39200-39299.xml index 67919f1f07..eac05252f1 100644 --- a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/skills/39200-39299.xml +++ b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/skills/39200-39299.xml @@ -44,12 +44,97 @@ icon.BranchSys.icon.br_lucky_bag_i00 - A1 + 200 + 2 + 1 + 90044 + 1 + A1 + 1000 + 5 + 0 + SELF + SINGLE + + + + 37000000 + + + 1110000 + + + icon.empty_bottle - A1 + 1 + 900 + CHANGEBODY + DARK_ASSASSIN_SUIT + true + 1 + 4 + 56 + A2 + 900000 + 600 + true + true + NONE + 5 + 0 + SELF + SINGLE + 90043 + 1 + + + 5 + PER + + + 5 + PER + + + 4 + DIFF + + + 3 + PER + + + 1 + DIFF + + + 1 + DIFF + + + 10 + DIFF + + + 2 + PER + + + 2 + PER + + + 2 + PER + + + 2 + PER + + diff --git a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/skills/documentation.txt index 70730cd225..dccc51036a 100644 --- a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/stats/skills/documentation.txt @@ -117,6 +117,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/xsd/skills.xsd b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/xsd/skills.xsd index 5124275fcc..2d6f7d73bf 100644 --- a/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/xsd/skills.xsd +++ b/L2J_Mobius_Classic_2.1_Zaken/dist/game/data/xsd/skills.xsd @@ -1447,6 +1447,21 @@ + + + + + + + + + + + + + + + diff --git a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/scripts/handlers/EffectMasterHandler.java index a07217a390..24d4f6b16c 100644 --- a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -148,6 +148,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/items/90000-90099.xml b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/items/90000-90099.xml index 20d68b5465..693a70b740 100644 --- a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/items/90000-90099.xml +++ b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/items/90000-90099.xml @@ -448,24 +448,38 @@ + - + + + + + + + - + + + + + + + + diff --git a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/skills/39200-39299.xml b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/skills/39200-39299.xml index 32cd9a8e52..70a7e793fb 100644 --- a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/skills/39200-39299.xml +++ b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/skills/39200-39299.xml @@ -44,12 +44,97 @@ icon.BranchSys.icon.br_lucky_bag_i00 - A1 + 200 + 2 + 1 + 90044 + 1 + A1 + 1000 + 5 + 0 + SELF + SINGLE + + + + 37000000 + + + 1110000 + + + icon.empty_bottle - A1 + 1 + 900 + CHANGEBODY + DARK_ASSASSIN_SUIT + true + 1 + 4 + 56 + A2 + 900000 + 600 + true + true + NONE + 5 + 0 + SELF + SINGLE + 90043 + 1 + + + 5 + PER + + + 5 + PER + + + 4 + DIFF + + + 3 + PER + + + 1 + DIFF + + + 1 + DIFF + + + 10 + DIFF + + + 2 + PER + + + 2 + PER + + + 2 + PER + + + 2 + PER + + diff --git a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/skills/documentation.txt index 7cf045f300..4d68e11b56 100644 --- a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/stats/skills/documentation.txt @@ -118,6 +118,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/xsd/skills.xsd b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/xsd/skills.xsd index 06926ed280..b2f6e616e1 100644 --- a/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/xsd/skills.xsd +++ b/L2J_Mobius_Classic_2.2_Antharas/dist/game/data/xsd/skills.xsd @@ -7,7 +7,7 @@ - + @@ -22,23 +22,6 @@ - - - - - - - - - - - - - - - - - @@ -88,6 +71,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -148,7 +165,6 @@ - @@ -164,66 +180,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -239,6 +195,21 @@ + + + + + + + + + + + + + + + @@ -315,21 +286,6 @@ - - - - - - - - - - - - - - - @@ -376,7 +332,6 @@ - @@ -429,8 +384,8 @@ + - @@ -470,7 +425,6 @@ - @@ -493,6 +447,21 @@ + + + + + + + + + + + + + + + @@ -513,21 +482,6 @@ - - - - - - - - - - - - - - - @@ -681,7 +635,7 @@ - + @@ -1014,7 +968,6 @@ - @@ -1478,6 +1431,7 @@ + @@ -1488,21 +1442,6 @@ - - - - - - - - - - - - - - - @@ -1524,6 +1463,7 @@ + @@ -1532,7 +1472,21 @@ - + + + + + + + + + + + + + + + @@ -1547,22 +1501,6 @@ - - - - - - - - - - - - - - - - @@ -1578,18 +1516,14 @@ - + - - - - - + @@ -1597,6 +1531,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -1767,7 +1766,7 @@ - + @@ -1851,7 +1850,7 @@ - + diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/scripts/handlers/EffectMasterHandler.java b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/scripts/handlers/EffectMasterHandler.java index 70422edf7c..5efa1d3edd 100644 --- a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/scripts/handlers/EffectMasterHandler.java +++ b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/scripts/handlers/EffectMasterHandler.java @@ -149,6 +149,7 @@ public final class EffectMasterHandler EffectHandler.getInstance().registerHandler("GetDamageLimit", GetDamageLimit::new); EffectHandler.getInstance().registerHandler("GetMomentum", GetMomentum::new); EffectHandler.getInstance().registerHandler("GiveClanReputation", GiveClanReputation::new); + EffectHandler.getInstance().registerHandler("GiveExpAndSp", GiveExpAndSp::new); EffectHandler.getInstance().registerHandler("GiveFame", GiveFame::new); EffectHandler.getInstance().registerHandler("GiveRecommendation", GiveRecommendation::new); EffectHandler.getInstance().registerHandler("GiveSp", GiveSp::new); diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java new file mode 100644 index 0000000000..1d072109a5 --- /dev/null +++ b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/scripts/handlers/effecthandlers/GiveExpAndSp.java @@ -0,0 +1,70 @@ +/* + * 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.effecthandlers; + +import com.l2jmobius.gameserver.model.StatsSet; +import com.l2jmobius.gameserver.model.actor.L2Character; +import com.l2jmobius.gameserver.model.effects.AbstractEffect; +import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance; +import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.network.SystemMessageId; +import com.l2jmobius.gameserver.network.serverpackets.SystemMessage; + +/** + * Give XP and SP effect implementation. + * @author quangnguyen + */ +public final class GiveExpAndSp extends AbstractEffect +{ + private final int _xp; + private final int _sp; + + public GiveExpAndSp(StatsSet params) + { + _xp = params.getInt("xp", 0); + _sp = params.getInt("sp", 0); + } + + @Override + public boolean isInstant() + { + return true; + } + + @Override + public void instant(L2Character effector, L2Character effected, Skill skill, L2ItemInstance item) + { + if (!effector.isPlayer() || !effected.isPlayer() || effected.isAlikeDead()) + { + return; + } + + if ((_sp != 0) && (_xp != 0)) + { + effector.getActingPlayer().getStat().addExp(_xp); + effector.getActingPlayer().getStat().addSp(_sp); + + SystemMessage sm = null; + sm = SystemMessage.getSystemMessage(SystemMessageId.YOU_HAVE_ACQUIRED_S1_XP_BONUS_S2_AND_S3_SP_BONUS_S4); + sm.addLong(_xp); + sm.addLong(0); + sm.addLong(_sp); + sm.addLong(0); + effector.sendPacket(sm); + } + } +} \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/items/90000-90099.xml b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/items/90000-90099.xml index f44a4d5aa3..6908eadd02 100644 --- a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/items/90000-90099.xml +++ b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/items/90000-90099.xml @@ -448,24 +448,38 @@ + - + + + + + + + - + + + + + + + + diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/skills/39200-39299.xml b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/skills/39200-39299.xml index 5e9439a178..3738c6af37 100644 --- a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/skills/39200-39299.xml +++ b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/skills/39200-39299.xml @@ -44,12 +44,97 @@ icon.BranchSys.icon.br_lucky_bag_i00 - A1 + 200 + 2 + 1 + 90044 + 1 + A1 + 1000 + 5 + 0 + SELF + SINGLE + + + + 37000000 + + + 1110000 + + + icon.empty_bottle - A1 + 1 + 900 + CHANGEBODY + DARK_ASSASSIN_SUIT + true + 1 + 4 + 56 + A2 + 900000 + 600 + true + true + NONE + 5 + 0 + SELF + SINGLE + 90043 + 1 + + + 5 + PER + + + 5 + PER + + + 4 + DIFF + + + 3 + PER + + + 1 + DIFF + + + 1 + DIFF + + + 10 + DIFF + + + 2 + PER + + + 2 + PER + + + 2 + PER + + + 2 + PER + + diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/skills/documentation.txt b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/skills/documentation.txt index 51c5da9572..88dc9ce743 100644 --- a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/skills/documentation.txt +++ b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/stats/skills/documentation.txt @@ -119,6 +119,7 @@ GetAgro: Causes enemy NPC to attack you. GetDamageLimit: Sets the maximum amount of damage you can receive. GetMomentum: Increases momentum by a given value at fixed rate. GiveClanReputation: Gives clan reputation points to a players clan. (l2jmobius) +GiveExpAndSp: Gives a given amount of XP and SP. (l2jmobius) GiveFame: Gives a given amount of Fame. (l2jmobius) GiveRecommendation: Gives recommendations to a player. Blue name. GiveSp: Gives a given amount of SP. diff --git a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/xsd/skills.xsd b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/xsd/skills.xsd index 06926ed280..b2f6e616e1 100644 --- a/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/xsd/skills.xsd +++ b/L2J_Mobius_Classic_2.3_SevenSigns/dist/game/data/xsd/skills.xsd @@ -7,7 +7,7 @@ - + @@ -22,23 +22,6 @@ - - - - - - - - - - - - - - - - - @@ -88,6 +71,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -148,7 +165,6 @@ - @@ -164,66 +180,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -239,6 +195,21 @@ + + + + + + + + + + + + + + + @@ -315,21 +286,6 @@ - - - - - - - - - - - - - - - @@ -376,7 +332,6 @@ - @@ -429,8 +384,8 @@ + - @@ -470,7 +425,6 @@ - @@ -493,6 +447,21 @@ + + + + + + + + + + + + + + + @@ -513,21 +482,6 @@ - - - - - - - - - - - - - - - @@ -681,7 +635,7 @@ - + @@ -1014,7 +968,6 @@ - @@ -1478,6 +1431,7 @@ + @@ -1488,21 +1442,6 @@ - - - - - - - - - - - - - - - @@ -1524,6 +1463,7 @@ + @@ -1532,7 +1472,21 @@ - + + + + + + + + + + + + + + + @@ -1547,22 +1501,6 @@ - - - - - - - - - - - - - - - - @@ -1578,18 +1516,14 @@ - + - - - - - + @@ -1597,6 +1531,71 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -1767,7 +1766,7 @@ - + @@ -1851,7 +1850,7 @@ - +