Package lineage2.gameserver.model

Examples of lineage2.gameserver.model.Effect


   
    List<Effect> effectList = player.getEffectList().getAllEffects();
    _effects = new ArrayList<>(effectList.size());
    for (Effect $effect : effectList)
    {
      Effect effect = $effect.getTemplate().getEffect(new Env($effect.getEffector(), $effect.getEffected(), $effect.getSkill()));
      effect.setCount($effect.getCount());
      effect.setPeriod($effect.getCount() == 1 ? $effect.getPeriod() - $effect.getTime() : $effect.getPeriod());
     
      _effects.add(effect);
    }
  }
View Full Code Here


          {
            if (counter < stealCount)
            {
              if (canSteal(e))
              {
                Effect stolenEffect = cloneEffect(activeChar, e);
                if (stolenEffect != null)
                {
                  activeChar.getEffectList().addEffect(stolenEffect);
                }
                e.exit();
View Full Code Here

  private Effect cloneEffect(Creature cha, Effect eff)
  {
    Skill skill = eff.getSkill();
    for (EffectTemplate et : skill.getEffectTemplates())
    {
      Effect effect = et.getEffect(new Env(cha, cha, skill));
      if (effect != null)
      {
        effect.setCount(eff.getCount());
        effect.setPeriod(eff.getCount() == 1 ? eff.getPeriod() - eff.getTime() : eff.getPeriod());
        return effect;
      }
    }
    return null;
  }
View Full Code Here

          if (et == null)
          {
            continue;
          }
          Env env = new Env(playable, playable, skill);
          Effect effect = et.getEffect(env);
          if ((effect == null) || effect.isOneTime())
          {
            continue;
          }
          effect.setCount(effectCount);
          effect.setPeriod(effectCount == 1 ? duration - effectCurTime : duration);
          if(et.getEffectType() == EffectType.ServitorShare && playable.isPlayer())
          {
            playable.getPlayer().setServitorShareRestore(true, effect);
            continue;
          }
View Full Code Here

    for (Player pp : p.getPartyMembers())
    {
      for (EffectTemplate et : skill.getEffectTemplates())
      {
        Env env = new Env(pp, pp, skill);
        Effect effect = et.getEffect(env);
        effect.setPeriod(10000);
        pp.getEffectList().addEffect(effect);
      }
    }
  }
View Full Code Here

  /**
   * Method saveBuffList.
   */
  public static void saveBuffList()
  {
    Effect skill[];
    for (Player player : getPlayers(players_list1))
    {
      if (player != null)
      {
        skill = player.getEffectList().getAllFirstEffects();
View Full Code Here

        {
          for (EffectTemplate et : effect.getSkill().getEffectTemplates())
          {
            Env env = new Env(player, player, effect.getSkill());
            env.value = Integer.MAX_VALUE;
            Effect e = et.getEffect(env);
            e.setPeriod(effect.getPeriod());
            e.getEffected().getEffectList().addEffect(e);
          }
          try
          {
            Thread.sleep(150);
          }
View Full Code Here

        skill = SkillTable.getInstance().getInfo(buff[0], buff[1]);
        for (EffectTemplate et : skill.getEffectTemplates())
        {
          Env env = new Env(player, player, skill);
          env.value = Integer.MAX_VALUE;
          Effect e = et.getEffect(env);
          e.setPeriod(600000);
          e.getEffected().getEffectList().addEffect(e);
        }
        try
        {
          Thread.sleep(150);
        }
View Full Code Here

  /**
   * Method saveBuffList.
   */
  public static void saveBuffList()
  {
    Effect skill[];
    for (Player player : getPlayers(players_list1))
    {
      if (player != null)
      {
        skill = player.getEffectList().getAllFirstEffects();
View Full Code Here

        {
          for (EffectTemplate et : effect.getSkill().getEffectTemplates())
          {
            Env env = new Env(player, player, effect.getSkill());
            env.value = Integer.MAX_VALUE;
            Effect e = et.getEffect(env);
            e.setPeriod(effect.getPeriod());
            e.getEffected().getEffectList().addEffect(e);
          }
          try
          {
            Thread.sleep(150);
          }
View Full Code Here

TOP

Related Classes of lineage2.gameserver.model.Effect

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.