L2-scripts Форум

L2-scripts Форум (http://l2-scripts.ru/forum/index.php)
-   Archive Lindvior, Ertheia, Odyssey, Undergeround, Helios, Grand Crusade (http://l2-scripts.ru/forum/forumdisplay.php?f=103)
-   -   [CORE] Effect UNAGGRO must work for PLAYER also! (http://l2-scripts.ru/forum/showthread.php?t=4136)

boulanger 29.01.2014 17:39

[CORE] Effect UNAGGRO must work for PLAYER also!
 
hello, the effect unaggro does not work for Player character, but should, because of skills like dark rain

Цитата:

Dissolve - removes the aggression of nearby enemies toward you and increase speed by 100
it does increase our speed but didnt remove aggression

Quote
Mass Dark Viel - inflicts damage on the target and nearby enemies with 158 power and decreases aggression toward youself
it damages nearby enemies but didnt decrease/cancel aggression

Quote
Dark Rain - inflicts damage on the target and nearby enemies with 138 power and decreases aggression toward youself
here is effect template, as you can see is implemented only for npc, not for player also, please fix.

Код:

package l2s.gameserver.skills.effects;

import l2s.gameserver.model.Creature;
import l2s.gameserver.model.Effect;
import l2s.gameserver.model.instances.NpcInstance;
import l2s.gameserver.stats.Env;

public class EffectUnAggro extends Effect
{
  public EffectUnAggro(Env env, EffectTemplate template)
  {
    super(env, template);
  }

  public void onStart()
  {
    super.onStart();
    if (this._effected.isNpc())
      ((NpcInstance)this._effected).setUnAggred(true);
  }

  public void onExit()
  {
    super.onExit();
    if (this._effected.isNpc())
      ((NpcInstance)this._effected).setUnAggred(false);
  }

  public boolean onActionTime()
  {
    return false;
  }
}


iqman 16.02.2014 23:26

And how do you imagine yourself that this will work? What the player should do if unagrred?

boulanger 17.02.2014 00:25

close topic not urgent, on retail 99% of time works only on npc.

iqman 17.02.2014 03:23

Ok, closed, I just don't get it :)


Часовой пояс GMT +4, время: 20:28.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd. Перевод: zCarot