StatsAndEffects.UnsubscribeFromAttributeChange
Declaration#
public virtual void UnsubscribeFromAttributeChange(SimpleEvent handler, string attributeId)Parameters#
| Name | Description |
|---|---|
| handler | Handler to remove |
| attributeId | Id of attribute |
Description#
Remove subscription from Attribute changes
Usage#
Example
using NullSave.GDTK.Stats;using UnityEngine;
public class Example : MonoBehaviour{
public void ExampleMethod(StatsAndEffects source) { string id = source.database.attributes[0].info.id; source.UnsubscribeFromAttributeChange(AttributeChange, id); }
private void AttributeChange() { Debug.Log("Attribute has been added or removed."); }
}