Exemple #1
0
 /// <summary>
 /// ダメージ処理
 /// </summary>
 /// <param name="damage"></param>
 /// <param name="battler"></param>
 public static void SkillDamage(int damage, BattlerSerializable battler)
 {
     Damage(damage, battler);
     //睡眠状態なら睡眠状態を解除する
     if (DeadCheck(battler) == false && StatusDictionary.IsSleep(battler))
     {
         RemoveStatus(StatusConsts.SLEEP, battler);
     }
 }
Exemple #2
0
 private static void WakeUpCheck(List <SkillDamages> damageses)
 {
     foreach (var damagese in damageses)
     {
         var battler = BattlerDictionary.GetBattlerByUniqId(damagese.targetUniqId);
         if (StatusDictionary.IsSleep(battler))
         {
             if (damagese.isHit)
             {
                 //HPにダメージを与えたか検索
                 var damage = damagese.SkillDamage.Find(x => x.valueTarget == SkillValueTarget.HP);
                 if (damage != null && damage.damage > 0)
                 {
                     RemoveStatus(StatusConsts.SLEEP, battler);
                 }
             }
         }
     }
 }