Breakroom is now Sinewave Campus. Book a meeting

SPublicRegion

客户端类型
在此类中ID
  1. 属性
  2. ID
  3. OwnerID
  4. Name
  5. MapPath
  6. PreviewPath
  7. RankingScore
  8. MaxAvatars
  9. FileSize
  10. Memory
  11. Landmarks
  12. Regions
  13. Description
  14. Access
成员 13
属性IDThe Region ID of this region
属性OwnerIDThe ID of the owner of this region
属性NameThe Name of this region
属性MapPath–
属性PreviewPath–
属性RankingScoreThe Ranking Score of the region.
属性MaxAvatarsThe max number of avatars this region can hold.
属性FileSizeThe current MBs the region is using.
属性Memory–
属性LandmarksAn array of Landmarks in the region.
属性RegionsReturns an array of SSubRegion in the region.
属性DescriptionReturns the description of the region.
属性AccessThe access type of the region (such as "Public" or "Approved only")

属性​

ID只读​

int ID {get; }

The Region ID of this region

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionID = r.ID
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

OwnerID只读​

int OwnerID {get; }

The ID of the owner of this region

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionOwnerID = r.OwnerID
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

Name只读​

string Name {get; }

The Name of this region

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionName = r.Name
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

MapPath只读​

string MapPath {get; }

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionMapPath = r.MapPath
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

PreviewPath只读​

string PreviewPath {get; }

示例

Lua
--Make's a UIText show the Preview Path of the user's first available region

textObject = Space.Host.GetReference("TheTextReference")

function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionPreviewPath = r.PreviewPath
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

RankingScore只读​

int RankingScore {get; }

The Ranking Score of the region.

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionRankingScore = r.RankingScore
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

MaxAvatars只读​

int MaxAvatars {get; }

The max number of avatars this region can hold.

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionMaxAvatars = r.MaxAvatars
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

FileSize只读​

int FileSize {get; }

The current MBs the region is using.

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionFileSize = r.FileSize
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

Memory只读​

int Memory {get; }

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionMemory = r.Memory
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

Landmarks只读​

SLandmark[] Landmarks {get; }

An array of Landmarks in the region.

示例

``` function GetUserRegionsComplete(SUserRegions) local r = SUserRegions.AvailableRegions[1] regionLandmarks = r.Landmarks end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete) ```

Regions只读​

SSubRegion[] Regions {get; }

Returns an array of SSubRegion in the region.

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionSubRegions = r.Regions
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

Description只读​

string Description {get; }

Returns the description of the region.

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionDescription = r.Description
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)

Access只读​

int Access {get; }

The access type of the region (such as "Public" or "Approved only")
1= Disabled, 2= FreeForall, 3= FriendsOnly, 4= ApprovedOnly, 5= GroupsOnly

示例

Lua
function GetUserRegionsComplete(SUserRegions)
local r = SUserRegions.AvailableRegions[1]
regionAccessType = r.Access
end

Space.Grid.GetEnabledUserRegions(GetUserRegionsComplete)