示例#1
0
  @Override
  public void affectPhyStats(Physical affected, PhyStats affectableStats) {
    super.affectPhyStats(affected, affectableStats);
    if (affected == null) return;
    if (!(affected instanceof MOB)) return;
    final MOB mob = (MOB) affected;

    if (mob == invoker) return;

    final int xlvl = super.getXLEVELLevel(invoker());
    if (CMLib.flags().isEvil(mob)) {
      affectableStats.setArmor(affectableStats.armor() - 15 - (6 * xlvl));
      affectableStats.setAttackAdjustment(affectableStats.attackAdjustment() + 20 + (4 * xlvl));
    } else if (CMLib.flags().isGood(mob)) {
      affectableStats.setArmor(affectableStats.armor() + 15 + (6 * xlvl));
      affectableStats.setAttackAdjustment(affectableStats.attackAdjustment() - 20 - (4 * xlvl));
    }
  }
示例#2
0
 @Override
 public void affectPhyStats(Physical affected, PhyStats affectableStats) {
   affectableStats.setDisposition(affectableStats.disposition() | PhyStats.IS_GOLEM);
   affectableStats.setSensesMask(
       affectableStats.sensesMask() | PhyStats.CAN_NOT_SPEAK | PhyStats.CAN_NOT_TASTE);
   affectableStats.setArmor(affectableStats.armor() + affectableStats.armor());
   affectableStats.setAttackAdjustment(0);
   affectableStats.setDamage(0);
 }
示例#3
0
 @Override
 public void affectPhyStats(Physical affected, PhyStats affectableStats) {
   super.affectPhyStats(affected, affectableStats);
   if (affected instanceof MOB) {
     if (CMLib.flags().isStanding((MOB) affected)) {
       final MOB mob = (MOB) affected;
       final int attArmor =
           (((int) Math.round(CMath.div(mob.charStats().getStat(CharStats.STAT_DEXTERITY), 9.0)))
                   + 1)
               * (mob.charStats().getClassLevel(this) - 1);
       affectableStats.setArmor(affectableStats.armor() - attArmor);
     }
   }
 }