Class AttributeSetInstanceExtensions
- Namespace
- ElectricDrill.AstraRpgFramework.Attributes
- Assembly
- com.electricdrill.astra-rpg-framework.Runtime.dll
Extension methods for converting SerializableDictionary to AttributeSetInstance.
public static class AttributeSetInstanceExtensions
- Inheritance
-
objectAttributeSetInstanceExtensions
Methods
ToAttributeSetInstance(SerializableDictionary<Attribute, long>, AttributeSet)
Converts a SerializableDictionary of attributes to an AttributeSetInstance. Validates that all attributes from the AttributeSet are present in the dictionary.
public static AttributeSetInstance ToAttributeSetInstance(this SerializableDictionary<Attribute, long> dictionary, AttributeSet attributeSet)
Parameters
dictionarySerializableDictionary<Attribute, long>The dictionary to convert
attributeSetAttributeSetThe AttributeSet to validate against
Returns
- AttributeSetInstance
A new AttributeSetInstance with values from the dictionary