(Created page with "=Properties= {{ScriptFunction|bool|Enabled|[get, set]|Returns true if the Attachment Helper Enabled.|5=local Object = Space.Scene.Find("SCRIPT_OBJECT")<br> Space.Log(Object.At...") |
|||
Line 1: | Line 1: | ||
=Properties= | =Properties= | ||
− | {{ScriptFunction|bool|Enabled|[get, set]|Returns true if the Attachment Helper Enabled.|5 | + | {{ScriptFunction|bool|Enabled|[get, set]|Returns true if the Attachment Helper Enabled.|5= Space.Host.ExecutingObject.AttachmentHelper.Enabled = false|6=<pre>--clicking this object will Enable/Disable it's Attachment Helper component |
− | Space. | + | thisGameObject = Space.Host.ExecutingObject |
+ | attachmenthelper = thisGameObject.AttachmentHelper | ||
+ | |||
+ | |||
+ | OnClick = function() | ||
+ | attachmenthelper.Enabled = not attachmenthelper.Enabled | ||
+ | end | ||
+ | |||
+ | |||
+ | thisGameObject.AddClickable() | ||
+ | thisGameObject.Clickable.OnClick(OnClick)</pre>) | ||
}} | }} | ||
{{Scripting Navbox}} | {{Scripting Navbox}} |
Returns true if the Attachment Helper Enabled.
--clicking this object will Enable/Disable it's Attachment Helper component thisGameObject = Space.Host.ExecutingObject attachmenthelper = thisGameObject.AttachmentHelper OnClick = function() attachmenthelper.Enabled = not attachmenthelper.Enabled end thisGameObject.AddClickable() thisGameObject.Clickable.OnClick(OnClick))
|