Files
godot-docs/classes/class_visibilityenabler2d.rst
2018-01-12 08:52:43 +01:00

68 lines
2.2 KiB
ReStructuredText

.. Generated automatically by doc/tools/makerst.py in Godot's source tree.
.. DO NOT EDIT THIS FILE, but the VisibilityEnabler2D.xml source instead.
.. The source is found in doc/classes or modules/<name>/doc_classes.
.. _class_VisibilityEnabler2D:
VisibilityEnabler2D
===================
**Inherits:** :ref:`VisibilityNotifier2D<class_visibilitynotifier2d>` **<** :ref:`Node2D<class_node2d>` **<** :ref:`CanvasItem<class_canvasitem>` **<** :ref:`Node<class_node>` **<** :ref:`Object<class_object>`
**Category:** Core
Brief Description
-----------------
Enable certain nodes only when visible.
Member Variables
----------------
.. _class_VisibilityEnabler2D_freeze_bodies:
- :ref:`bool<class_bool>` **freeze_bodies**
.. _class_VisibilityEnabler2D_pause_animated_sprites:
- :ref:`bool<class_bool>` **pause_animated_sprites**
.. _class_VisibilityEnabler2D_pause_animations:
- :ref:`bool<class_bool>` **pause_animations**
.. _class_VisibilityEnabler2D_pause_particles:
- :ref:`bool<class_bool>` **pause_particles**
.. _class_VisibilityEnabler2D_physics_process_parent:
- :ref:`bool<class_bool>` **physics_process_parent**
.. _class_VisibilityEnabler2D_process_parent:
- :ref:`bool<class_bool>` **process_parent**
Enums
-----
.. _enum_VisibilityEnabler2D_Enabler:
enum **Enabler**
- **ENABLER_PAUSE_ANIMATIONS** = **0** --- This enabler will pause :ref:`AnimationPlayer<class_animationplayer>` nodes.
- **ENABLER_FREEZE_BODIES** = **1** --- This enabler will freeze :ref:`RigidBody2D<class_rigidbody2d>` nodes.
- **ENABLER_PAUSE_PARTICLES** = **2** --- This enabler will stop :ref:`Particles2D<class_particles2d>` nodes.
- **ENABLER_PARENT_PROCESS** = **3** --- This enabler will stop the parent's _process function.
- **ENABLER_PARENT_PHYSICS_PROCESS** = **4** --- This enabler will stop the parent's _physics_process function.
- **ENABLER_PAUSE_ANIMATED_SPRITES** = **5**
- **ENABLER_MAX** = **6**
Description
-----------
The VisibilityEnabler2D will disable :ref:`RigidBody2D<class_rigidbody2d>`, :ref:`AnimationPlayer<class_animationplayer>`, and other nodes when they are not visible. It will only affect other nodes within the same scene as the VisibilityEnabler2D itself.