BooltonAttribute¶
Namespace:
SideXP.Core| Inherits from:PropertyAttribute
Displays a button to enable/disable a boolean value instead of the regular
Constructors¶
BooltonAttribute()¶
Displays a button to enable/disable a boolean value instead of the regular
BooltonAttribute(string)¶
Displays a button to enable/disable a boolean value instead of the regular
Parameters
callbackName
Properties¶
CallbackName¶
The name of the function to call (from this script) when the button is clicked.
Remarks
The callback can be a function (no return type and a single boolean parameter), or a boolean setter.
Toggle¶
By default, a button with a label "Enable/Disable" will be displayed for this property. If this option is enabled, a regular toggle field will be used, so the named callback can still be invoked without changing the common usage of this property.