class_inputeventaction.rst 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the InputEventAction.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_InputEventAction:
  5. InputEventAction
  6. ================
  7. **Inherits:** :ref:`InputEvent<class_inputevent>` **<** :ref:`Resource<class_resource>` **<** :ref:`Reference<class_reference>` **<** :ref:`Object<class_object>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. Input event type for actions.
  12. Member Functions
  13. ----------------
  14. +------------------------------+-------------------------------------------------------------------------------------------------------+
  15. | :ref:`String<class_string>` | :ref:`get_action<class_InputEventAction_get_action>` **(** **)** const |
  16. +------------------------------+-------------------------------------------------------------------------------------------------------+
  17. | void | :ref:`set_action<class_InputEventAction_set_action>` **(** :ref:`String<class_string>` action **)** |
  18. +------------------------------+-------------------------------------------------------------------------------------------------------+
  19. | void | :ref:`set_pressed<class_InputEventAction_set_pressed>` **(** :ref:`bool<class_bool>` pressed **)** |
  20. +------------------------------+-------------------------------------------------------------------------------------------------------+
  21. Member Variables
  22. ----------------
  23. - :ref:`String<class_string>` **action** - The action's name. Actions are accessed via this :ref:`String<class_string>`.
  24. - :ref:`bool<class_bool>` **pressed** - If ``true`` the action's state is pressed. If ``false`` the action's state is released.
  25. Description
  26. -----------
  27. Contains a generic action which can be targeted from several type of inputs. Actions can be created from the project settings menu ``Project > Project Settings > Input Map[/Code]. See [method Node._input].
  28. Member Function Description
  29. ---------------------------
  30. .. _class_InputEventAction_get_action:
  31. - :ref:`String<class_string>` **get_action** **(** **)** const
  32. .. _class_InputEventAction_set_action:
  33. - void **set_action** **(** :ref:`String<class_string>` action **)**
  34. .. _class_InputEventAction_set_pressed:
  35. - void **set_pressed** **(** :ref:`bool<class_bool>` pressed **)**