internal FinalDPS(ParsedEvtcLog log, long start, long end, AbstractSingleActor actor, AbstractSingleActor target) { double phaseDuration = (end - start) / 1000.0; (Damage, PowerDamage, CondiDamage, StrikeDamage, LifeLeechDamage, BarrierDamage) = ComputeDamageFrom(log, actor.GetDamageEvents(target, log, start, end)); (ActorDamage, ActorPowerDamage, ActorCondiDamage, ActorStrikeDamage, ActorLifeLeechDamage, ActorBarrierDamage) = ComputeDamageFrom(log, actor.GetJustActorDamageEvents(target, log, start, end)); if (phaseDuration > 0) { Dps = (int)Math.Round(Damage / phaseDuration); CondiDps = (int)Math.Round(CondiDamage / phaseDuration); PowerDps = (int)Math.Round(PowerDamage / phaseDuration); StrikeDps = (int)Math.Round(StrikeDamage / phaseDuration); LifeLeechDps = (int)Math.Round(LifeLeechDamage / phaseDuration); BarrierDps = (int)Math.Round(BarrierDamage / phaseDuration); // ActorDps = (int)Math.Round(Damage / phaseDuration); ActorCondiDps = (int)Math.Round(ActorCondiDamage / phaseDuration); ActorPowerDps = (int)Math.Round(ActorPowerDamage / phaseDuration); ActorStrikeDps = (int)Math.Round(ActorStrikeDamage / phaseDuration); ActorLifeLeechDps = (int)Math.Round(ActorLifeLeechDamage / phaseDuration); ActorBarrierDps = (int)Math.Round(ActorBarrierDamage / phaseDuration); } // Breakbar BreakbarDamage = Math.Round(actor.GetBreakbarDamageEvents(target, log, start, end).Sum(x => x.BreakbarDamage), 1); ActorBreakbarDamage = Math.Round(actor.GetJustActorBreakbarDamageEvents(target, log, start, end).Sum(x => x.BreakbarDamage), 1); }
internal FinalDPS(ParsedEvtcLog log, long start, long end, AbstractSingleActor actor, AbstractSingleActor target) { double phaseDuration = (end - start) / 1000.0; int damage; double dps = 0.0; IReadOnlyList <AbstractHealthDamageEvent> damageLogs = actor.GetDamageEvents(target, log, start, end); //DPS damage = damageLogs.Sum(x => x.HealthDamage); if (phaseDuration > 0) { dps = damage / phaseDuration; } Dps = (int)Math.Round(dps); Damage = damage; //Condi DPS damage = damageLogs.Sum(x => x.ConditionDamageBased(log) ? x.HealthDamage : 0); if (phaseDuration > 0) { dps = damage / phaseDuration; } CondiDps = (int)Math.Round(dps); CondiDamage = damage; //Power DPS damage = Damage - CondiDamage; if (phaseDuration > 0) { dps = damage / phaseDuration; } PowerDps = (int)Math.Round(dps); PowerDamage = damage; IReadOnlyList <AbstractHealthDamageEvent> actorDamageLogs = actor.GetJustActorDamageEvents(target, log, start, end); // Actor DPS damage = actorDamageLogs.Sum(x => x.HealthDamage); if (phaseDuration > 0) { dps = damage / phaseDuration; } ActorDps = (int)Math.Round(dps); ActorDamage = damage; //Actor Condi DPS damage = actorDamageLogs.Sum(x => x.ConditionDamageBased(log) ? x.HealthDamage : 0); if (phaseDuration > 0) { dps = damage / phaseDuration; } ActorCondiDps = (int)Math.Round(dps); ActorCondiDamage = damage; //Actor Power DPS damage = ActorDamage - ActorCondiDamage; if (phaseDuration > 0) { dps = damage / phaseDuration; } ActorPowerDps = (int)Math.Round(dps); ActorPowerDamage = damage; // Breakbar BreakbarDamage = Math.Round(actor.GetBreakbarDamageEvents(target, log, start, end).Sum(x => x.BreakbarDamage), 1); ActorBreakbarDamage = Math.Round(actor.GetJustActorBreakbarDamageEvents(target, log, start, end).Sum(x => x.BreakbarDamage), 1); }