ComponentBase.Enabled Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Enabled state of this component.
public:
property bool Enabled { bool get(); void set(bool value); };
public bool Enabled { get; set; }
member this.Enabled : bool with get, set
Public Property Enabled As Boolean
Property Value
Remarks
Disabled components have no effect. This is usually the same, as if the component wasn't attached at all, except that the enabled state can be toggled at any time, and any other state (for instance, the color of a light source) is preserved. It is therefore often easier to disable a component, and enable it later again, rather than to delete it and create a new component later.
However, an entity may only have one instance of each component type attached, even if a component is disabled.