From 0d88776290792fd067c12e4eaa5789b48e3ca70b Mon Sep 17 00:00:00 2001 From: MobiusDevelopment <8391001+MobiusDevelopment@users.noreply.github.com> Date: Thu, 10 Oct 2019 10:18:01 +0000 Subject: [PATCH] Addition of OpNotInCeremonyOfChaos skill condition. --- .../handlers/SkillConditionMasterHandler.java | 1 + .../OpNotInCeremonyOfChaosSkillCondition.java | 40 +++++++++++++++++++ .../handlers/SkillConditionMasterHandler.java | 1 + .../OpNotInCeremonyOfChaosSkillCondition.java | 40 +++++++++++++++++++ .../handlers/SkillConditionMasterHandler.java | 1 + .../OpNotInCeremonyOfChaosSkillCondition.java | 40 +++++++++++++++++++ .../handlers/SkillConditionMasterHandler.java | 1 + .../OpNotInCeremonyOfChaosSkillCondition.java | 40 +++++++++++++++++++ .../handlers/SkillConditionMasterHandler.java | 1 + .../OpNotInCeremonyOfChaosSkillCondition.java | 40 +++++++++++++++++++ .../handlers/SkillConditionMasterHandler.java | 1 + .../OpNotInCeremonyOfChaosSkillCondition.java | 40 +++++++++++++++++++ .../handlers/SkillConditionMasterHandler.java | 1 + .../OpNotInCeremonyOfChaosSkillCondition.java | 40 +++++++++++++++++++ .../handlers/SkillConditionMasterHandler.java | 1 + .../OpNotInCeremonyOfChaosSkillCondition.java | 40 +++++++++++++++++++ 16 files changed, 328 insertions(+) create mode 100644 L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java create mode 100644 L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java create mode 100644 L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java create mode 100644 L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java create mode 100644 L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java create mode 100644 L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java create mode 100644 L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java create mode 100644 L2J_Mobius_7.0_PreludeOfWar/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java index 6e46f1e46c..266581076b 100644 --- a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java +++ b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java @@ -136,5 +136,6 @@ public class SkillConditionMasterHandler SkillConditionHandler.getInstance().registerHandler("OpTargetMyPledgeAcademy", OpTargetMyPledgeAcademySkillCondition::new); SkillConditionHandler.getInstance().registerHandler("OpCheckFlag", OpCheckFlagSkillCondition::new); SkillConditionHandler.getInstance().registerHandler("NotFeared", NotFearedSkillCondition::new); + SkillConditionHandler.getInstance().registerHandler("OpNotInCeremonyOfChaos", OpNotInCeremonyOfChaosSkillCondition::new); } } diff --git a/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java new file mode 100644 index 0000000000..9549fdc2ac --- /dev/null +++ b/L2J_Mobius_1.0_Ertheia/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java @@ -0,0 +1,40 @@ +/* + * 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.skillconditionhandlers; + +import org.l2jmobius.gameserver.model.StatsSet; +import org.l2jmobius.gameserver.model.WorldObject; +import org.l2jmobius.gameserver.model.actor.Creature; +import org.l2jmobius.gameserver.model.ceremonyofchaos.CeremonyOfChaosEvent; +import org.l2jmobius.gameserver.model.skills.ISkillCondition; +import org.l2jmobius.gameserver.model.skills.Skill; + +/** + * @author Mobius + */ +public class OpNotInCeremonyOfChaosSkillCondition implements ISkillCondition +{ + public OpNotInCeremonyOfChaosSkillCondition(StatsSet params) + { + } + + @Override + public boolean canUse(Creature caster, Skill skill, WorldObject target) + { + return (caster.isPlayer() && !caster.getActingPlayer().isOnEvent(CeremonyOfChaosEvent.class)); + } +} diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java index 6e46f1e46c..266581076b 100644 --- a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java +++ b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java @@ -136,5 +136,6 @@ public class SkillConditionMasterHandler SkillConditionHandler.getInstance().registerHandler("OpTargetMyPledgeAcademy", OpTargetMyPledgeAcademySkillCondition::new); SkillConditionHandler.getInstance().registerHandler("OpCheckFlag", OpCheckFlagSkillCondition::new); SkillConditionHandler.getInstance().registerHandler("NotFeared", NotFearedSkillCondition::new); + SkillConditionHandler.getInstance().registerHandler("OpNotInCeremonyOfChaos", OpNotInCeremonyOfChaosSkillCondition::new); } } diff --git a/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java new file mode 100644 index 0000000000..9549fdc2ac --- /dev/null +++ b/L2J_Mobius_2.5_Underground/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java @@ -0,0 +1,40 @@ +/* + * 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.skillconditionhandlers; + +import org.l2jmobius.gameserver.model.StatsSet; +import org.l2jmobius.gameserver.model.WorldObject; +import org.l2jmobius.gameserver.model.actor.Creature; +import org.l2jmobius.gameserver.model.ceremonyofchaos.CeremonyOfChaosEvent; +import org.l2jmobius.gameserver.model.skills.ISkillCondition; +import org.l2jmobius.gameserver.model.skills.Skill; + +/** + * @author Mobius + */ +public class OpNotInCeremonyOfChaosSkillCondition implements ISkillCondition +{ + public OpNotInCeremonyOfChaosSkillCondition(StatsSet params) + { + } + + @Override + public boolean canUse(Creature caster, Skill skill, WorldObject target) + { + return (caster.isPlayer() && !caster.getActingPlayer().isOnEvent(CeremonyOfChaosEvent.class)); + } +} diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java index 6e46f1e46c..266581076b 100644 --- a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java +++ b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java @@ -136,5 +136,6 @@ public class SkillConditionMasterHandler SkillConditionHandler.getInstance().registerHandler("OpTargetMyPledgeAcademy", OpTargetMyPledgeAcademySkillCondition::new); SkillConditionHandler.getInstance().registerHandler("OpCheckFlag", OpCheckFlagSkillCondition::new); SkillConditionHandler.getInstance().registerHandler("NotFeared", NotFearedSkillCondition::new); + SkillConditionHandler.getInstance().registerHandler("OpNotInCeremonyOfChaos", OpNotInCeremonyOfChaosSkillCondition::new); } } diff --git a/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java new file mode 100644 index 0000000000..9549fdc2ac --- /dev/null +++ b/L2J_Mobius_3.0_Helios/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java @@ -0,0 +1,40 @@ +/* + * 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.skillconditionhandlers; + +import org.l2jmobius.gameserver.model.StatsSet; +import org.l2jmobius.gameserver.model.WorldObject; +import org.l2jmobius.gameserver.model.actor.Creature; +import org.l2jmobius.gameserver.model.ceremonyofchaos.CeremonyOfChaosEvent; +import org.l2jmobius.gameserver.model.skills.ISkillCondition; +import org.l2jmobius.gameserver.model.skills.Skill; + +/** + * @author Mobius + */ +public class OpNotInCeremonyOfChaosSkillCondition implements ISkillCondition +{ + public OpNotInCeremonyOfChaosSkillCondition(StatsSet params) + { + } + + @Override + public boolean canUse(Creature caster, Skill skill, WorldObject target) + { + return (caster.isPlayer() && !caster.getActingPlayer().isOnEvent(CeremonyOfChaosEvent.class)); + } +} diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java index 6e46f1e46c..266581076b 100644 --- a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java +++ b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java @@ -136,5 +136,6 @@ public class SkillConditionMasterHandler SkillConditionHandler.getInstance().registerHandler("OpTargetMyPledgeAcademy", OpTargetMyPledgeAcademySkillCondition::new); SkillConditionHandler.getInstance().registerHandler("OpCheckFlag", OpCheckFlagSkillCondition::new); SkillConditionHandler.getInstance().registerHandler("NotFeared", NotFearedSkillCondition::new); + SkillConditionHandler.getInstance().registerHandler("OpNotInCeremonyOfChaos", OpNotInCeremonyOfChaosSkillCondition::new); } } diff --git a/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java new file mode 100644 index 0000000000..9549fdc2ac --- /dev/null +++ b/L2J_Mobius_4.0_GrandCrusade/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java @@ -0,0 +1,40 @@ +/* + * 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.skillconditionhandlers; + +import org.l2jmobius.gameserver.model.StatsSet; +import org.l2jmobius.gameserver.model.WorldObject; +import org.l2jmobius.gameserver.model.actor.Creature; +import org.l2jmobius.gameserver.model.ceremonyofchaos.CeremonyOfChaosEvent; +import org.l2jmobius.gameserver.model.skills.ISkillCondition; +import org.l2jmobius.gameserver.model.skills.Skill; + +/** + * @author Mobius + */ +public class OpNotInCeremonyOfChaosSkillCondition implements ISkillCondition +{ + public OpNotInCeremonyOfChaosSkillCondition(StatsSet params) + { + } + + @Override + public boolean canUse(Creature caster, Skill skill, WorldObject target) + { + return (caster.isPlayer() && !caster.getActingPlayer().isOnEvent(CeremonyOfChaosEvent.class)); + } +} diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java index 6e46f1e46c..266581076b 100644 --- a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java +++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java @@ -136,5 +136,6 @@ public class SkillConditionMasterHandler SkillConditionHandler.getInstance().registerHandler("OpTargetMyPledgeAcademy", OpTargetMyPledgeAcademySkillCondition::new); SkillConditionHandler.getInstance().registerHandler("OpCheckFlag", OpCheckFlagSkillCondition::new); SkillConditionHandler.getInstance().registerHandler("NotFeared", NotFearedSkillCondition::new); + SkillConditionHandler.getInstance().registerHandler("OpNotInCeremonyOfChaos", OpNotInCeremonyOfChaosSkillCondition::new); } } diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java new file mode 100644 index 0000000000..9549fdc2ac --- /dev/null +++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java @@ -0,0 +1,40 @@ +/* + * 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.skillconditionhandlers; + +import org.l2jmobius.gameserver.model.StatsSet; +import org.l2jmobius.gameserver.model.WorldObject; +import org.l2jmobius.gameserver.model.actor.Creature; +import org.l2jmobius.gameserver.model.ceremonyofchaos.CeremonyOfChaosEvent; +import org.l2jmobius.gameserver.model.skills.ISkillCondition; +import org.l2jmobius.gameserver.model.skills.Skill; + +/** + * @author Mobius + */ +public class OpNotInCeremonyOfChaosSkillCondition implements ISkillCondition +{ + public OpNotInCeremonyOfChaosSkillCondition(StatsSet params) + { + } + + @Override + public boolean canUse(Creature caster, Skill skill, WorldObject target) + { + return (caster.isPlayer() && !caster.getActingPlayer().isOnEvent(CeremonyOfChaosEvent.class)); + } +} diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java index 6e46f1e46c..266581076b 100644 --- a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java +++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java @@ -136,5 +136,6 @@ public class SkillConditionMasterHandler SkillConditionHandler.getInstance().registerHandler("OpTargetMyPledgeAcademy", OpTargetMyPledgeAcademySkillCondition::new); SkillConditionHandler.getInstance().registerHandler("OpCheckFlag", OpCheckFlagSkillCondition::new); SkillConditionHandler.getInstance().registerHandler("NotFeared", NotFearedSkillCondition::new); + SkillConditionHandler.getInstance().registerHandler("OpNotInCeremonyOfChaos", OpNotInCeremonyOfChaosSkillCondition::new); } } diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java new file mode 100644 index 0000000000..9549fdc2ac --- /dev/null +++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java @@ -0,0 +1,40 @@ +/* + * 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.skillconditionhandlers; + +import org.l2jmobius.gameserver.model.StatsSet; +import org.l2jmobius.gameserver.model.WorldObject; +import org.l2jmobius.gameserver.model.actor.Creature; +import org.l2jmobius.gameserver.model.ceremonyofchaos.CeremonyOfChaosEvent; +import org.l2jmobius.gameserver.model.skills.ISkillCondition; +import org.l2jmobius.gameserver.model.skills.Skill; + +/** + * @author Mobius + */ +public class OpNotInCeremonyOfChaosSkillCondition implements ISkillCondition +{ + public OpNotInCeremonyOfChaosSkillCondition(StatsSet params) + { + } + + @Override + public boolean canUse(Creature caster, Skill skill, WorldObject target) + { + return (caster.isPlayer() && !caster.getActingPlayer().isOnEvent(CeremonyOfChaosEvent.class)); + } +} diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java index 6e46f1e46c..266581076b 100644 --- a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java +++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java @@ -136,5 +136,6 @@ public class SkillConditionMasterHandler SkillConditionHandler.getInstance().registerHandler("OpTargetMyPledgeAcademy", OpTargetMyPledgeAcademySkillCondition::new); SkillConditionHandler.getInstance().registerHandler("OpCheckFlag", OpCheckFlagSkillCondition::new); SkillConditionHandler.getInstance().registerHandler("NotFeared", NotFearedSkillCondition::new); + SkillConditionHandler.getInstance().registerHandler("OpNotInCeremonyOfChaos", OpNotInCeremonyOfChaosSkillCondition::new); } } diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java new file mode 100644 index 0000000000..9549fdc2ac --- /dev/null +++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java @@ -0,0 +1,40 @@ +/* + * 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.skillconditionhandlers; + +import org.l2jmobius.gameserver.model.StatsSet; +import org.l2jmobius.gameserver.model.WorldObject; +import org.l2jmobius.gameserver.model.actor.Creature; +import org.l2jmobius.gameserver.model.ceremonyofchaos.CeremonyOfChaosEvent; +import org.l2jmobius.gameserver.model.skills.ISkillCondition; +import org.l2jmobius.gameserver.model.skills.Skill; + +/** + * @author Mobius + */ +public class OpNotInCeremonyOfChaosSkillCondition implements ISkillCondition +{ + public OpNotInCeremonyOfChaosSkillCondition(StatsSet params) + { + } + + @Override + public boolean canUse(Creature caster, Skill skill, WorldObject target) + { + return (caster.isPlayer() && !caster.getActingPlayer().isOnEvent(CeremonyOfChaosEvent.class)); + } +} diff --git a/L2J_Mobius_7.0_PreludeOfWar/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java b/L2J_Mobius_7.0_PreludeOfWar/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java index 6e46f1e46c..266581076b 100644 --- a/L2J_Mobius_7.0_PreludeOfWar/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java +++ b/L2J_Mobius_7.0_PreludeOfWar/dist/game/data/scripts/handlers/SkillConditionMasterHandler.java @@ -136,5 +136,6 @@ public class SkillConditionMasterHandler SkillConditionHandler.getInstance().registerHandler("OpTargetMyPledgeAcademy", OpTargetMyPledgeAcademySkillCondition::new); SkillConditionHandler.getInstance().registerHandler("OpCheckFlag", OpCheckFlagSkillCondition::new); SkillConditionHandler.getInstance().registerHandler("NotFeared", NotFearedSkillCondition::new); + SkillConditionHandler.getInstance().registerHandler("OpNotInCeremonyOfChaos", OpNotInCeremonyOfChaosSkillCondition::new); } } diff --git a/L2J_Mobius_7.0_PreludeOfWar/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java b/L2J_Mobius_7.0_PreludeOfWar/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java new file mode 100644 index 0000000000..9549fdc2ac --- /dev/null +++ b/L2J_Mobius_7.0_PreludeOfWar/dist/game/data/scripts/handlers/skillconditionhandlers/OpNotInCeremonyOfChaosSkillCondition.java @@ -0,0 +1,40 @@ +/* + * 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.skillconditionhandlers; + +import org.l2jmobius.gameserver.model.StatsSet; +import org.l2jmobius.gameserver.model.WorldObject; +import org.l2jmobius.gameserver.model.actor.Creature; +import org.l2jmobius.gameserver.model.ceremonyofchaos.CeremonyOfChaosEvent; +import org.l2jmobius.gameserver.model.skills.ISkillCondition; +import org.l2jmobius.gameserver.model.skills.Skill; + +/** + * @author Mobius + */ +public class OpNotInCeremonyOfChaosSkillCondition implements ISkillCondition +{ + public OpNotInCeremonyOfChaosSkillCondition(StatsSet params) + { + } + + @Override + public boolean canUse(Creature caster, Skill skill, WorldObject target) + { + return (caster.isPlayer() && !caster.getActingPlayer().isOnEvent(CeremonyOfChaosEvent.class)); + } +}