Sinespace Client  2023.2.17543
Client-side scripting for Sinespace
SineSpace.Scripting.Components.SRoomFloor Class Reference
Inheritance diagram for SineSpace.Scripting.Components.SRoomFloor:
ScriptClassComponent< RoomFloorBaseInternal >

Properties

bool Enabled [get, set]
 Status of enable or disable room floor component More...
 
string Name [get]
 Name of this floor More...
 
string Description [get]
 Description of this floor. More...
 
bool IsDefaultFloor [get]
 Is this default floor? More...
 
SGameObject[] Furniture [get]
 Get all furniture game objects More...
 
int Owner [get]
 Return the ID of the user account that owns this room floor, if any. More...
 
- Properties inherited from ScriptClassComponent< RoomFloorBaseInternal >
SGameObject GameObject [get]
 Return the GameObject which component added. More...
 

Property Documentation

◆ Description

string SineSpace.Scripting.Components.SRoomFloor.Description
get

Description of this floor.

&ndash;get first order floor
floor = Space.Scene.Floors[0].Floor
&ndash;output the description of this floor
Space.Log(floor.Description)

◆ Enabled

bool SineSpace.Scripting.Components.SRoomFloor.Enabled
getset

Status of enable or disable room floor component

&ndash;get first order floor
floor = Space.Scene.Floors[0].Floor
&ndash;disable floor component
floor.Enabled = false

◆ Furniture

SGameObject [] SineSpace.Scripting.Components.SRoomFloor.Furniture
get

Get all furniture game objects

&ndash;get first order floor
floor = Space.Scene.Floors[0].Floor
&ndash;get all furniture in this floor, and output the name one of them
if floor.Furniture ~=nil and #floor.Furniture > 0 then
Space.Log(floor.Furniture[0].Name)
end

◆ IsDefaultFloor

bool SineSpace.Scripting.Components.SRoomFloor.IsDefaultFloor
get

Is this default floor?

&ndash;get first order floor
floor = Space.Scene.Floors[0].Floor
&ndash;output this floor is default floor or not
Space.Log(floor.IsDefaultFloor)

◆ Name

string SineSpace.Scripting.Components.SRoomFloor.Name
get

Name of this floor

&ndash;get first order floor
floor = Space.Scene.Floors[0].Floor
&ndash;output name of this floor
Space.Log(floor.Name)

◆ Owner

int SineSpace.Scripting.Components.SRoomFloor.Owner
get

Return the ID of the user account that owns this room floor, if any.

&ndash;get first order floor
floor = Space.Scene.Floors[0].Floor
&ndash;Check if player is the owner of this floor, output name if they are.
if floor.Owner == Space.Scene.PlayerAvatar.ID then
Space.Log(floor.Furniture[0].Name)
end