Version: Unity 7.0 Alpha (7000.0)
LanguageEnglish
  • C#

IEnableableComponent

interface in Unity.Entities

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Description

An interface for a component type which allows the component to be enabled and disabled at runtime without a structural change.

This interface is only valid when used in combination with IBufferElementData or IComponentData. While the extra overhead involved in processing enableable components is generally quite low, this interface should only be used on components that will actually be enabled/disabled by the application at relatively high frequency.

Additional resources: EntityManager.SetComponentEnabled, EntityManager.IsComponentEnabled, ComponentLookup<T0>.SetComponentEnabled, ComponentLookup<T0>.IsComponentEnabled, BufferLookup<T0>.SetBufferEnabled, BufferLookup<T0>.IsBufferEnabled, ArchetypeChunk.SetComponentEnabled, ArchetypeChunk.IsComponentEnabled