Breakroom is now Sinewave Campus. Book a meeting

SScriptingEvents

ClientComponents
On this classInvokeEvent
  1. Functions
  2. InvokeEvent
  3. Properties
  4. Enabled
  5. Events
  6. ComponentName
  7. GameObject
Members 5
FunctionInvokeEventInvoke the event with its name
PropertyEnabledWhether the scriptingEvents component is enabled or not
PropertyEventsReturns a list of events
PropertyComponentNameThe name of this component.
PropertyGameObject–

Functions​

InvokeEvent​

void InvokeEvent(string name)

Invoke the event with its name

Parameters

NameTypeDefault
namestring–

Returns

void

Example

Lua
Space.Host.ExecutingObject.Events.InvokeEvent("EventName")

Properties​

Enabled​

bool Enabled {get; set; }

Whether the scriptingEvents component is enabled or not

Example

Lua
Space.Host.ExecutingObject.Events.Enabled = true

EventsRead only​

string[] Events {get; }

Returns a list of events

Example

Lua
eventNames = Space.Host.ExecutingObject.Events.Events

ComponentNameRead only​

string ComponentName {get; }

The name of this component.

Example

Lua
componentName = Space.Host.ExecutingObject.Events.ComponentName

GameObjectRead only​

SGameObject GameObject {get; }

Example

Lua
theGameObject = Space.Host.ExecutingObject.Events.GameObject