Page 1 of 1

[BETA]Veil

Posted: Sun Nov 10, 2013 3:21 pm
by Hindi
L2J Revision 6262
L2JDP Revision 10010

As I think Veil isn't working correctly (it affects mobs while they are attacking + while under effect, the mob doesn't react when under attack) even if it seems correct (viewtopic.php?f=103&t=28505&p=170549&hilit=veil#p170549), I'm looking for a way to obtain the following :

- If the mob is attacking / following, it is not affected (I can do that using getIntention() I guess)
- The mob stop lookingn for aggro during the effet (_globalAggro = -120 ?)
- The mob attacks a player if a player attacks him

I tried to achieve this by using :

Code: Select all

        public void onStart(BuffInfo info)    {        L2AttackableAI targetAI = (L2AttackableAI) target.getAI();        targetAI.setGlobalAggro(-120);        targetAI.setIntention(AI_INTENTION_ACTIVE);    } 
Setting _globalAggro to -120 should prevent the mob from looking for targets during 120s (L2Attackable.thinkActive()).
The problem is the mob aggro as soon as Veil affects him and setting intention to ACTIVE/IDLE (even if onIntentionActive() and onIntentionIdle() should stop the attack and delete the target) does not stop the mob from attacking.

Any suggestion to achieve this would really help !