Package l2p.gameserver.model

Examples of l2p.gameserver.model.L2Fishing


    if(caster == null || !caster.isPlayer())
    {
      return;
    }
    L2Player player = (L2Player) caster;
    L2Fishing fish = player.getFishCombat();
    L2Weapon weaponItem = player.getActiveWeaponItem();
    int SS = player.getChargedFishShot() ? 2 : 1;
    int pen = 0;
    double gradebonus = 1 + weaponItem.getCrystalType().ordinal() * 0.1;
    int dmg = (int) (getPower() * gradebonus * SS);
    if(player.getSkillLevel(1315) < getLevel() - 2) // 1315 - Fish Expertise
    {
      // Penalty
      player.sendPacket(Msg.SINCE_THE_SKILL_LEVEL_OF_REELING_PUMPING_IS_HIGHER_THAN_THE_LEVEL_OF_YOUR_FISHING_MASTERY_A_PENALTY_OF_S1_WILL_BE_APPLIED);
      pen = 50;
      int penatlydmg = dmg - pen;
      if(player.isGM())
      {
        player.sendMessage("Dmg w/o penalty = " + dmg);
      }
      dmg = penatlydmg;
    }
    if(SS == 2)
    {
      player.unChargeFishShot();
    }
    if(fish != null)
    {
      if(getSkillType() == SkillType.REELING)
      {
        fish.UseRealing(dmg, pen);
      }
      else
      {
        fish.UsePomping(dmg, pen);
      }
    }
  }
View Full Code Here

TOP

Related Classes of l2p.gameserver.model.L2Fishing

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.