package editor_stage_manager
Types
EditorUserInterface
interface
StageAlreadyExistsError
struct
StageAlreadyExistsError.Error
StageEntity
struct
EntityToStageEntity
StageEntity.AddDataBinding
StageEntity.DataBindings
StageEntity.Depth
StageEntity.SetMaterial
StageEntityEditorData
struct
type StageEntityEditorData struct {
Bvh *collision.BVH
Mesh *rendering.Mesh
ShaderData rendering.DrawInstance
Description stages.EntityDescription
}
StageEntityEditorData is the structure holding all the uniquely identifiable and linking data about the entity on this stage. That will include things like content linkage, data bindings, etc.
StageManager
struct
type StageManager struct {
OnEntitySpawn events.EventWithArg[*StageEntity]
OnEntityDestroy events.EventWithArg[*StageEntity]
OnEntitySelected events.EventWithArg[*StageEntity]
OnEntityDeselected events.EventWithArg[*StageEntity]
OnEntityChangedParent events.EventWithArg[*StageEntity]
// Has unexported fields.
}
StageManager represents the current stage in the editor. It contains all of the entities on the stage.
StageManager.AddBVH
StageManager.AddEntity
AddEntity will generate a new entity for the stage with a new random Id. It will internally just call AddEntityWithId
StageManager.AddEntityWithId
AddEntityWithId will create an entity for the stage with a specified Id rather than generating one. This entity will have a StageEntityData automatically added to it as named data named "stage".
StageManager.Clear
Clear will destroy all entities that are managed by this stage manager.
StageManager.ClearSelection
StageManager.CreateTemplateFromSelected
func (m *StageManager) CreateTemplateFromSelected(edEvts *editor_events.EditorEvents, proj *project.Project) error
StageManager.DeselectEntity
StageManager.DestroySelected
StageManager.EntityById
StageManager.HasSelection
StageManager.HierarchyRespectiveSelection
StageManager.Initialize
func (m *StageManager) Initialize(host *engine.Host, history *memento.History, editorUI EditorUserInterface)
StageManager.IsNew
StageManager.IsSelected
StageManager.IsSelectedById
StageManager.List
List will return all of the internally held entities for the stage
StageManager.LoadStage
func (m *StageManager) LoadStage(id string, host *engine.Host, cache *content_database.Cache, proj *project.Project) error
StageManager.NewStage
StageManager.RefitBVH
StageManager.RefitWorldBVH
StageManager.RemoveEntityBVH
StageManager.SaveStage
func (m *StageManager) SaveStage(cache *content_database.Cache, fs *project_file_system.FileSystem) error
StageManager.SelectAppendEntityById
StageManager.SelectEntity
StageManager.SelectEntityById
StageManager.SelectToggleEntityById
StageManager.Selection
StageManager.SelectionBounds
StageManager.SelectionCenter
StageManager.SelectionPivotCenter
StageManager.SetEntityParent
StageManager.SetStageId
StageManager.SpawnTemplate
func (m *StageManager) SpawnTemplate(host *engine.Host, proj *project.Project, cc *content_database.CachedContent, point matrix.Vec3) error