class_godotsharp.rst 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  1. :github_url: hide
  2. .. DO NOT EDIT THIS FILE!!!
  3. .. Generated automatically from Godot engine sources.
  4. .. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py.
  5. .. XML source: https://github.com/godotengine/godot/tree/master/modules/mono/doc_classes/GodotSharp.xml.
  6. .. _class_GodotSharp:
  7. GodotSharp
  8. ==========
  9. **Inherits:** :ref:`Object<class_Object>`
  10. Bridge between Godot and the Mono runtime (Mono-enabled builds only).
  11. Description
  12. -----------
  13. This class is a bridge between Godot and the Mono runtime. It exposes several low-level operations and is only available in Mono-enabled Godot builds.
  14. See also :ref:`CSharpScript<class_CSharpScript>`.
  15. Methods
  16. -------
  17. +-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------+
  18. | void | :ref:`attach_thread<class_GodotSharp_method_attach_thread>` **(** **)** |
  19. +-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------+
  20. | void | :ref:`detach_thread<class_GodotSharp_method_detach_thread>` **(** **)** |
  21. +-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------+
  22. | :ref:`int<class_int>` | :ref:`get_domain_id<class_GodotSharp_method_get_domain_id>` **(** **)** |
  23. +-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------+
  24. | :ref:`int<class_int>` | :ref:`get_scripts_domain_id<class_GodotSharp_method_get_scripts_domain_id>` **(** **)** |
  25. +-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------+
  26. | :ref:`bool<class_bool>` | :ref:`is_domain_finalizing_for_unload<class_GodotSharp_method_is_domain_finalizing_for_unload>` **(** :ref:`int<class_int>` domain_id **)** |
  27. +-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------+
  28. | :ref:`bool<class_bool>` | :ref:`is_runtime_initialized<class_GodotSharp_method_is_runtime_initialized>` **(** **)** |
  29. +-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------+
  30. | :ref:`bool<class_bool>` | :ref:`is_runtime_shutting_down<class_GodotSharp_method_is_runtime_shutting_down>` **(** **)** |
  31. +-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------+
  32. | :ref:`bool<class_bool>` | :ref:`is_scripts_domain_loaded<class_GodotSharp_method_is_scripts_domain_loaded>` **(** **)** |
  33. +-------------------------+---------------------------------------------------------------------------------------------------------------------------------------------+
  34. Method Descriptions
  35. -------------------
  36. .. _class_GodotSharp_method_attach_thread:
  37. - void **attach_thread** **(** **)**
  38. Attaches the current thread to the Mono runtime.
  39. ----
  40. .. _class_GodotSharp_method_detach_thread:
  41. - void **detach_thread** **(** **)**
  42. Detaches the current thread from the Mono runtime.
  43. ----
  44. .. _class_GodotSharp_method_get_domain_id:
  45. - :ref:`int<class_int>` **get_domain_id** **(** **)**
  46. Returns the current MonoDomain ID.
  47. \ **Note:** The Mono runtime must be initialized for this method to work (use :ref:`is_runtime_initialized<class_GodotSharp_method_is_runtime_initialized>` to check). If the Mono runtime isn't initialized at the time this method is called, the engine will crash.
  48. ----
  49. .. _class_GodotSharp_method_get_scripts_domain_id:
  50. - :ref:`int<class_int>` **get_scripts_domain_id** **(** **)**
  51. Returns the scripts MonoDomain's ID. This will be the same MonoDomain ID as :ref:`get_domain_id<class_GodotSharp_method_get_domain_id>`, unless the scripts domain isn't loaded.
  52. \ **Note:** The Mono runtime must be initialized for this method to work (use :ref:`is_runtime_initialized<class_GodotSharp_method_is_runtime_initialized>` to check). If the Mono runtime isn't initialized at the time this method is called, the engine will crash.
  53. ----
  54. .. _class_GodotSharp_method_is_domain_finalizing_for_unload:
  55. - :ref:`bool<class_bool>` **is_domain_finalizing_for_unload** **(** :ref:`int<class_int>` domain_id **)**
  56. Returns ``true`` if the domain is being finalized, ``false`` otherwise.
  57. ----
  58. .. _class_GodotSharp_method_is_runtime_initialized:
  59. - :ref:`bool<class_bool>` **is_runtime_initialized** **(** **)**
  60. Returns ``true`` if the Mono runtime is initialized, ``false`` otherwise.
  61. ----
  62. .. _class_GodotSharp_method_is_runtime_shutting_down:
  63. - :ref:`bool<class_bool>` **is_runtime_shutting_down** **(** **)**
  64. Returns ``true`` if the Mono runtime is shutting down, ``false`` otherwise.
  65. ----
  66. .. _class_GodotSharp_method_is_scripts_domain_loaded:
  67. - :ref:`bool<class_bool>` **is_scripts_domain_loaded** **(** **)**
  68. Returns ``true`` if the scripts domain is loaded, ``false`` otherwise.
  69. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  70. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  71. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  72. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  73. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  74. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`