Enables certain nodes only when approximately visible.
The VisibilityEnabler2D will disable [RigidBody2D], [AnimationPlayer], and other nodes when they are not visible. It will only affect nodes with the same root node as the VisibilityEnabler2D, and the root node itself.
[b]Note:[/b] For performance reasons, VisibilityEnabler2D uses an approximate heuristic with precision determined by [member ProjectSettings.world/2d/cell_size]. If you need exact visibility checking, use another method such as adding an [Area2D] node as a child of a [Camera2D] node.
[b]Note:[/b] VisibilityEnabler2D will not affect nodes added after scene initialization.
Returns whether the enabler identified by given [enum Enabler] constant is active.
Sets active state of the enabler identified by given [enum Enabler] constant.
If [code]true[/code], [RigidBody2D] nodes will be paused.
If [code]true[/code], [AnimatedSprite] nodes will be paused.
If [code]true[/code], [AnimationPlayer] nodes will be paused.
If [code]true[/code], [Particles2D] nodes will be paused.
If [code]true[/code], the parent's [method Node._physics_process] will be stopped.
If [code]true[/code], the parent's [method Node._process] will be stopped.
This enabler will pause [AnimationPlayer] nodes.
This enabler will freeze [RigidBody2D] nodes.
This enabler will stop [Particles2D] nodes.
This enabler will stop the parent's _process function.
This enabler will stop the parent's _physics_process function.
This enabler will stop [AnimatedSprite] nodes animations.
Represents the size of the [enum Enabler] enum.