Class MyHierarchyComponentBase
Inheritance
System.Object
MyHierarchyComponentBase
Assembly: VRage.Game.dll
Syntax
[MyComponentBuilder]
public class MyHierarchyComponentBase : MyEntityComponentBase, IMyEntityComponentBase, IMyComponentBase
Constructors
MyHierarchyComponentBase()
Declaration
public MyHierarchyComponentBase()
Fields
ChildId
Declaration
Field Value
| Type |
Description |
| System.Int64 |
|
Properties
Children
Gets the children collection.
Declaration
public ListReader<MyHierarchyComponentBase> Children { get; }
Property Value
ChildrenNeedingWorldMatrix
Gets the children collection for spatial updates.
Declaration
public HashSetReader<MyHierarchyComponentBase> ChildrenNeedingWorldMatrix { get; }
Property Value
ComponentTypeDebugString
Declaration
public override string ComponentTypeDebugString { get; }
Property Value
| Type |
Description |
| System.String |
|
Overrides
Parent
Declaration
public MyHierarchyComponentBase Parent { get; set; }
Property Value
Methods
AddChild(IMyEntity, Boolean, Boolean)
Declaration
public void AddChild(IMyEntity child, bool preserveWorldPos = false, bool insertIntoSceneIfNeeded = true)
Parameters
| Type |
Name |
Description |
| IMyEntity |
child |
The child.
|
| System.Boolean |
preserveWorldPos |
if set to true [preserve absolute position].
|
| System.Boolean |
insertIntoSceneIfNeeded |
|
AddChildWithMatrix(IMyEntity, ref Matrix, Boolean)
Declaration
public void AddChildWithMatrix(IMyEntity child, ref Matrix childLocalMatrix, bool insertIntoSceneIfNeeded = true)
Parameters
| Type |
Name |
Description |
| IMyEntity |
child |
|
| Matrix |
childLocalMatrix |
|
| System.Boolean |
insertIntoSceneIfNeeded |
|
Delete()
Declaration
Deserialize(MyObjectBuilder_ComponentBase)
Declaration
public override void Deserialize(MyObjectBuilder_ComponentBase builder)
Parameters
Overrides
GetChildrenRecursive(HashSet<IMyEntity>)
Declaration
public void GetChildrenRecursive(HashSet<IMyEntity> result)
Parameters
| Type |
Name |
Description |
| System.Collections.Generic.HashSet<IMyEntity> |
result |
|
GetTopMostParent(Type)
Return top most parent of this entity
Declaration
public MyHierarchyComponentBase GetTopMostParent(Type type = null)
Parameters
| Type |
Name |
Description |
| System.Type |
type |
|
Returns
IsSerialized()
Declaration
public override bool IsSerialized()
Returns
| Type |
Description |
| System.Boolean |
|
Overrides
OnAddedToScene()
Declaration
public override void OnAddedToScene()
Overrides
OnBeforeRemovedFromContainer()
Declaration
public override void OnBeforeRemovedFromContainer()
Overrides
RemoveByJN(MyHierarchyComponentBase)
Declaration
public void RemoveByJN(MyHierarchyComponentBase childHierarchy)
Parameters
RemoveChild(IMyEntity, Boolean)
Declaration
public void RemoveChild(IMyEntity child, bool preserveWorldPos = false)
Parameters
| Type |
Name |
Description |
| IMyEntity |
child |
The child.
|
| System.Boolean |
preserveWorldPos |
if set to true [preserve absolute position].
|
Serialize(Boolean)
Declaration
public override MyObjectBuilder_ComponentBase Serialize(bool copy = false)
Parameters
| Type |
Name |
Description |
| System.Boolean |
copy |
|
Returns
Overrides
Events
OnChildRemoved
Declaration
public event Action<IMyEntity> OnChildRemoved
Event Type
OnParentChanged
Declaration
public event Action<MyHierarchyComponentBase, MyHierarchyComponentBase> OnParentChanged
Event Type
Extension Methods