C# Class Forge.Unity.LevelDesigner

Inheritance: UnityEngine.MonoBehaviour
显示文件 Open project: jacobdufault/forge-unity

Public Properties

Property Type Description
LevelTemplatePath string
SavedLevelTemplateState string
SavedSharedTemplateState string
SavedSnapshotState string
SharedTemplatePath string
SnapshotPath string

Private Properties

Property Type Description
FindChild UnityEngine.GameObject
PrepareForRestoration void

Public Methods

Method Description
AddEntity ( ) : void

Adds an entity to the current snapshot.

AddLevelTemplate ( ) : void

Adds a template to the current level template group.

AddSharedTemplate ( ) : void

Adds a template to the current shared template group.

ClearLevelTemplates ( ) : void

Removes the level template group.

ClearSharedTemplates ( ) : void

Removes the shared template group.

ClearSnapshot ( ) : void

Removes the current level.

CreateLevelTemplateGroup ( ) : void

Creates a new empty level template group.

CreateSharedTemplateGroup ( ) : void

Creates a new empty shared template group.

CreateSnapshot ( ) : void

Creates a new empty snapshot.

ExportLevelTemplates ( ) : void

Writes the current state of the level templates to the template path.

ExportSharedTemplates ( ) : void

Writes the current state of the shared templates to the template path.

ExportSnapshot ( ) : void

Exports the current level reference to the export path.

ImportLevelTemplates ( string templateJson ) : void

Imports level templates using the given template JSON.

ImportSharedTemplates ( string templateJson ) : void

Imports shared templates using the given template JSON.

ImportSnapshot ( string snapshotJson ) : void
OnEntityDestroyed ( EntityContainer container ) : void
OnTemplateDestroyed ( ITemplate template ) : void

Protected Methods

Method Description
OnDisable ( ) : void
Update ( ) : void

Private Methods

Method Description
FindChild ( string name ) : GameObject

Finds or creates a child entity with the given name (relative to this game object).

PrepareForRestoration ( ) : void

Prepares the restoration state and clears out entity/template containers in preparation either a Unity serialization cycle or entering play mode.

Method Details

AddEntity() public method

Adds an entity to the current snapshot.
public AddEntity ( ) : void
return void

AddLevelTemplate() public method

Adds a template to the current level template group.
public AddLevelTemplate ( ) : void
return void

AddSharedTemplate() public method

Adds a template to the current shared template group.
public AddSharedTemplate ( ) : void
return void

ClearLevelTemplates() public method

Removes the level template group.
public ClearLevelTemplates ( ) : void
return void

ClearSharedTemplates() public method

Removes the shared template group.
public ClearSharedTemplates ( ) : void
return void

ClearSnapshot() public method

Removes the current level.
public ClearSnapshot ( ) : void
return void

CreateLevelTemplateGroup() public method

Creates a new empty level template group.
public CreateLevelTemplateGroup ( ) : void
return void

CreateSharedTemplateGroup() public method

Creates a new empty shared template group.
public CreateSharedTemplateGroup ( ) : void
return void

CreateSnapshot() public method

Creates a new empty snapshot.
public CreateSnapshot ( ) : void
return void

ExportLevelTemplates() public method

Writes the current state of the level templates to the template path.
public ExportLevelTemplates ( ) : void
return void

ExportSharedTemplates() public method

Writes the current state of the shared templates to the template path.
public ExportSharedTemplates ( ) : void
return void

ExportSnapshot() public method

Exports the current level reference to the export path.
public ExportSnapshot ( ) : void
return void

ImportLevelTemplates() public method

Imports level templates using the given template JSON.
public ImportLevelTemplates ( string templateJson ) : void
templateJson string
return void

ImportSharedTemplates() public method

Imports shared templates using the given template JSON.
public ImportSharedTemplates ( string templateJson ) : void
templateJson string
return void

ImportSnapshot() public method

public ImportSnapshot ( string snapshotJson ) : void
snapshotJson string
return void

OnDisable() protected method

protected OnDisable ( ) : void
return void

OnEntityDestroyed() public method

public OnEntityDestroyed ( EntityContainer container ) : void
container EntityContainer
return void

OnTemplateDestroyed() public method

public OnTemplateDestroyed ( ITemplate template ) : void
template ITemplate
return void

Update() protected method

protected Update ( ) : void
return void

Property Details

LevelTemplatePath public_oe property

public string LevelTemplatePath
return string

SavedLevelTemplateState public_oe property

public string SavedLevelTemplateState
return string

SavedSharedTemplateState public_oe property

public string SavedSharedTemplateState
return string

SavedSnapshotState public_oe property

public string SavedSnapshotState
return string

SharedTemplatePath public_oe property

public string SharedTemplatePath
return string

SnapshotPath public_oe property

public string SnapshotPath
return string