Show / Hide Table of Contents

Class BonusEffectCappedMultiplicative

Level-aware multiplicative effect with a cap. Applies a fixed multiplier (Value) per SourceLevel, but clamps the cumulative multiplier at Cap. For cost reductions (LowerIsBetter=true), Cap is a floor (e.g. 0.5 = never below 50%). For yield boosts (LowerIsBetter=false), Cap is a ceiling (e.g. 1.5 = never above 150%). Once the cap is reached, further levels have no additional effect — pair with BonusEffectDiminishing on a separate bonus for post-cap scaling.

Inheritance
System.Object
BonusEffect
BonusEffectCappedMultiplicative
Implements
IDescribable
Inherited Members
BonusEffect.IDescribable.Description()
BonusEffect.LowerIsBetter
Namespace: Eco.Gameplay.Bonuses
Assembly: Eco.Gameplay.dll
Syntax
public class BonusEffectCappedMultiplicative : BonusEffect, IDescribable

Constructors

BonusEffectCappedMultiplicative()

Declaration
public BonusEffectCappedMultiplicative()

Properties

Cap

Cumulative multiplier limit. For costs (Value < 1): floor; for yields (Value > 1): ceiling. Defaults to 1 (no cap).

Declaration
public float Cap { get; set; }
Property Value
Type Description
System.Single

OrderOfOperations

Declaration
public override float OrderOfOperations { get; }
Property Value
Type Description
System.Single
Overrides
BonusEffect.OrderOfOperations

ScalesWithTalentLevel

Declaration
public override bool ScalesWithTalentLevel { get; }
Property Value
Type Description
System.Boolean
Overrides
BonusEffect.ScalesWithTalentLevel

Value

Per-level multiplier. Examples: 0.9f = 10% reduction per level, 1.1f = 10% increase per level.

Declaration
public float Value { get; set; }
Property Value
Type Description
System.Single

Methods

Description(BonusContext)

Declaration
public override LocString Description(BonusContext context = null)
Parameters
Type Name Description
BonusContext context
Returns
Type Description
LocString
Overrides
BonusEffect.Description(BonusContext)

TransformValue(BonusContext, Single)

Declaration
public override float TransformValue(BonusContext context, float val)
Parameters
Type Name Description
BonusContext context
System.Single val
Returns
Type Description
System.Single
Overrides
BonusEffect.TransformValue(BonusContext, Single)

Implements

IDescribable

Extension Methods

TagUtils.TagNames(Object, Boolean)
TagUtils.TagDisplayNames(Object, Boolean)
ClientSetViewExtensions.SetClassOfProperty(Object, Player, String, String, Int32)
TypeTooltipExtensions.UILinkGeneric(Object)
☀
☾
In This Article
Back to top
Copyright (c) Strange Loop Games 2021
☀
☾