Beispiel #1
0
 /// <inheritdoc/>
 public float this[AttributeDefinition attributeDefinition]
 {
     get => this.GetValueOfAttribute(attributeDefinition);
Beispiel #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="StatAttribute"/> class.
 /// </summary>
 /// <param name="definition">The definition.</param>
 /// <param name="baseValue">The base value.</param>
 public StatAttribute(AttributeDefinition definition, float baseValue)
     : base(definition, AggregateType.AddRaw)
 {
     this.statValue = baseValue;
 }
Beispiel #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BaseAttribute"/> class.
 /// </summary>
 /// <param name="definition">The definition.</param>
 /// <param name="aggregateType">Type of the aggregate.</param>
 protected BaseAttribute(AttributeDefinition definition, AggregateType aggregateType)
 {
     this.Definition    = definition;
     this.AggregateType = aggregateType;
 }
Beispiel #4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ComposableAttribute"/> class.
 /// </summary>
 /// <param name="definition">The definition.</param>
 public ComposableAttribute(AttributeDefinition definition)
     : base(definition, AggregateType.AddRaw)
 {
     this.elementList = new List <IElement>();
 }
Beispiel #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AttributeRelationship" /> class.
 /// </summary>
 /// <param name="targetAttribute">The target attribute.</param>
 /// <param name="inputOperand">The multiplier.</param>
 /// <param name="inputAttribute">The input attribute.</param>
 /// <param name="inputOperator">The input operator.</param>
 public AttributeRelationship(AttributeDefinition targetAttribute, float inputOperand, AttributeDefinition inputAttribute, InputOperator inputOperator)
 {
     this.InputOperand    = inputOperand;
     this.InputOperator   = inputOperator;
     this.targetAttribute = targetAttribute;
     this.inputAttribute  = inputAttribute;
 }
Beispiel #6
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AttributeRelationship" /> class.
 /// </summary>
 /// <param name="targetAttribute">The target attribute.</param>
 /// <param name="inputOperand">The multiplier.</param>
 /// <param name="inputAttribute">The input attribute.</param>
 public AttributeRelationship(AttributeDefinition targetAttribute, float inputOperand, AttributeDefinition inputAttribute)
     : this(targetAttribute, inputOperand, inputAttribute, InputOperator.Multiply)
 {
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="ConstValueAttribute" /> class.
 /// </summary>
 /// <param name="value">The value.</param>
 /// <param name="definition">The definition.</param>
 public ConstValueAttribute(float value, AttributeDefinition definition)
 {
     this.Value      = value;
     this.definition = definition;
 }