Jump to content

Recommended Posts

Posted (edited)

well all u know the special effects that gm's have.

the effect to dance when u are stunning and the effect of stun with a fire in the ground

so i was thinking about some new skills on bd and i remembered that effect of the stunning dance so i thought that it will be cool a skill like dat ;D

anyway lets start ;D

 

create in gameserver/skills/effects this

/*
 * 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 2, 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, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 * 02111-1307, USA.
 *
 * http://www.gnu.org/copyleft/gpl.html
 */
package com.l2jfrozen.gameserver.skills.effects;

import com.l2jfrozen.gameserver.model.L2Character;
import com.l2jfrozen.gameserver.model.L2Effect;
import com.l2jfrozen.gameserver.skills.Env;

final class EffectStunDance extends L2Effect
{

	public EffectStunDance(Env env, EffectTemplate template)
	{
		super(env, template);
	}

	@Override
	public EffectType getEffectType()
	{
		return EffectType.STUNDANCE;
	}

	@Override
	public void onStart()
	{
		getEffected().stopMove(null);
		getEffected().startAbnormalEffect(L2Character.ABNORMAL_EFFECT_DANCE_STUNNED);
		getEffected().setIsParalyzed(true);
	}

	@Override
	public void onExit()
	{
		getEffected().stopAbnormalEffect(L2Character.ABNORMAL_EFFECT_DANCE_STUNNED);
		getEffected().setIsParalyzed(false);
	}

	@Override
	public boolean onActionTime()
	{
		return false;
	}
}

and this 

/*
 * 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 2, 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, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 * 02111-1307, USA.
 *
 * http://www.gnu.org/copyleft/gpl.html
 */
package com.l2jfrozen.gameserver.skills.effects;

import com.l2jfrozen.gameserver.model.L2Character;
import com.l2jfrozen.gameserver.model.L2Effect;
import com.l2jfrozen.gameserver.skills.Env;

final class EffectStunFireRoot extends L2Effect
{

	public EffectStunFireRoot(Env env, EffectTemplate template)
	{
		super(env, template);
	}

	@Override
	public EffectType getEffectType()
	{
		return EffectType.FIREROOT;
	}

	@Override
	public void onStart()
	{
		getEffected().stopMove(null);
		getEffected().startAbnormalEffect(L2Character.ABNORMAL_EFFECT_FIREROOT_STUN);
		getEffected().setIsParalyzed(true);
	}

	@Override
	public void onExit()
	{
		getEffected().stopAbnormalEffect(L2Character.ABNORMAL_EFFECT_FIREROOT_STUN);
		getEffected().setIsParalyzed(false);
	}

	@Override
	public boolean onActionTime()
	{
		return false;
	}
}

now in model/L2Effect.java

find this

NEGATE,

and below add these

		STUNDANCE,
		FIREROOT, 

now in model/L2Character.java

find this

public static final int ABNORMAL_EFFECT_GROW = 0x010000;

and add below these

 

/** The Constant ABNORMAL_EFFECT_DANCE_STUNNED. */
public static final int ABNORMAL_EFFECT_DANCE_STUNNED = 0x040000;


/** The Constant ABNORMAL_EFFECT_FIREROOT_STUN. */
public static final int ABNORMAL_EFFECT_FIREROOT_STUN = 0x080000;

and last in gameserver/skills/DocumentBase.java

find this

			else if(abn.equals("stealth"))
			{
				abnormal = L2Character.ABNORMAL_EFFECT_STEALTH;
			}

and below add these

			else if(abn.equals("dance"))
			{
				abnormal = L2Character.ABNORMAL_EFFECT_DANCE_STUNNED;
			}
			else if(abn.equals("fireroot"))
			{
				abnormal = L2Character.ABNORMAL_EFFECT_FIREROOT_STUN;
			}

now u can add new skills with these effects ;D

example:

 

<skill id="367" levels="1" name="Dance of Medusa">
<set name="magicLvl" val="77"/>
<set name="mpConsume" val="53"/>
<set name="weaponsAllowed" val="512"/>
<set name="power" val="80"/>
<set name="saveVs" val="MEN"/>
<set name="skillRadius" val="150"/>
<set name="target" val="TARGET_AURA"/>
<set name="skillType" val="PARALYZE"/>
<set name="operateType" val="OP_ACTIVE"/>
<set name="hitTime" val="2000"/>
<set name="reuseDelay" val="120000"/>
<set name="isDebuff" val="true"/>
<set name="element" val="4"/>
<!-- Earth -->
<set name="lvlDepend" val="1"/>
<for>
<!-- <effect count="1" name="Petrification" time="30" val="0"/> -->
<!-- The player that will "eat" the debuff will get stunned and start dancing for 30sec. the dancing effect doesnt work in monster -->
<effect count="1" name="StunDance" time="30" val="0"/>
</for>
</skill>
<skill id="402" levels="10" name="Arrest" enchantLevels1="30" enchantLevels2="30">
  <table name="#enchantMagicLvl">76 76 76 77 77 77 78 78 78 79 79 79 80 80 80 81 81 81 82 82 82 82 83 83 83 84 84 85 85 85</table>
  <enchant1 name="magicLvl" val="#enchantMagicLvl"/>
  <enchant2 name="magicLvl" val="#enchantMagicLvl"/>
  <table name="#power">80 81 82 82 83 84 84 85 86 86 87 88 88 89 90 90 91 92 92 93 94 94 95 96 96 97 98 98 99 100</table>
  <table name="#chance">80 81 82 82 83 84 84 85 86 86 87 88 88 89 90 90 91 92 92 93 94 94 95 96 96 97 98 98 99 100</table>
  <table name="#mpConsume">25 27 28 29 30 31 32 33 34 34</table>
  <set name="mpConsume" val="#mpConsume"/>
  <set name="power" val="125"/>
  <set name="saveVs" val="MEN"/>
  <set name="lvlDepend" val="2"/>
  <set name="target" val="TARGET_ONE"/>
  <set name="reuseDelay" val="16000"/>
  <set name="hitTime" val="2000"/>
  <set name="skillType" val="ROOT"/>
  <set name="operateType" val="OP_ACTIVE"/>
  <set name="castRange" val="150"/>
  <set name="effectRange" val="650"/>
  <set name="isDebuff" val="true" />
  <enchant1 name="power" val="#power"/>
  <enchant2 name="power" val="#chance"/>
  <for>
  <!--  <effect count="1" name="Root" time="7" val="0" stackOrder="1" stackType="Root"/> -->
<!-- The player that will "eat" the debuff will get stunned and shows a fire arrest him for 7sec. the fire effect doesnt work in monster -->
         <effect count="1" name="StunFireRoot" time="7" val="0" stackOrder="1" stackType="Root"/>
  </for>
</skill>

thats for the effects ;p

 

now the conditions.

the conditions are taken from client gracia++ i dont even know ;D

it works like the restorations skills of kamael.

u need to have a effect on u so u can use another skill

 

gameserver/skills/conditions.java

create new files

/*
 * 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 com.l2jfrozen.gameserver.skills.conditions;

import com.l2jfrozen.gameserver.model.L2Effect;
import com.l2jfrozen.gameserver.skills.Env;

public class ConditionTargetActiveEffectId extends Condition
{
    
    private final int _effectId;
    
    public ConditionTargetActiveEffectId(int effectId)
    {
        _effectId = effectId;
    }
    
    @Override
    public boolean testImpl(Env env)
    {
        for (L2Effect e : env.target.getAllEffects())
        {
            if (e != null)
            {
                if (e.getSkill().getId() == _effectId)
                    return true;
            }
        }
        return false;
    }
}

/*
 * 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 com.l2jfrozen.gameserver.skills.conditions;

import com.l2jfrozen.gameserver.model.L2Skill;
import com.l2jfrozen.gameserver.skills.Env;

public class ConditionTargetActiveSkillId extends Condition
{
    
    private final int _skillId;
    
    public ConditionTargetActiveSkillId(int skillId)
    {
        _skillId = skillId;
    }
    
    @Override
    public boolean testImpl(Env env)
    {
        for (L2Skill sk : env.target.getAllSkills())
        {
            if (sk != null)
            {
                if (sk.getId() == _skillId)
                    return true;
            }
        }
        return false;
    }
}

/*
 * 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 2, 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, write to the Free Software
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 * 02111-1307, USA.
 *
 * http://www.gnu.org/copyleft/gpl.html
 */
package com.l2jfrozen.gameserver.skills.conditions;

import com.l2jfrozen.gameserver.skills.Env;

/**
 * @author mkizub
 */
public class ConditionTargetSkill extends Condition
{

	private final int _skill;

	public ConditionTargetSkill(int skillId)
	{
		_skill = skillId;
	}

	@Override
	public boolean testImpl(Env env)
	{
		if(env.target == null)
			return false;
		return env.target.getAbnormalEffect() == _skill;
	}
}

thats it now in gameserver/skills/DocumentBase.java

find this

import com.l2jfrozen.gameserver.skills.conditions.ConditionPlayerState;

and add these below

import com.l2jfrozen.gameserver.skills.conditions.ConditionTargetActiveEffectId;
import com.l2jfrozen.gameserver.skills.conditions.ConditionTargetActiveSkillId;

now find this

			else if("class_id_restriction".equalsIgnoreCase(a.getNodeName()))
			{
				FastList<Integer> array = new FastList<Integer>();
				StringTokenizer st = new StringTokenizer(a.getNodeValue(), ",");
				while(st.hasMoreTokens())
				{
					String item = st.nextToken().trim();
					array.add(Integer.decode(getValue(item, null)));
				}
				cond = joinAnd(cond, new ConditionTargetClassIdRestriction(array));
			}

and below add these

            else if ("active_effect_id".equalsIgnoreCase(a.getNodeName()))
            {
                int effect_id = Integer.decode(getValue(a.getNodeValue(), template));
            	cond = joinAnd(cond, new ConditionTargetActiveEffectId(effect_id));
            }
            else if ("active_skill_id".equalsIgnoreCase(a.getNodeName()))
            {
                int skill_id = Integer.decode(getValue(a.getNodeValue(), template));
                cond = joinAnd(cond, new ConditionTargetActiveSkillId(skill_id));
            }

thats it ;D finished.

example

 

create this (its spoil skill transformed into restoration)

	<skill id="254" levels="8" name="Restoration">
		<table name="#mpConsume_Init"> 21 25 14 16 17 19 20 20 </table>
		<table name="#mpConsume"> 49 57 34 38 41 43 45 48 </table>
		<table name="#hot"> 45 54 66 75 81 87 90 96 </table>
		<table name="#ench1Heal"> 96 99 99 102 105 108 111 114 114 117 120 123 126 126 129 132 135 138 141 141 144 147 150 153 153 156 159 162 165 168 </table>
		<table name="#ench2Count"> 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 40 41 42 43 44 45 </table>
		<table name="#ench2mpInitialConsume"> 13 13 13 12 12 12 12 12 11 11 11 11 10 10 10 10 9 9 9 9 9 8 8 8 8 7 7 7 7 7 </table>
		<table name="#ench2mpConsume"> 53 52 50 50 49 48 48 46 46 45 44 42 42 41 40 38 38 38 37 36 34 34 33 32 30 30 29 29 28 26 </table>
		<set name="mpInitialConsume" val="#mpConsume_Init" />
		<set name="mpConsume" val="#mpConsume" />
		<set name="hitTime" val="2500" />
		<set name="operateType" val="OP_ACTIVE" />
		<set name="isMagic" val="true" />
		<set name="target" val="TARGET_ONE" />
		<set name="skillType" val="HOT" />
		<set name="castRange" val="600" />
		<set name="effectRange" val="1100" />
		<set name="reuseDelay" val="3000" />
		<enchant2 name="mpInitialConsume" val="#ench2mpInitialConsume" />
		<enchant2 name="mpConsume" val="#ench2mpConsume" />
		<for>
			<effect count="5" name="HealOverTime" time="3" val="#hot" stackOrder="1" stackType="touch_of_life">
			</effect>
		</for>
	</skill>
	<skill id="302" levels="3" name="Restoration Impact" enchantGroup1="1">
		<table name="#mpConsume_Init"> 7 8 10 </table>
		<table name="#mpConsume"> 16 20 23 </table>
		<table name="#power"> 10 15 20 </table>
		<table name="#ench1Power"> 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 </table>
		<set name="aggroPoints" val="#power" />
		<set name="mpInitialConsume" val="#mpConsume_Init" />
		<set name="mpConsume" val="#mpConsume" />
		<set name="power" val="#power" />
		<set name="hitTime" val="1000" />
		<set name="operateType" val="OP_ACTIVE" />
		<set name="isMagic" val="true" />
		<set name="target" val="TARGET_ONE" />
		<set name="skillType" val="HEAL_PERCENT" />
		<set name="castRange" val="600" />
		<set name="effectRange" val="1100" />
		<set name="reuseDelay" val="15000" />
		<set name="negateId" val="254" />
		<enchant1 name="power" val="#ench1Power" />
		<cond msg="You must use Restoration first">
			<target active_effect_id="254" />
		</cond>
		<for>
			<effect name="Negate" val="0" noicon="1" effectType="NEGATE" />
		</for>
	</skill>

so in order to use Restoration Impact u need the effect of "<target active_effect_id="254" />" 254 = Restoration

and u're done ;D u will be able to use Restoration Impact only if u have the effect of Restoration on you :)

Edited by te0x

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



  • Posts

    • From Salvation onwards I think you need a patched nwindow.dll that allows such modifications, try to see if you get what you need here: https://drive.google.com/drive/u/1/folders/1LLbQFGf8KlR-O0Iv5umfF-pwZgrDh9bd
    • hello everyone! I am wanting to save the files (Ini. - Data - ) of the EP5 Client: Salvation... But they generate the error "corrupt files"... I tried several versions of L2FileEditor without good results. I need help! Thank you!
    • Opening December 6th at 19:00 (GMT +3)! Open Beta Test from November 30th!   https://l2soe.com/   🌟 Introducing L2 Saga of Eternia: A Revolution in Lineage 2 High Five! 🌟   Dear Lineage 2 enthusiasts, Prepare to witness the future of private servers! L2 Saga of Eternia is not just another High Five project—it’s a game-changing experience designed to compete with the giants of the Lineage 2 private server scene. Built for the community, by the community, we’re here to raise the bar in quality, innovation, and longevity. What Sets Us Apart? 💎 No Wipes, Ever Say goodbye to the fear of losing your progress. Our server is built to last and will never close. Stability and consistency are our promises to you. ⚔️ Weekly New Content Our dedicated development team ensures fresh challenges, events, and updates every week. From custom quests to exclusive features, there will always be something exciting to explore. 💰 No Pay-to-Win Skill and strategy matter most here. Enjoy a balanced gameplay environment where your achievements come from effort, not your wallet. 🌍 A Massive Community With 2000+ players expected, join a vibrant and active community of like-minded adventurers ready to conquer the world of Aden. 🏆 Fair and Competitive Gameplay Our systems are designed to promote healthy competition while avoiding abusive mechanics and exploits. 🔧 Professional Development From advanced bug fixes to carefully curated content, we pride ourselves on smooth performance, no lag, and unparalleled server quality. Key Features Chronicle: High Five with unique interface Rate: Dynamic x10 rates Class Balance: Carefully fine-tuned for a fair experience PvP Focused: PvP Ranking & aura display effect for 3 Top PvPers every week Custom Events: Seasonal and permanent events to keep you engaged Additional Features:   Custom Endgame Content: Introduce unique dungeons, raids, or zones unavailable in other servers. Player-Driven Economy: Implement a strong market system and avoid overinflated drops or rewards. Epic Siege Battles: Announce special large-scale sieges and PvP events. Incentives for Streamers and Clans: Attract influencers and big clans to boost server publicity. Roadmap Transparency: Share a public roadmap of planned updates to build trust and excitemen   Here you can read all the features: https://l2soe.com/features   Video preview: Join the Revolution! This is your chance to be part of something legendary. L2 Saga of Eternia is not just a server; it’s a movement to redefine what Lineage 2 can be. Whether you’re a seasoned veteran or a newcomer to the world of Aden, we invite you to experience Lineage 2 at its finest.   Official Launch Date: December 6th 2024 Website: https://l2soe.com/ Facebook: https://www.facebook.com/l2soe Discord: https://discord.com/invite/l2eternia   Let’s build the ultimate Lineage 2 experience together. See you in-game! 🎮
    • That's like a tutorial on how to run l2 on MacOS Xd but good job for the investigation. 
    • small update: dc robe set sold   wts adena 1kk = 1.5$ 
  • Topics

×
×
  • Create New...