Thanks for replies and sorry for such a long time for me to show up
I forgot to specify that I want to change L2 in a way that:
Let's say you got Arcane Protection, which gives (let's say) 5% tenacity. Then you equip some epic jewelry and it also gives 5% (which stacks with the buff you already have and now you have 10% tenacity overall). Then you turn on some toggle skill that gives 5% tenacity as well and now you have 15% tenacity. So basically time duration of
any incoming debuff regardless of what it does will be reduced by 15% (but maximum overall tenacity on a character should never go over 50%), it should always rely on overall tenacity on a character. Later on I plant to edit descriptions to skills/items accordingly, so it's not a problem if tenacity won't really be shown anywhere in-game, a smart player can just do a little bit of math by checking his gear and buffs to learn how much tenacity he has.
I really want to make this work, because people are excited to see this live (this will change PvP dramatically, less random and more strategy/thinking). We have some drastic changes for classes/skills incoming that hopefully will deliver brand new and fresh pvp, but all of it will be useless without tenacity.
While I'm very comfortable with XML files, I'm very new to programming on
this level.
Right now I'd like to know if I made tenacity effect properly to begin with.
In
EffectTemplate.java I've created (right under public final ChanceCondition chanceCondition;):
then I changed "public EffectTemplate" to
Code: Select all
public EffectTemplate(Condition pAttachCond, Condition pApplayCond, String func, Lambda pLambda, int pCounter, int pAbnormalTime, AbnormalEffect pAbnormalEffect, AbnormalEffect[] pSpecialEffect, AbnormalEffect pEventEffect, String pAbnormalType, byte pAbnormalLvl, boolean showicon, double ePower, int trigId, int trigLvl, ChanceCondition chanceCond, int pTenacityEffect)ย
and after "chanceCondition = chanceCond;" I've added
Then in
DocumentBase.java I added right after int "abnormalTime = 1;" (although I don't understand exactly what it does, but by default without any buffs/items players should have 0 tenacity)
and changed line
Code: Select all
final EffectTemplate lt = new EffectTemplate(attachCond, applayCond, name, lambda, count, abnormalTime, abnormalVisualEffect, special, event, abnormalType, abnormalLvl, icon, effectPower, trigId, trigLvl, chance, tenacityEffect);
Is this correct? Is this it? Tenacity effect is now created and should work correctly?
If yes, now all I have to do is to edit in BaseDocument.java formulas where ENABLE_MODIFY_SKILL_DURATION is mentioned?
And do I have to create new L2TraitType called tenacity and new stat (in Stats.java) called tenacity?
I really appreciate your help!