Attribute for use on Fusion.Behaviour classes. Automatically creates a button in the inspector of Behaviour derived classes. Can be used on Fields or Method member types. For fields, the name of the method the button will execute must be supplied. When used on methods, that method will be called.
More...
Inherits BehaviourActionAttribute.
|
| BehaviourButtonActionAttribute (string buttonName, bool showWhileRunning, bool showWhileNotRunning, string conditionMember=null) |
| Define a ButtonBehaviourAction. More...
|
|
| BehaviourButtonActionAttribute (string buttonName, string executeMethod, bool showWhileRunning, bool showWhileNotRunning, string conditionMember=null) |
| Define a ButtonBehaviourAction. More...
|
|
| BehaviourButtonActionAttribute (string buttonName, string executeMethod=null, string conditionMember=null) |
| Define a ButtonBehaviourAction. More...
|
|
| BehaviourActionAttribute (string conditionMember=null, ActionFlags flags=ActionFlags.ShowAtNotRuntime|ActionFlags.ShowAtRuntime) |
| Define a BehaviourAction, with the action being the method this attribute is attached to. More...
|
|
Attribute for use on Fusion.Behaviour classes. Automatically creates a button in the inspector of Behaviour derived classes. Can be used on Fields or Method member types. For fields, the name of the method the button will execute must be supplied. When used on methods, that method will be called.
◆ BehaviourButtonActionAttribute() [1/3]
Define a ButtonBehaviourAction.
- Parameters
-
buttonName | The name that will be displayed on the button. |
executeMethod | The name of the method to execute. If excluded, this will be the method this attribute is on. |
conditionMember | The name of the member (in the same class) to evaluate, to determine if the action should be performed. Typically null, as the action method can have its own logic. |
◆ BehaviourButtonActionAttribute() [2/3]
BehaviourButtonActionAttribute |
( |
string |
buttonName, |
|
|
string |
executeMethod, |
|
|
bool |
showWhileRunning, |
|
|
bool |
showWhileNotRunning, |
|
|
string |
conditionMember = null |
|
) |
| |
Define a ButtonBehaviourAction.
- Parameters
-
buttonName | The name that will be displayed on the button. |
showWhileRunning | Indicates if this button should appear while playing. |
showWhileNotRunning | Indicates if this button should appear while not playing. |
executeMethod | The name of the method to execute. If excluded, this will be the method this attribute is on. |
conditionMember | The name of the member (in the same class) to evaluate, to determine if the action should be performed. Typically null, as the action method can have its own logic. |
◆ BehaviourButtonActionAttribute() [3/3]
Define a ButtonBehaviourAction.
- Parameters
-
buttonName | The name that will be displayed on the button. |
showWhileRunning | Indicates if this button should appear while playing. |
showWhileNotRunning | Indicates if this button should appear while not playing. |
conditionMember | The name of the member (in the same class) to evaluate, to determine if the action should be performed. Typically null, as the action method can have its own logic. This member can be a property, field or method. The return value of any of these is converted into a double. True = 1, False = 0. Null = 0. |