summaryrefslogtreecommitdiff
path: root/doc/classes
diff options
context:
space:
mode:
authorRicardo Buring <ricardo.buring@gmail.com>2022-09-06 15:35:33 +0200
committerRicardo Buring <ricardo.buring@gmail.com>2022-09-07 15:05:46 +0200
commit532e378cd9da5ab2121c6da8ac7d06ae7d5b6006 (patch)
tree073e9497b43233b4ebc35c9c8fc2203d214520d8 /doc/classes
parent019253512d75eb5e012772921ace6c092d8f5380 (diff)
Expose registration of physics servers to GDExtension
This exposes PhysicsServer2DManager and PhysicsServer3DManager.
Diffstat (limited to 'doc/classes')
-rw-r--r--doc/classes/@GlobalScope.xml6
-rw-r--r--doc/classes/PhysicsServer2DManager.xml30
-rw-r--r--doc/classes/PhysicsServer3DManager.xml30
3 files changed, 66 insertions, 0 deletions
diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml
index 86804e2c4c..41d1ccf2ea 100644
--- a/doc/classes/@GlobalScope.xml
+++ b/doc/classes/@GlobalScope.xml
@@ -1302,9 +1302,15 @@
<member name="PhysicsServer2D" type="PhysicsServer2D" setter="" getter="">
The [PhysicsServer2D] singleton.
</member>
+ <member name="PhysicsServer2DManager" type="PhysicsServer2DManager" setter="" getter="">
+ The [PhysicsServer2DManager] singleton.
+ </member>
<member name="PhysicsServer3D" type="PhysicsServer3D" setter="" getter="">
The [PhysicsServer3D] singleton.
</member>
+ <member name="PhysicsServer3DManager" type="PhysicsServer3DManager" setter="" getter="">
+ The [PhysicsServer3DManager] singleton.
+ </member>
<member name="ProjectSettings" type="ProjectSettings" setter="" getter="">
The [ProjectSettings] singleton.
</member>
diff --git a/doc/classes/PhysicsServer2DManager.xml b/doc/classes/PhysicsServer2DManager.xml
new file mode 100644
index 0000000000..328ac93ce3
--- /dev/null
+++ b/doc/classes/PhysicsServer2DManager.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="PhysicsServer2DManager" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ Manager for 2D physics server implementations.
+ </brief_description>
+ <description>
+ [PhysicsServer2DManager] is the API for registering [PhysicsServer2D] implementations, and for setting the default implementation.
+ [b]Note:[/b] It is not possible to switch physics servers at runtime. This class is only used on startup at the server initialization level, by Godot itself and possibly by GDExtensions.
+ </description>
+ <tutorials>
+ </tutorials>
+ <methods>
+ <method name="register_server">
+ <return type="void" />
+ <param index="0" name="name" type="String" />
+ <param index="1" name="create_callback" type="Callable" />
+ <description>
+ Register a [PhysicsServer2D] implementation by passing a [param name] and a [Callable] that returns a [PhysicsServer2D] object.
+ </description>
+ </method>
+ <method name="set_default_server">
+ <return type="void" />
+ <param index="0" name="name" type="String" />
+ <param index="1" name="priority" type="int" />
+ <description>
+ Set the default [PhysicsServer2D] implementation to the one identified by [param name], if [param priority] is greater than the priority of the current default implementation.
+ </description>
+ </method>
+ </methods>
+</class>
diff --git a/doc/classes/PhysicsServer3DManager.xml b/doc/classes/PhysicsServer3DManager.xml
new file mode 100644
index 0000000000..3ec03fede4
--- /dev/null
+++ b/doc/classes/PhysicsServer3DManager.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<class name="PhysicsServer3DManager" inherits="Object" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
+ <brief_description>
+ Manager for 3D physics server implementations.
+ </brief_description>
+ <description>
+ [PhysicsServer3DManager] is the API for registering [PhysicsServer3D] implementations, and for setting the default implementation.
+ [b]Note:[/b] It is not possible to switch physics servers at runtime. This class is only used on startup at the server initialization level, by Godot itself and possibly by GDExtensions.
+ </description>
+ <tutorials>
+ </tutorials>
+ <methods>
+ <method name="register_server">
+ <return type="void" />
+ <param index="0" name="name" type="String" />
+ <param index="1" name="create_callback" type="Callable" />
+ <description>
+ Register a [PhysicsServer3D] implementation by passing a [param name] and a [Callable] that returns a [PhysicsServer2D] object.
+ </description>
+ </method>
+ <method name="set_default_server">
+ <return type="void" />
+ <param index="0" name="name" type="String" />
+ <param index="1" name="priority" type="int" />
+ <description>
+ Set the default [PhysicsServer3D] implementation to the one identified by [param name], if [param priority] is greater than the priority of the current default implementation.
+ </description>
+ </method>
+ </methods>
+</class>