Пример #1
0
 public Attack(BattleParticipant source, AttackType type, IEnumerable <EquipmentInfo> equipmentUsed, IEnumerable <Hit> hits)
 {
     Source        = source;
     SourceHP      = source?.ToHP;
     Type          = type;
     EquipmentUsed = equipmentUsed.ToArray();
     Hits          = hits.ToArray();
 }
Пример #2
0
 public Hit(BattleParticipant source, BattleParticipant target, RawHit raw)
 {
     Target       = target;
     IsCritical   = raw.IsCritical;
     IsProtection = raw.IsProtection;
     Damage       = raw.Damage;
     FromHP       = target.ToHP;
     source?.DoDamage(Damage);
     (ToHP, Recover) = target.GetDamage(Damage);
 }