wiki.sine.space | sinespace

Scripting/SGameObject

From wiki.sine.space
Revision as of 21:59, 30 January 2021 by Voidtech (Talk | contribs) (Added and defined 61 properties + Added simple examples to 61 properties in SGameObject)

Jump to: navigation, search

The SGameObject class refers a single Game Object active within the scene.

Contents

Public Member Functions

Duplicate

SGameObject Duplicate ();

Copies the object and returns a reference to the copy. Equivalent to calling Instantiate() in Unity

local copy = Object.Duplicate();


Destroy

void Destroy ();

Schedules this object for deletion at the end of the frame

Object.Destroy();



AddLight

SLight AddLight ()

Adds a Light component to the object.

local obj = Space.Host.ExecutingObject;

-- add the Light component to the object if there is none
if obj.Light == null then

obj.AddLight();

end

Space.Log(obj.Light);

-- prints "SLight" to the console. Now we can work with the Light component on this object.



AddAudioSource

SAudioSource AddAudioSource ()

Adds an AudioSource component to the object.

local obj = Space.Host.ExecutingObject;

-- add the AudioSource component to the object if there is none
if obj.Audio == null then

obj.AddAudioSource();

end

Space.Log(obj.Audio);

-- prints "SAudioSource" to the console. Now we can work with the AudioSource component on this object.



AddClickable

SClickable AddClickable ()

Adds a Clickable component to the object.

local obj = Space.Host.ExecutingObject;

-- add the Clickable component to the object if there is none
if obj.Clickable == null then

obj.AddClickable();

end

Space.Log(obj.Clickable);

-- prints "SClickable" to the console. Now we can work with the Clickable component on this object.



AddRigidbody

SRigidbody AddRigidbody ()

Adds a Rigidbody component to the object.

local obj = Space.Host.ExecutingObject;

-- add the Rigidbody component to the object if there is none
if obj.Rigidbody == null then

obj.AddRigidbody();

end

Space.Log(obj.Rigidbody);

-- prints "SRigidbody" to the console. Now we can work with the Rigidbody component on this object.



AddNavMeshAgent

SNavMeshAgent AddNavMeshAgent ()

Adds a NavMeshAgent component to the object.

local obj = Space.Host.ExecutingObject;

-- add the NavMeshAgent component to the object if there is none
if obj.NavMeshAgent == null then

obj.AddNavMeshAgent();

end

Space.Log(obj.NavMeshAgent);

-- prints "SNavMeshAgent" to the console. Now we can work with the NavMeshAgent component on this object.



AddSeat

SSeat AddSeat ()

Adds a Seat component to the object.

local obj = Space.Host.ExecutingObject;

-- add the Seat component to the object if there is none
if obj.Seat == null then

obj.AddSeat();

end

Space.Log(obj.Seat);

-- prints "SSeat" to the console. Now we can work with the Seat component on this object.




SubscribeToEvents

void SubscribeToEvents ();

Causes this script to start listening to events on the object. Only use if you need to.

Space.Host.ExecutingObject.SubscribeToEvents()


OnAwake

void OnAwake (Action callback)

Binds a event to the Awake() event. Requires SubscribeToEvents be called first.

function F()
Space.Log("bound")
end
Space.Host.ExecutingObject.SubscribeToEvents()
Space.Host.ExecutingObject.OnAwake(F)


OnStart

void OnStart (Action callback)

Binds a event to the Start() event. Requires SubscribeToEvents be called first.

function F()
Space.Log("bound")
end
Space.Host.ExecutingObject.SubscribeToEvents()
Space.Host.ExecutingObject.OnStart(F)


OnEnable

void OnEnable (Action callback)

Binds a event to the OnEnable() event. Requires SubscribeToEvents be called first.

function F()
Space.Log("bound")
end
Space.Host.ExecutingObject.SubscribeToEvents()
Space.Host.ExecutingObject.OnEnable(F)


OnDisable

void OnDisable (Action callback)

Binds a event to the OnDisable() event. Requires SubscribeToEvents be called first.

function F()
Space.Log("bound")
end
Space.Host.ExecutingObject.SubscribeToEvents()
Space.Host.ExecutingObject.OnDisable(F)


OnFixedUpdate

void OnFixedUpdate (Action callback)

Binds a event to the OnFixedUpdate() event. Requires SubscribeToEvents be called first.

function F()
Space.Log("bound")
end
Space.Host.ExecutingObject.SubscribeToEvents()
Space.Host.ExecutingObject.OnFixedUpdate(F)


OnLateUpdate

void OnLateUpdate (Action callback)

Binds a event to the OnLateUpdate() event. Requires SubscribeToEvents be called first.

function F()
Space.Log("bound")
end
Space.Host.ExecutingObject.SubscribeToEvents()
Space.Host.ExecutingObject.OnLateUpdate(F)


OnUpdate

void OnUpdate (Action callback)

Binds a event to the OnUpdate() event. Requires SubscribeToEvents be called first.

function F()
Space.Log("bound")
end
Space.Host.ExecutingObject.SubscribeToEvents()
Space.Host.ExecutingObject.OnUpdate(F)


OnMouseDown

void OnMouseDown (Action callback)

Binds a event to the OnMouseDown() event. Requires SubscribeToEvents be called first.

function F()
Space.Log("bound")
end
Space.Host.ExecutingObject.SubscribeToEvents()
Space.Host.ExecutingObject.OnMouseDown(F)


Properties

Active

bool Active { get; set; }

Is this object Active in the scene

Object.Active = true;


Layer

int Layer { get; set; }

Gets/Sets the object onto a particular layer (0-31)

Space.Log("This object is on the layer " .. Object.Layer);


Tag

string Tag { get; }

Gets this objects Tag

Space.Log("Object Tag is " .. Object.Tag);


Name

string Name { get; set; }

Gets/sets the name of this object

Object.Name = "Hello World!";


Exists

bool Exists { get; }

Does this object still exist in the scene (returns false if the object has been deleted via Destroy();)

if(!Object.Exists) return;


Parent

SGameObject Parent { get; set; }

Gets/sets the parent GameObject of this object. Assign nil/null to set this as the root.

-- For this example, 2 separate Game Objects ("Cube", "Cube (1)") are used.

-- This Scripting Runtime is the component of the "Cube" object.
-- 1 Object Reference is used: Name: Cube1, references "Cube (1)".

local obj = Space.Host.ExecutingObject;

obj.Parent = Space.Host.GetReference("Cube1");

-- Now "Cube (1)" is the parent of "Cube" (can be observed in Hierarchy).


Root

SGameObject Root { get; }

Gets the root of this object group - may be this object.

-- For this example, 3 separate Game Objects ("Cube", "Cube (1)", "Cube (2)") are used.

-- "Cube" is the parent of "Cube (1)", "Cube (1)" is the parent of "Cube (2)"
-- This Scripting Runtime is the component of the "Cube (2)" object.

local obj = Space.Host.ExecutingObject;

Space.Log(obj.Root.Name);

-- prints "Cube" to the console


Children

[[Scripting/SGameObject[]|SGameObject[]]] Children { get; }

Returns the list of direct children of this object.

-- For this example, 3 separate Game Objects ("Cube", "Cube (1)", "Cube (2)") are used.

-- "Cube" is the parent of both "Cube (1)" and "Cube (2)" (in this order in the hierarchy).
-- This Scripting Runtime is the component of the "Cube" object.

local obj = Space.Host.ExecutingObject;

Space.Log(obj.Children[1].Name);
-- prints "Cube (1)" to the console
Space.Log(obj.Children[2].Name);

-- prints "Cube (2)" to the console



WorldPosition

SVector WorldPosition { get; set; }

Gets or sets the current position of this object relative to the scene

Space.Host.ExecutingObject.WorldPosition = Vector.New(1,1,1)


LocalPosition

SVector LocalPosition { get; set; }

Gets or sets the current position of this object relative to the objects parent, taking into account local position/scale/rotation

Space.Host.ExecutingObject.LocalPosition = Vector.New(1,1,1)


WorldRotation

SQuaternion WorldRotation { get; set; }

Gets or sets the current rotation of this object relative to the scene

Space.Host.ExecutingObject.WorldRotation = Quaternion.Euler(0,180,0)


LocalRotation

SQuaternion LocalRotation { get; set; }

Gets or sets the current rotation of this object relative to the parent object

Space.Host.ExecutingObject.LocalRotation = Quaternion.Euler(0,180,0)


LocalScale

SVector LocalScale { get; set; }

Gets or sets the current scale of this object relative to the parent

Space.Host.ExecutingObject.LocalScale = Vector.New(2,2,2)


WorldScale

SVector WorldScale { get; }

Gets the current scale of this object relative to the scene

worldScale = Space.Host.ExecutingObject.WorldScale 


Forward

SVector Forward { get; }

Returns the forward direction vector of this game object (blue arrow)

local obj = Space.Host.ExecutingObject;

obj.WorldRotation = Quaternion.Euler(0,0,0);
Space.Log(obj.Forward);
-- prints "[0,0,1]" to the console
obj.WorldRotation = Quaternion.Euler(0,90,0);
Space.Log(obj.Forward);

-- prints "[1,0,0]" to the console - now it points in the direction the Right directional vector was pointing in.



Up

SVector Up { get; }

Returns the up direction vector of this game object (green arrow)

local obj = Space.Host.ExecutingObject;

obj.WorldRotation = Quaternion.Euler(0,0,0);
Space.Log(obj.Up);
-- prints "[0,1,0]" to the console
obj.WorldRotation = Quaternion.Euler(90,0,0);
Space.Log(obj.Up);

-- prints "[0,0,1]" to the console - now it points in the direction the Forward directional vector was pointing in.



Right

SVector Right { get; }

Returns the right direction vector of this game object (red arrow)

local obj = Space.Host.ExecutingObject;

obj.WorldRotation = Quaternion.Euler(0,0,0);
Space.Log(obj.Right);
-- prints "[1,0,0]" to the console
obj.WorldRotation = Quaternion.Euler(0,0,90);
Space.Log(obj.Right);

-- prints "[0,1,0]" to the console - now it points in the direction the Up directional vector was pointing in.



Light

SLight Light { get; }

Returns a reference to a Light component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

-- add the Light component to the object if there is none
if obj.Light == null then

obj.AddLight ();

end

-- Now we can work with the Light component on this object.
-- For example, let's set its colour to Red:

obj.Light.Color = Vector.New(1,0,0);



Animator

SAnimator Animator { get; }

Returns a reference to a Animator component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

Space.Log(obj.Animator);

-- prints "SAnimator" to the console if there is an Animator component on this object, or an empty string, if there is none.


Audio

SAudioSource Audio { get; }

Returns a reference to a AudioSource component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

-- add the AudioSource component to the object if there is none
if obj.Audio == null then

obj.AddAudioSource();

end

Space.Log(obj.Audio);
-- Now we can work with the AudioSource component on this object.
-- For example, let's set its volume to 0.25:

obj.Audio.Volume = 0.25;



Browser

SBrowserSurface Browser { get; }

Returns a reference to a BrowserSurface component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

-- If this object has a BrowserSurface component, the script will reload the page in it
if obj.Browser ~= null then

obj.Browser.Reload ();
end



Renderer

SRenderer Renderer { get; }

Returns a reference to a Renderer component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

-- If this object has a Renderer component, let's colour its material blue!
if obj.Renderer ~= null then

obj.Renderer.Material.SetColor("_Color", 0, 0, 1, 1);
end



Clickable

SClickable Clickable { get; }

Returns a reference to a Clickable component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

-- add the Clickable component to the object if there is none
if obj.Clickable == null then

obj.AddClickable();

end

Space.Log(obj.Clickable);
--Now we can work with the Clickable component on this object.
-- Let's add an option for the object to be moved up by 1 every time that option is chosen:
local deltaPos = Vector.New(0,1,0);

function MoveItUp ()

obj.WorldPosition = obj.WorldPosition + deltaPos;

end

obj.Clickable.AddExtraAction ("Move up", "Moves the object up by 1.", MoveItUp);


Rigidbody

SRigidbody Rigidbody { get; }

Returns a reference to a Rigidbody component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

-- add the Rigidbody component to the object if there is none
if obj.Rigidbody == null then

obj.AddRigidbody();

end

Space.Log(obj.Rigidbody);
-- Now we can work with the Rigidbody component on this object.
-- Let's make it spin!
obj.Rigidbody.UseGravity = false;
obj.Rigidbody.AngularDrag = 0;

obj.Rigidbody.AngularVelocity = Vector.New(0,Space.Math.Pi/2,0);



Collider

SCollider Collider { get; }

Returns a reference to a Collider component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

-- If this object has a Collider component, let's make it a trigger:
if obj.Collider ~= null then

obj.Collider.IsTrigger = true;
end


UIText

SUIText UIText { get; }

Returns a reference to a UI.Text component on the object. Will return null if it does not exist.

uitext = Space.Host.ExecutingObject.UIText 



NavMeshAgent

SNavMeshAgent NavMeshAgent { get; }

Returns a reference to a NavMeshAgent component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

-- add the NavMeshAgent component to the object if there is none
if obj.NavMeshAgent == null then

obj.AddNavMeshAgent();

end

Space.Log(obj.NavMeshAgent);

-- prints "SNavMeshAgent" to the console. Now we can work with the NavMeshAgent component on this object.



Seat

SSeat Seat { get; }

Returns a reference to a Seat component on the object. Will return null if it does not exist.

local obj = Space.Host.ExecutingObject;

-- add the Seat component to the object if there is none
if obj.Seat == null then

obj.AddSeat();

end

Space.Log(obj.Seat);

-- prints "SSeat" to the console. Now we can work with the Seat component on this object.


Owner

long Owner { get; }

Returns the GameObject's Owner

Owner = Space.Host.ExecutingObject.Owner


LocalID

int LocalID { get; }

Returns the GameObject's Local ID

LocalID = Space.Host.ExecutingObject.LocalID


InventoryID

int InventoryID { get; }

Return's the GameObject's InventoryID

InventoryID = Space.Host.ExecutingObject.InventoryID


HasStableID

bool HasStableID { get; }

Returns true if GameObject has Stable ID

HasStableID = Space.Host.ExecutingObject.HasStableID


GlobalID

string GlobalID { get; }

Returns the global ID of the GameObject

GlobalID = Space.Host.ExecutingObject.GlobalID


HingeJoint

SHingeJoint HingeJoint { get; }

Returns a HingeJoint component attached to this object, or nil if none exist

HingeJoint = Space.Host.ExecutingObject.HingeJoint


Light

SLight Light { get; }

Returns a Light component attached to this object, or nil if none exist

Light = Space.Host.ExecutingObject.Light


ReflectionProbe

SReflectionProbe ReflectionProbe { get; }

Returns a ReflectionProbe component attached to this object, or nil if none exist

ReflectionProbe = Space.Host.ExecutingObject.ReflectionProbe


LightInChild

SLight LightInChild { get; }

Returns a Light component attached to this object or its children, or nil if none exist

LightInChild = Space.Host.ExecutingObject.LightInChild


LightInParent

SLight LightInParent { get; }

Returns a Light component attached to this object or it's parent, or nil if none exist

LightInParent = Space.Host.ExecutingObject.LightInParent


Floor

SRoomFloor Floor { get; }

Returns a RoomFloor component attached to this object, or nil if none exist

Floor = Space.Host.ExecutingObject.Floor


Animation

SAnimation Animation { get; }

Returns an Animation component attached to this object, or nil if none exist Animation is a legacy component and should not be confused with Animator

Animation = Space.Host.ExecutingObject.Animation


CanvasGroup

SCanvasGroup CanvasGroup { get; }

Returns Canvas Group component attached to this object, or nil if none exist

CanvasGroup = Space.Host.ExecutingObject.CanvasGroup


VoiceZone

SVoiceZone VoiceZone { get; }

Returns a VoiceZone component attached to this object, or nil if none exist

VoiceZone = Space.Host.ExecutingObject.VoiceZone


Director

SPlayableDirector Director { get; }

Returns a PlayableDirector component attached to this object, or nil if none exist

Director = Space.Host.ExecutingObject.Director


Vehicle

SModularVehicle Vehicle { get; }

Returns a Modular Vehicle component attached to this object, or nil if none exist

Vehicle = Space.Host.ExecutingObject.Vehicle


PostProcessVolume

SPostProcessVolume PostProcessVolume { get; }

Returns a Post Process Volume component attached to this object, or nil if none exist

PostProcessVolume = Space.Host.ExecutingObject.PostProcessVolume


Archimatix

SAXModel Archimatix { get; }

Returns a Archimatix Model ("AXModel" component) - or Nil if nothing exists

Archimatix = Space.Host.ExecutingObject.Archimatix


EmbeddedVideo

SEmbeddedVideo EmbeddedVideo { get; }

Returns a Embedded Video component attached to this object, or nil if none exist

EmbeddedVideo = Space.Host.ExecutingObject.EmbeddedVideo


Avatar

SAvatar Avatar { get; }

Return's GameObject's Avatar

Avatar = Space.Host.ExecutingObject.Avatar


AvatarAppearance

SAvatarAppearance AvatarAppearance { get; }

Returns a AvatarAppearance component attached to this object, or nil if none exist

AvatarAppearance = Space.Host.ExecutingObject.AvatarAppearance


Script

SScriptingRuntime Script { get; }

Returns a Scripting Runtime component attached to this object, or nil if none exist

Script = Space.Host.ExecutingObject.Script


StateMachine

long StateMachine { get; }

Returns a State Machine component attached to this object, or nil if none exist

StateMachine = Space.Host.ExecutingObject.StateMachine


Events

SScriptingEvents Events { get; }

Returns a Scripting Events component attached to this object, or nil if none exist

Events = Space.Host.ExecutingObject.Events


Data

SScriptingData Data { get; }

Returns a Scripting Data component attached to this object, or nil if none exist

Data = Space.Host.ExecutingObject.Data


BoxCollider

SBoxCollider BoxCollider { get; }

Returns a Box Collider component attached to this object, or nil if none exist

BoxCollider = Space.Host.ExecutingObject.BoxCollider


SphereCollider

SSphereCollider SphereCollider { get; }

Returns a Sphere Collider component attached to this object, or nil if none exist

SphereCollider = Space.Host.ExecutingObject.SphereCollider


CapsuleCollider

SCapsuleCollider CapsuleCollider { get; }

Returns a Capsule Collider component attached to this object, or nil if none exist

CapsuleCollider = Space.Host.ExecutingObject.CapsuleCollider


CharacterController

SCharacterController CharacterController { get; }

Returns a Character Controller component attached to this object, or nil if none exist

CharacterController = Space.Host.ExecutingObject.CharacterController


AudioReactive

SAudioReactiveBase AudioReactive { get; }

Returns the first Audio Reactive component attached to this object, or nil if none exist

AudioReactive = Space.Host.ExecutingObject.AudioReactive


AttachmentHelper

SAttachmentHelper AttachmentHelper { get; }

Returns the first Attachment Helper component attached to this object, or nil if none exist

AttachmentHelper = Space.Host.ExecutingObject.AttachmentHelper


AudioReactiveAnimation

SAudioReactiveAnimation AudioReactiveAnimation { get; }

Returns the first Audio Reactive Animation component attached to this object, or nil if none exist

AudioReactiveAnimation = Space.Host.ExecutingObject.AudioReactiveAnimation


AudioReactiveLight

SAudioReactiveLight AudioReactiveLight { get; }

Returns the first Audio Reactive Light component attached to this object, or nil if none exist

AudioReactiveLight = Space.Host.ExecutingObject.AudioReactiveLight


AudioReactiveParticleSystem

SAudioReactiveParticleSystem AudioReactiveParticleSystem { get; }

Returns the first Audio Reactive Particle System component attached to this object, or nil if none exist

AudioReactiveParticleSystem = Space.Host.ExecutingObject.AudioReactiveParticleSystem


AudioReactiveMaterial

SAudioReactiveMaterial AudioReactiveMaterial { get; }

Returns the first Audio Reactive Material component attached to this object, or nil if none exist

AudioReactiveMaterial = Space.Host.ExecutingObject.AudioReactiveMaterial


AudioReactiveTransform

SAudioReactiveTransform AudioReactiveTransform { get; }

Returns the first Audio Reactive Transform component attached to this object, or nil if none exist

AudioReactiveTransform = Space.Host.ExecutingObject.AudioReactiveTransform


TrailRenderer

STrailRenderer TrailRenderer { get; }

Returns a Unity component attached to this object, or nil if none exist

TrailRenderer = Space.Host.ExecutingObject.TrailRenderer


LineRenderer

SLineRenderer LineRenderer { get; }

Returns a Unity component attached to this object, or nil if none exist

LineRenderer = Space.Host.ExecutingObject.LineRenderer


UILayout

SUILayout UILayout { get; }

Returns a Renderer component attached to this object, or nil if none exist

UILayout = Space.Host.ExecutingObject.UILayout


UIToggle

SUIToggle UIToggle { get; }

Returns a Unity uGUI Toggle component attached to this object, or nil if none exist

UIToggle = Space.Host.ExecutingObject.UIToggle


UIDropdown

SUIDropdown UIDropdown { get; }

Returns a Unity uGUI Dropdown component attached to this object, or nil if none exist

UIDropdown = Space.Host.ExecutingObject.UIDropdown


UIButton

SUIButton UIButton { get; }

Returns a Unity uGUI Dropdown component attached to this object, or nil if none exist

UIButton = Space.Host.ExecutingObject.UIButton


UISlider

SUISlider UISlider { get; }

Returns a Unity uGUI Slider component attached to this object, or nil if none exist

UISlider = Space.Host.ExecutingObject.UISlider


UIScrollbar

SUIScrollbar UIScrollbar { get; }

Returns a Unity uGUI Scrollbar component attached to this object, or nil if none exist

UIScrollbar = Space.Host.ExecutingObject.UIScrollbar


UICanvas

SUICanvas UICanvas { get; }

Returns a Unity uGUI Canvas component attached to this object, or nil if none exist

UICanvas = Space.Host.ExecutingObject.UICanvas


UIImage

SUIImage UIImage { get; }

Returns a Unity uGUI Image component attached to this object, or nil if none exist

UIImage = Space.Host.ExecutingObject.UIImage


UIRawImage

SUIRawImage UIRawImage { get; }

Returns a Unity uGUI Text component attached to this object, or nil if none exist

UIRawImage = Space.Host.ExecutingObject.UIRawImage


UIInputField

SUIInputField UIInputField { get; }

Returns a Unity uGUI Text component attached to this object, or nil if none exist

UIInputField = Space.Host.ExecutingObject.UIInputField


VirtualCamera

SVirtualCamera VirtualCamera { get; }

Returns a VirtualCamera component attached to this object, or nil if none exists

VirtualCamera = Space.Host.ExecutingObject.VirtualCamera


Cloth

SCloth Cloth { get; }

Returns a Cloth component attached to this object, or nil if none exists

Cloth = Space.Host.ExecutingObject.Cloth


MeshRenderer

SMeshRenderer MeshRenderer { get; }

Returns a MeshRenderer component attached to this object, or nil if none exists

MeshRenderer = Space.Host.ExecutingObject.MeshRenderer


Furniture

SFurniture Furniture { get; }

Returns a Furniture component attached to this object, or nil if none exists

Furniture = Space.Host.ExecutingObject.Furniture


ParticleSystem

SParticleSystem ParticleSystem { get; }

Returns a ParticleSystem component attached to this object, or nil if none exists

ParticleSystem = Space.Host.ExecutingObject.ParticleSystem


NavMeshObstacle

SNavMeshObstacle NavMeshObstacle { get; }

Returns a NavMeshObstacle component attached to this object, or nil if none exists

NavMeshObstacle = Space.Host.ExecutingObject.NavMeshObstacle


RectTransform

SRectTransform RectTransform { get; }

Returns a RectTransform component attached to this object, or nil if none exists

RectTransform = Space.Host.ExecutingObject.RectTransform


SkinnedMeshRenderer

SSkinnedMeshRenderer SkinnedMeshRenderer { get; }

Returns a SkinnedMeshRenderer component attached to this object, or nil if none exists

SkinnedMeshRenderer = Space.Host.ExecutingObject.SkinnedMeshRenderer


Radio

SSceneBackgroundMusic Radio { get; }

Returns a SceneBackgroundMusic component attached to this object, or nil if none exists

Radio = Space.Host.ExecutingObject.Radio


Terrain

STerrain Terrain { get; }

Returns a Terrain component attached to this object, or nil if none exists

Terrain = Space.Host.ExecutingObject.Terrain


Alive

bool Alive { get; }

Returns true if GameObject is Alive

Alive = Space.Host.ExecutingObject.Alive


ActiveSelf

bool ActiveSelf { get;set; }

Returns true if GameObject is Active (even if it's parent is not active)

ActiveSelf = Space.Host.ExecutingObject.ActiveSelf


EventCalendar

SEventCalendar EventCalendar { get; }

Returns an EventCalendar component attached to this object, or nil if none exists

EventCalendar = Space.Host.ExecutingObject.EventCalendar