Namespace ElectricDrill.AstraRpgFramework.Attributes
Classes
- AttributeSO
Represents a character attribute that extends BoundedValue functionality. An attribute is a measurable characteristic such as strength, dexterity, luck, and so on. Can have a min and a max value.
- AttributeSetInstance
Represents a runtime instance of an AttributeSet with actual values for each attribute. Provides methods to manipulate and access attribute values during gameplay.
- AttributeSetInstanceExtensions
Extension methods for converting SerializableDictionary to AttributeSetInstance.
- AttributeSetSO
A ScriptableObject that defines a collection of attributes for use in character systems. Attribute sets are usually used to group attributes that can be shared across different characters or classes. For example, any character of any class could have the same attribute set, including attributes like strength, dexterity, constitution, intelligence, and luck.
- EntityAttributes
Manages the attributes of an entity. This component calculates attribute values by combining base values, flat modifiers, percentage modifiers, and spent attribute points. It requires an ElectricDrill.AstraRpgFramework.Attributes.EntityAttributes.EntityCore component on the same GameObject.
Structs
- AttributeChangeInfo
Immutable structure that contains information about an attribute value change. Used to track and communicate attribute modifications across the system and for payload-aware condition evaluation.
- EntityAttributes.BulkUpdateScope
Disposable bracket returned by BeginBulk(). Dispose flushes deferred events when the outermost bracket closes. Declared as a ref struct so it cannot be boxed or captured across async boundaries — each bracket must be confined to a single stack frame.
Interfaces
- IAttributeReader
Read-only interface for querying attribute values from an entity. Use TryGet(AttributeSO, out long) as the safe access path;
Getrequires Contains(T) to be checked first.
- IHasAttributeSet
Interface for objects that expose an AttributeSet definition.