Fixed Infinity Spear cancel like retail.
This commit is contained in:
parent
6aaf999da7
commit
8fc3e43a4d
@ -754,7 +754,7 @@
|
|||||||
<set name="item_skill_lvl" val="1" />
|
<set name="item_skill_lvl" val="1" />
|
||||||
<set name="onCrit_skill_id" val="3592" /> <!-- Dispell -->
|
<set name="onCrit_skill_id" val="3592" /> <!-- Dispell -->
|
||||||
<set name="onCrit_skill_lvl" val="1" />
|
<set name="onCrit_skill_lvl" val="1" />
|
||||||
<set name="onCrit_skill_chance" val="20" />
|
<set name="onCrit_skill_chance" val="100" />
|
||||||
<for>
|
<for>
|
||||||
<set val="297" order="0x08" stat="pAtk" />
|
<set val="297" order="0x08" stat="pAtk" />
|
||||||
<set val="137" order="0x08" stat="mAtk" />
|
<set val="137" order="0x08" stat="mAtk" />
|
||||||
@ -764,8 +764,6 @@
|
|||||||
<set val="325" order="0x08" stat="pAtkSpd" />
|
<set val="325" order="0x08" stat="pAtkSpd" />
|
||||||
<enchant val="0" order="0x0C" stat="pAtk" />
|
<enchant val="0" order="0x0C" stat="pAtk" />
|
||||||
<enchant val="0" order="0x0C" stat="mAtk" />
|
<enchant val="0" order="0x0C" stat="mAtk" />
|
||||||
<skill onCrit="1" id="3592" lvl="1" chance="10" />
|
|
||||||
<!-- 10% chance to cancel each buff from target on a critical hit -->
|
|
||||||
</for>
|
</for>
|
||||||
</item>
|
</item>
|
||||||
<item id="6622" type="EtcItem" name="Secret Book of Giants">
|
<item id="6622" type="EtcItem" name="Secret Book of Giants">
|
||||||
|
@ -1515,15 +1515,18 @@
|
|||||||
</for>
|
</for>
|
||||||
</skill>
|
</skill>
|
||||||
<skill id="3592" levels="1" name="Dispell">
|
<skill id="3592" levels="1" name="Dispell">
|
||||||
<set name="bestowed" val="true" />
|
<set name="bestowed" val="true"/>
|
||||||
<set name="magicLevel" val="80" />
|
<set name="magicLvl" val="80"/>
|
||||||
<set name="negateSkillTypes" val="BUFF" />
|
<set name="operateType" val="ACTIVE"/>
|
||||||
<set name="operateType" val="ACTIVE" />
|
<set name="power" val="80"/>
|
||||||
<set name="power" val="80" />
|
<set name="skillType" val="CORE_DONE"/>
|
||||||
<!-- Base Land Rate -->
|
<set name="target" val="ONE"/>
|
||||||
<set name="skillType" val="CANCEL" />
|
<!-- Negate power is max cancel buffs -->
|
||||||
<set name="target" val="ONE" />
|
<set name="negateSkillTypes" val="BUFF"/>
|
||||||
<set name="negatePower" val="5" />
|
<set name="negatePower" val="5"/>
|
||||||
|
<for>
|
||||||
|
<effect count="1" name="HeroCancel" time="1" noicon="1" val="0"/>
|
||||||
|
</for>
|
||||||
</skill>
|
</skill>
|
||||||
<skill id="3593" levels="1" name="Special Ability: Infinity Bow">
|
<skill id="3593" levels="1" name="Special Ability: Infinity Bow">
|
||||||
<!-- Decreases enemy's Speed during a critical attack. Increases Max MP, Max CP and damage inflicted during PvP. The skill re-use time is shortened, and MP consumption is reduced. -->
|
<!-- Decreases enemy's Speed during a critical attack. Increases Max MP, Max CP and damage inflicted during PvP. The skill re-use time is shortened, and MP consumption is reduced. -->
|
||||||
|
@ -102,7 +102,8 @@ public abstract class Effect
|
|||||||
BLOCK_DEBUFF,
|
BLOCK_DEBUFF,
|
||||||
PREVENT_BUFF,
|
PREVENT_BUFF,
|
||||||
CLAN_GATE,
|
CLAN_GATE,
|
||||||
NEGATE
|
NEGATE,
|
||||||
|
HERO_CANCEL
|
||||||
}
|
}
|
||||||
|
|
||||||
// member _effector is the instance of Creature that cast/used the spell/skill that is causing this effect. Do not confuse with the instance of Creature that is being affected by this effect.
|
// member _effector is the instance of Creature that cast/used the spell/skill that is causing this effect. Do not confuse with the instance of Creature that is being affected by this effect.
|
||||||
|
@ -0,0 +1,87 @@
|
|||||||
|
/*
|
||||||
|
* 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 <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
package org.l2jmobius.gameserver.model.skill.effects;
|
||||||
|
|
||||||
|
import org.l2jmobius.commons.util.Rnd;
|
||||||
|
import org.l2jmobius.gameserver.model.Effect;
|
||||||
|
import org.l2jmobius.gameserver.model.skill.Env;
|
||||||
|
import org.l2jmobius.gameserver.model.skill.SkillType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Infinity Spear effect like L2OFF Interlude (lineage2.com 2007 year)
|
||||||
|
* @author Souverain, OnePaTuBHuK
|
||||||
|
*/
|
||||||
|
public class EffectHeroCancel extends Effect
|
||||||
|
{
|
||||||
|
public EffectHeroCancel(final Env env, final EffectTemplate template)
|
||||||
|
{
|
||||||
|
super(env, template);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EffectType getEffectType()
|
||||||
|
{
|
||||||
|
return EffectType.HERO_CANCEL;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onStart()
|
||||||
|
{
|
||||||
|
int maxdisp = (int) getSkill().getNegatePower();
|
||||||
|
for (Effect e : getEffected().getAllEffects())
|
||||||
|
{
|
||||||
|
switch (e.getEffectType())
|
||||||
|
{
|
||||||
|
case SIGNET_GROUND:
|
||||||
|
case SIGNET_EFFECT:
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if ((e.getSkill().getId() != 4082) && (e.getSkill().getId() != 4215) && (e.getSkill().getId() != 5182) && (e.getSkill().getId() != 4515) && (e.getSkill().getId() != 110) && (e.getSkill().getId() != 111) && (e.getSkill().getId() != 1323) && (e.getSkill().getId() != 1325))
|
||||||
|
{
|
||||||
|
if (e.getSkill().getSkillType() == SkillType.BUFF)
|
||||||
|
{
|
||||||
|
int rate = 10;
|
||||||
|
|
||||||
|
if (Rnd.get(100) < rate)
|
||||||
|
{
|
||||||
|
e.exit(true);
|
||||||
|
maxdisp--;
|
||||||
|
if (maxdisp == 0)
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onExit()
|
||||||
|
{
|
||||||
|
// Do nothing.
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean onActionTime()
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
@ -754,7 +754,7 @@
|
|||||||
<set name="item_skill_lvl" val="1" />
|
<set name="item_skill_lvl" val="1" />
|
||||||
<set name="onCrit_skill_id" val="3592" /> <!-- Dispell -->
|
<set name="onCrit_skill_id" val="3592" /> <!-- Dispell -->
|
||||||
<set name="onCrit_skill_lvl" val="1" />
|
<set name="onCrit_skill_lvl" val="1" />
|
||||||
<set name="onCrit_skill_chance" val="20" />
|
<set name="onCrit_skill_chance" val="100" />
|
||||||
<for>
|
<for>
|
||||||
<set val="297" order="0x08" stat="pAtk" />
|
<set val="297" order="0x08" stat="pAtk" />
|
||||||
<set val="137" order="0x08" stat="mAtk" />
|
<set val="137" order="0x08" stat="mAtk" />
|
||||||
@ -764,8 +764,6 @@
|
|||||||
<set val="325" order="0x08" stat="pAtkSpd" />
|
<set val="325" order="0x08" stat="pAtkSpd" />
|
||||||
<enchant val="0" order="0x0C" stat="pAtk" />
|
<enchant val="0" order="0x0C" stat="pAtk" />
|
||||||
<enchant val="0" order="0x0C" stat="mAtk" />
|
<enchant val="0" order="0x0C" stat="mAtk" />
|
||||||
<skill onCrit="1" id="3592" lvl="1" chance="10" />
|
|
||||||
<!-- 10% chance to cancel each buff from target on a critical hit -->
|
|
||||||
</for>
|
</for>
|
||||||
</item>
|
</item>
|
||||||
<item id="6622" type="EtcItem" name="Secret Book of Giants">
|
<item id="6622" type="EtcItem" name="Secret Book of Giants">
|
||||||
|
@ -1515,15 +1515,18 @@
|
|||||||
</for>
|
</for>
|
||||||
</skill>
|
</skill>
|
||||||
<skill id="3592" levels="1" name="Dispell">
|
<skill id="3592" levels="1" name="Dispell">
|
||||||
<set name="bestowed" val="true" />
|
<set name="bestowed" val="true"/>
|
||||||
<set name="magicLevel" val="80" />
|
<set name="magicLvl" val="80"/>
|
||||||
<set name="negateSkillTypes" val="BUFF" />
|
<set name="operateType" val="ACTIVE"/>
|
||||||
<set name="operateType" val="ACTIVE" />
|
<set name="power" val="80"/>
|
||||||
<set name="power" val="80" />
|
<set name="skillType" val="CORE_DONE"/>
|
||||||
<!-- Base Land Rate -->
|
<set name="target" val="ONE"/>
|
||||||
<set name="skillType" val="CANCEL" />
|
<!-- Negate power is max cancel buffs -->
|
||||||
<set name="target" val="ONE" />
|
<set name="negateSkillTypes" val="BUFF"/>
|
||||||
<set name="negatePower" val="5" />
|
<set name="negatePower" val="5"/>
|
||||||
|
<for>
|
||||||
|
<effect count="1" name="HeroCancel" time="1" noicon="1" val="0"/>
|
||||||
|
</for>
|
||||||
</skill>
|
</skill>
|
||||||
<skill id="3593" levels="1" name="Special Ability: Infinity Bow">
|
<skill id="3593" levels="1" name="Special Ability: Infinity Bow">
|
||||||
<!-- Decreases enemy's Speed during a critical attack. Increases Max MP, Max CP and damage inflicted during PvP. The skill re-use time is shortened, and MP consumption is reduced. -->
|
<!-- Decreases enemy's Speed during a critical attack. Increases Max MP, Max CP and damage inflicted during PvP. The skill re-use time is shortened, and MP consumption is reduced. -->
|
||||||
|
@ -102,7 +102,8 @@ public abstract class Effect
|
|||||||
BLOCK_DEBUFF,
|
BLOCK_DEBUFF,
|
||||||
PREVENT_BUFF,
|
PREVENT_BUFF,
|
||||||
CLAN_GATE,
|
CLAN_GATE,
|
||||||
NEGATE
|
NEGATE,
|
||||||
|
HERO_CANCEL
|
||||||
}
|
}
|
||||||
|
|
||||||
// member _effector is the instance of Creature that cast/used the spell/skill that is causing this effect. Do not confuse with the instance of Creature that is being affected by this effect.
|
// member _effector is the instance of Creature that cast/used the spell/skill that is causing this effect. Do not confuse with the instance of Creature that is being affected by this effect.
|
||||||
|
@ -0,0 +1,87 @@
|
|||||||
|
/*
|
||||||
|
* 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 <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
package org.l2jmobius.gameserver.model.skill.effects;
|
||||||
|
|
||||||
|
import org.l2jmobius.commons.util.Rnd;
|
||||||
|
import org.l2jmobius.gameserver.model.Effect;
|
||||||
|
import org.l2jmobius.gameserver.model.skill.Env;
|
||||||
|
import org.l2jmobius.gameserver.model.skill.SkillType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Infinity Spear effect like L2OFF Interlude (lineage2.com 2007 year)
|
||||||
|
* @author Souverain, OnePaTuBHuK
|
||||||
|
*/
|
||||||
|
public class EffectHeroCancel extends Effect
|
||||||
|
{
|
||||||
|
public EffectHeroCancel(final Env env, final EffectTemplate template)
|
||||||
|
{
|
||||||
|
super(env, template);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EffectType getEffectType()
|
||||||
|
{
|
||||||
|
return EffectType.HERO_CANCEL;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onStart()
|
||||||
|
{
|
||||||
|
int maxdisp = (int) getSkill().getNegatePower();
|
||||||
|
for (Effect e : getEffected().getAllEffects())
|
||||||
|
{
|
||||||
|
switch (e.getEffectType())
|
||||||
|
{
|
||||||
|
case SIGNET_GROUND:
|
||||||
|
case SIGNET_EFFECT:
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if ((e.getSkill().getId() != 4082) && (e.getSkill().getId() != 4215) && (e.getSkill().getId() != 5182) && (e.getSkill().getId() != 4515) && (e.getSkill().getId() != 110) && (e.getSkill().getId() != 111) && (e.getSkill().getId() != 1323) && (e.getSkill().getId() != 1325))
|
||||||
|
{
|
||||||
|
if (e.getSkill().getSkillType() == SkillType.BUFF)
|
||||||
|
{
|
||||||
|
int rate = 10;
|
||||||
|
|
||||||
|
if (Rnd.get(100) < rate)
|
||||||
|
{
|
||||||
|
e.exit(true);
|
||||||
|
maxdisp--;
|
||||||
|
if (maxdisp == 0)
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onExit()
|
||||||
|
{
|
||||||
|
// Do nothing.
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean onActionTime()
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user