Jump to content
  • 0

Question

Posted (edited)

    <skill id="341" levels="1" name="Touch of Life">
        <set name="hpConsume" val="1215"/>
        <set name="power" val="50"/>
        <set name="target" val="TARGET_ONE"/>
        <set name="skillType" val="HEAL_PERCENT"/>
        <set name="magicLvl" val="78"/>
        <set name="operateType" val="OP_ACTIVE"/>
        <set name="castRange" val="40"/>
        <set name="effectRange" val="400"/>
        <set name="reuseDelay" val="1200000"/>
        <set name="hitTime" val="1800"/>
        <set name="aggroPoints" val="810"/>
        <for>
            <effect count="120" name="HealOverTime" time="1" val="50" stackOrder="1" stackType="touch_of_life">
                <mul order="0x30" stat="gainHp" val="1.3"/>
                <mul order="0x30" stat="cancelVuln" val="0.7"/>
                <mul order="0x30" stat="debuffVuln" val="0.7"/>
            </effect>
        </for>
    </skill>

 

for example what i have to add to this skill script to make it available only in olympiad? 

Edited by dramaa93

8 answers to this question

Recommended Posts

  • 0
Posted (edited)
On 2/4/2021 at 6:35 AM, dramaa93 said:

    <skill id="341" levels="1" name="Touch of Life">
        <set name="hpConsume" val="1215"/>
        <set name="power" val="50"/>
        <set name="target" val="TARGET_ONE"/>
        <set name="skillType" val="HEAL_PERCENT"/>
        <set name="magicLvl" val="78"/>
        <set name="operateType" val="OP_ACTIVE"/>
        <set name="castRange" val="40"/>
        <set name="effectRange" val="400"/>
        <set name="reuseDelay" val="1200000"/>
        <set name="hitTime" val="1800"/>
        <set name="aggroPoints" val="810"/>
        <for>
            <effect count="120" name="HealOverTime" time="1" val="50" stackOrder="1" stackType="touch_of_life">
                <mul order="0x30" stat="gainHp" val="1.3"/>
                <mul order="0x30" stat="cancelVuln" val="0.7"/>
                <mul order="0x30" stat="debuffVuln" val="0.7"/>
            </effect>
        </for>
    </skill>

 

for example what i have to add to this skill script to make it available only in olympiad? 

 

There are 2 ways to proceed. 

 

Either you create a new condition which you gonna do it your self after spend few times in some skills that has conditions such as SEX, RACE, MOUNT e.t.c, or you gonna create a new

 

<set name="olympiadRestricted" val="true" /> 

 

then go inside Skill.java where it parse the structure (you can search for ex. hpConsume to see how it's done), create a new boolean read it as

 

public boolean isOlympiadRestricted()
{
  return _olympiadRestricted;
}

 

and then you have to find the method that does casting check (in L2J  is the following in L2PcInstance.java)

 

public boolean checkDoCastConditions

 

and add your own check, for example

 

if (activeChar.isInOlympiad() && skill.isOlympiadRestricted())
{
   return false;
}

 

Edited by Kara
  • 0
Posted (edited)

@dramaa93 I am sure about that you can prohibit skill in a zone,but not for the opposite..
so you can disable the skill to all other zones like :
1.find the skill (lets say about noblesse)

2.add these lines : 

Spoiler

+<cond msgId="113" addName="1">
+<not>
+<zone name="[add here the zone type ]"/>
+</not>
+</cond>
<for>
<effect count="1" name="BlessNoblesse" stackOrder="1" stackType="BlessOfNoble" time="3600" val="0"/>


3.repeat several times until u add all zones types except olympiadstadium zone

 

i hope it helps


maybe @Zake know a better way for that.

 

Edited by scraw
  • 0
Posted
56 minutes ago, dramaa93 said:

l2jfrozen (pls dont say to use acis cus its better.. :/)

I wanted to check in documentbase if there is a condition for olympiad. Unfortunately in l2jfrozen there is not. You can add a quick one though by editing ConditionPlayerState.java. All you have to do is to add an olympiad enumeration and a simple isInOlympiad() check in testImpl (or whatever this method is called in frozen)

Guest
This topic is now closed to further replies.
×
×
  • Create New...