Skip to content

Class: ActiveComponent ​

active is the user-set flag for this entity alone. activeInHierarchy is derived (this && every ancestor) and maintained by ActiveSystem — treat as read-only from game code. Writes to active set dirty, which is ActiveSystem's signal to re-walk the subtree.

underCanvas (also derived by ActiveSystem) is the Cocos rule: 2D content only draws inside a Canvas. True for a Canvas entity and everything below one; nodes where it's false are hidden by NodeTransformSystem whatever they carry.

Extends ​

Constructors ​

Constructor ​

ts
new ActiveComponent(active?): ActiveComponent;

Parameters ​

ParameterTypeDefault value
activebooleantrue

Returns ​

ActiveComponent

Overrides ​

Component.constructor

Properties ​

PropertyModifierTypeDefault valueInherited from
activepublicbooleanundefined-
activeInHierarchypublicbooleantrue-
dirtypublicbooleantrueComponent.dirty
enabledpublicbooleantrueComponent.enabled
underCanvaspublicbooleanfalse-

© 2026 PlayAdGentic