class_visualscriptmathconstant.rst 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the VisualScriptMathConstant.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_VisualScriptMathConstant:
  5. VisualScriptMathConstant
  6. ========================
  7. **Inherits:** :ref:`VisualScriptNode<class_VisualScriptNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. Commonly used mathematical constants.
  12. Properties
  13. ----------
  14. +-----------------------------------------------------------------+-------------------------------------------------------------------+
  15. | :ref:`MathConstant<enum_VisualScriptMathConstant_MathConstant>` | :ref:`constant<class_VisualScriptMathConstant_property_constant>` |
  16. +-----------------------------------------------------------------+-------------------------------------------------------------------+
  17. Enumerations
  18. ------------
  19. .. _enum_VisualScriptMathConstant_MathConstant:
  20. .. _class_VisualScriptMathConstant_constant_MATH_CONSTANT_ONE:
  21. .. _class_VisualScriptMathConstant_constant_MATH_CONSTANT_PI:
  22. .. _class_VisualScriptMathConstant_constant_MATH_CONSTANT_HALF_PI:
  23. .. _class_VisualScriptMathConstant_constant_MATH_CONSTANT_TAU:
  24. .. _class_VisualScriptMathConstant_constant_MATH_CONSTANT_E:
  25. .. _class_VisualScriptMathConstant_constant_MATH_CONSTANT_SQRT2:
  26. .. _class_VisualScriptMathConstant_constant_MATH_CONSTANT_INF:
  27. .. _class_VisualScriptMathConstant_constant_MATH_CONSTANT_NAN:
  28. .. _class_VisualScriptMathConstant_constant_MATH_CONSTANT_MAX:
  29. enum **MathConstant**:
  30. - **MATH_CONSTANT_ONE** = **0** --- Unity: ``1``
  31. - **MATH_CONSTANT_PI** = **1** --- Pi: ``3.141593``
  32. - **MATH_CONSTANT_HALF_PI** = **2** --- Pi divided by two: ``1.570796``
  33. - **MATH_CONSTANT_TAU** = **3** --- Tau: ``6.283185``
  34. - **MATH_CONSTANT_E** = **4** --- Mathematical constant ``e``, the natural log base: ``2.718282``
  35. - **MATH_CONSTANT_SQRT2** = **5** --- Square root of two: ``1.414214``
  36. - **MATH_CONSTANT_INF** = **6** --- Infinity: ``inf``
  37. - **MATH_CONSTANT_NAN** = **7** --- Not a number: ``nan``
  38. - **MATH_CONSTANT_MAX** = **8**
  39. Description
  40. -----------
  41. Provides common math constants, such as Pi, on an output Data port.
  42. **Input Ports:**
  43. none
  44. **Output Ports:**
  45. - Data (variant): ``get``
  46. Property Descriptions
  47. ---------------------
  48. .. _class_VisualScriptMathConstant_property_constant:
  49. - :ref:`MathConstant<enum_VisualScriptMathConstant_MathConstant>` **constant**
  50. +----------+--------------------------+
  51. | *Setter* | set_math_constant(value) |
  52. +----------+--------------------------+
  53. | *Getter* | get_math_constant() |
  54. +----------+--------------------------+
  55. The math constant.