ドキュメント

Unity Engine

Unity Engine

OnConditionChanged()

Called after the condition's data changes and the built-in UI has refreshed to reflect it.
読み終わるまでの所要時間 1 分最終更新 2ヶ月前

Definition

public virtual void OnConditionChanged()

Remarks

Fires after an edit recorded through StateMachine.UndoBeginRecordStateMachine and StateMachine.UndoEndRecordStateMachine is applied to ConditionView<T>.Condition — whether the edit came from the built-in UI (typing in the value field, picking a comparison operator) or from your own code. Override this to refresh custom UI you added in ConditionView<T>.OnViewBuilt so it reflects the condition's current data. Unlike ConditionView<T>.OnViewBuilt, this can fire many times over the view's lifetime.

Examples

public override void OnConditionChanged(){ m_IconImage.image = Condition.Icon;}