public BuffClockDecaying(BuffForNode buffNode, IBehaviourContext buffNodeContext) { Ticks = buffNode.Ticks[buffNodeContext].Value; Duration = buffNode.Duration[buffNodeContext].Value; TimeRemaining = Duration; }
public Buff(BuffForNode buffNode, IBehaviourContext context) { buffTemplate = buffNode.BuffToApply; buffTemplate.SetupGraph(this); buffInput = buffTemplate.GetNode <BuffInputNode>(); buffInput.Target[this].Value = buffNode.Target[context].Value; BaseStackSize.onChanged += RecalculateStackSize; OnRemove += () => { buffTemplate.RemoveGraph(this); }; buffInput.SetTarget(this, this); }