protected override List <Lifetime> CreateLifetimes(ModifierInfo modifierInfo) { RagdollInfo ri = (RagdollInfo)modifierInfo; lifetime = new UnpredictableDurationLifetime(); return(new List <Lifetime>(new[] { lifetime })); }
protected override List <Lifetime> CreateLifetimes(ModifierInfo modifierInfo) { List <Lifetime> lifetimes = base.CreateLifetimes(modifierInfo); gaugeLifetime = new UnpredictableDurationLifetime(); lifetimes.Add(gaugeLifetime); return(lifetimes); }
public IncreaseLyingDuration(UnpredictableDurationLifetime subLifetime, float duration, Entity targetEntity) { this.subLifetime = subLifetime; this.duration = duration; StatsComponent sc = targetEntity.GetComponent <StatsComponent>(); bool found; extraLying = sc.CharacterStats.FindStats(StatsType.ExtraLyingDuration, out found); if (found) { vm = extraLying.AddModifier(StatsModifierOperator.Addition, duration); } }
protected override List <Lifetime> CreateLifetimes(ModifierInfo modifierInfo) { DamageOverTimeInfo doti = (DamageOverTimeInfo)modifierInfo; StatsComponent casterStatsComponent = casterEntity.GetComponent <StatsComponent>(); Stats casterBurnDurationUpScaleStats = casterStatsComponent.CharacterStats.FindStats(StatsType.BurnDurationUpScale); StatsComponent targetStatsComponent = targetEntity.GetComponent <StatsComponent>(); Stats targetBurnDurationDownScaleStats = targetStatsComponent.CharacterStats.FindStats(StatsType.BurnDurationDownScale); float duration = doti.DotModifierConfig.ShowDurationInSeconds(); _1HpLifetime = new UnpredictableDurationLifetime(); return(new List <Lifetime>(new Lifetime[] { new DurationBasedLifetime( duration * (1 + targetBurnDurationDownScaleStats.BakedFloatValue) * (1 + casterBurnDurationUpScaleStats.BakedFloatValue) ), _1HpLifetime })); }