Skip to content
Snippets Groups Projects
Commit 0956641a authored by HorridoJoho's avatar HorridoJoho Committed by Christian
Browse files

Working on effects.

+ Added BonusCountUp effect
* Renamed and moved NevitsHourglass effect to BonusTimeLimitUp
* Modified EffectMasterHandler
parent 3b127d05
No related branches found
No related tags found
No related merge requests found
......@@ -53,6 +53,7 @@ import com.l2jserver.datapack.handlers.effecthandlers.pump.BlockDamage;
import com.l2jserver.datapack.handlers.effecthandlers.pump.BlockDebuff;
import com.l2jserver.datapack.handlers.effecthandlers.pump.BlockParty;
import com.l2jserver.datapack.handlers.effecthandlers.pump.BlockResurrection;
import com.l2jserver.datapack.handlers.effecthandlers.pump.BonusTimeLimitUp;
import com.l2jserver.datapack.handlers.effecthandlers.pump.ChangeFishingMastery;
import com.l2jserver.datapack.handlers.effecthandlers.pump.CrystalGradeModify;
import com.l2jserver.datapack.handlers.effecthandlers.pump.CubicMastery;
......@@ -193,7 +194,8 @@ public final class EffectMasterHandler {
Mp.class,
MpPerMax.class,
Mute.class,
NevitHourglass.class,
BonusCountUp.class,
BonusTimeLimitUp.class,
NoblesseBless.class,
OpenChest.class,
OpenCommonRecipeBook.class,
......
/*
* Copyright © 2004-2021 L2J DataPack
*
* This file is part of L2J DataPack.
*
* L2J DataPack 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.
*
* L2J DataPack 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 <http://www.gnu.org/licenses/>.
*/
package com.l2jserver.datapack.handlers.effecthandlers.instant;
import com.l2jserver.gameserver.model.StatsSet;
import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
import com.l2jserver.gameserver.model.conditions.Condition;
import com.l2jserver.gameserver.model.effects.AbstractEffect;
import com.l2jserver.gameserver.model.skills.BuffInfo;
/**
* This effect instantly raises recommendations to give out by the specified count.
* @author HorridoJoho
* @since 2.6.3.0
*/
public class BonusCountUp extends AbstractEffect {
private final int _count;
protected BonusCountUp(Condition attachCond, Condition applyCond, StatsSet set, StatsSet params) {
super(attachCond, applyCond, set, params);
_count = set.getInt("count", 0);
}
@Override
public void onStart(BuffInfo info) {
super.onStart(info);
L2PcInstance player = info.getEffected().getActingPlayer();
if (player != null)
{
player.setRecomLeft(player.getRecomLeft() + _count);
}
}
@Override
public boolean isInstant() {
return true;
}
}
/*
* Copyright © 2004-2021 L2J DataPack
* Copyright © 2004-2021 L2J DataPack
*
* This file is part of L2J DataPack.
*
......@@ -16,7 +16,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.l2jserver.datapack.handlers.effecthandlers.instant;
package com.l2jserver.datapack.handlers.effecthandlers.pump;
import com.l2jserver.gameserver.model.StatsSet;
import com.l2jserver.gameserver.model.conditions.Condition;
......@@ -31,15 +31,12 @@ import com.l2jserver.gameserver.network.serverpackets.UserInfo;
* @author Maneco2
* @since 2.6.3.0
*/
public final class NevitHourglass extends AbstractEffect {
public final class BonusTimeLimitUp extends AbstractEffect {
private final int _time;
public NevitHourglass(Condition attachCond, Condition applyCond, StatsSet set, StatsSet params) {
public BonusTimeLimitUp(Condition attachCond, Condition applyCond, StatsSet set, StatsSet params) {
super(attachCond, applyCond, set, params);
}
@Override
public boolean isInstant() {
return true;
_time = set.getInt("time", 0);
}
@Override
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment