Commit 28bb2806 by Rémi Verschelde

doc: Sync classref with current source

parent c72b05e8
......@@ -31,7 +31,7 @@
for p in peers:
p.poll() # Must poll to update the state.
if p.get_status() == PacketPeerDTLS.STATUS_CONNECTED:
while p.get_available_packet_count() > 0:
while p.get_available_packet_count() > 0:
print("Received message from client: %s" % p.get_packet().get_string_from_utf8())
p.put_packet("Hello DTLS client".to_utf8())
[/codeblock]
......@@ -53,7 +53,7 @@
if !connected:
# Try to contact server
dtls.put_packet("The answer is... 42!".to_utf8())
while dtls.get_available_packet_count() > 0:
while dtls.get_available_packet_count() > 0:
print("Connected: %s" % dtls.get_packet().get_string_from_utf8())
connected = true
[/codeblock]
......@@ -68,7 +68,7 @@
</argument>
<argument index="1" name="certificate" type="X509Certificate">
</argument>
<argument index="2" name="ca_chain" type="X509Certificate">
<argument index="2" name="chain" type="X509Certificate" default="null">
</argument>
<description>
Setup the DTLS server to use the given [code]private_key[/code] and provide the given [code]certificate[/code] to clients. You can pass the optional [code]chain[/code] parameter to provide additional CA chain information along with the certificate.
......
......@@ -9,31 +9,39 @@
<tutorials>
</tutorials>
<methods>
<method name="get_rid" qualifiers="const">
<return type="RID">
<method name="get_closest_point" qualifiers="const">
<return type="Vector3">
</return>
<argument index="0" name="to_point" type="Vector3">
</argument>
<description>
Returns the point closest to the provided [code]to_point[/code] on the navigation mesh surface.
</description>
</method>
<method name="get_simple_path" qualifiers="const">
<return type="PackedVector3Array">
<method name="get_closest_point_normal" qualifiers="const">
<return type="Vector3">
</return>
<argument index="0" name="start" type="Vector3">
</argument>
<argument index="1" name="end" type="Vector3">
<argument index="0" name="to_point" type="Vector3">
</argument>
<argument index="2" name="optimize" type="bool" default="true">
<description>
Returns the normal for the point returned by [method get_closest_point].
</description>
</method>
<method name="get_closest_point_owner" qualifiers="const">
<return type="RID">
</return>
<argument index="0" name="to_point" type="Vector3">
</argument>
<description>
Returns the path between two given points. Points are in local coordinate space. If [code]optimize[/code] is [code]true[/code] (the default), the agent properties associated with each [NavigationMesh] (radius, height, etc.) are considered in the path calculation, otherwise they are ignored.
Returns the owner region RID for the point returned by [method get_closest_point].
</description>
</method>
<method name="get_closest_point_to_segment" qualifiers="const">
<return type="Vector3">
</return>
<argument index="0" name="from" type="Vector3">
<argument index="0" name="start" type="Vector3">
</argument>
<argument index="1" name="to" type="Vector3">
<argument index="1" name="end" type="Vector3">
</argument>
<argument index="2" name="use_collision" type="bool" default="false">
</argument>
......@@ -41,31 +49,23 @@
Returns the closest point between the navigation surface and the segment.
</description>
</method>
<method name="get_closest_point" qualifiers="const">
<return type="Vector3">
<method name="get_rid" qualifiers="const">
<return type="RID">
</return>
<argument index="0" name="point" type="Vector3">
</argument>
<description>
Returns the point closest to the provided [code]point[/code] on the navigation mesh surface.
</description>
</method>
<method name="get_closest_point_normal" qualifiers="const">
<return type="Vector3">
<method name="get_simple_path" qualifiers="const">
<return type="PackedVector3Array">
</return>
<argument index="0" name="point" type="Vector3">
<argument index="0" name="start" type="Vector3">
</argument>
<description>
Returns the normal for the point returned by [method get_closest_point].
</description>
</method>
<method name="get_closest_point_owner" qualifiers="const">
<return type="RID">
</return>
<argument index="0" name="point" type="Vector3">
<argument index="1" name="end" type="Vector3">
</argument>
<argument index="2" name="optimize" type="bool" default="true">
</argument>
<description>
Returns the owner region RID for the point returned by [method get_closest_point].
Returns the path between two given points. Points are in local coordinate space. If [code]optimize[/code] is [code]true[/code] (the default), the agent properties associated with each [NavigationMesh] (radius, height, etc.) are considered in the path calculation, otherwise they are ignored.
</description>
</method>
</methods>
......
......@@ -9,6 +9,24 @@
<tutorials>
</tutorials>
<methods>
<method name="get_closest_point" qualifiers="const">
<return type="Vector2">
</return>
<argument index="0" name="to_point" type="Vector2">
</argument>
<description>
Returns the point closest to the provided [code]to_point[/code] on the navigation mesh surface.
</description>
</method>
<method name="get_closest_point_owner" qualifiers="const">
<return type="RID">
</return>
<argument index="0" name="to_point" type="Vector2">
</argument>
<description>
Returns the owner region RID for the point returned by [method get_closest_point].
</description>
</method>
<method name="get_rid" qualifiers="const">
<return type="RID">
</return>
......@@ -28,24 +46,6 @@
Returns the path between two given points. Points are in local coordinate space. If [code]optimize[/code] is [code]true[/code] (the default), the path is smoothed by merging path segments where possible.
</description>
</method>
<method name="get_closest_point" qualifiers="const">
<return type="Vector2">
</return>
<argument index="0" name="point" type="Vector2">
</argument>
<description>
Returns the point closest to the provided [code]point[/code] on the navigation mesh surface.
</description>
</method>
<method name="get_closest_point_owner" qualifiers="const">
<return type="RID">
</return>
<argument index="0" name="point" type="Vector2">
</argument>
<description>
Returns the owner region RID for the point returned by [method get_closest_point].
</description>
</method>
</methods>
<members>
<member name="cell_size" type="float" setter="set_cell_size" getter="get_cell_size" default="10.0">
......
......@@ -164,50 +164,50 @@
Returns the map cell size.
</description>
</method>
<method name="map_get_edge_connection_margin" qualifiers="const">
<return type="float">
<method name="map_get_closest_point" qualifiers="const">
<return type="Vector2">
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="1" name="to_point" type="Vector2">
</argument>
<description>
Returns the edge connection margin of the map. The edge connection margin is a distance used to connect two regions.
Returns the point closest to the provided [code]to_point[/code] on the navigation mesh surface.
</description>
</method>
<method name="map_get_path" qualifiers="const">
<return type="PackedVector2Array">
<method name="map_get_closest_point_owner" qualifiers="const">
<return type="RID">
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="1" name="origin" type="Vector2">
</argument>
<argument index="2" name="destination" type="Vector2">
</argument>
<argument index="3" name="optimize" type="bool">
<argument index="1" name="to_point" type="Vector2">
</argument>
<description>
Returns the navigation path to reach the destination from the origin, while avoiding static obstacles.
Returns the owner region RID for the point returned by [method map_get_closest_point].
</description>
</method>
<method name="map_get_closest_point" qualifiers="const">
<return type="Vector2">
<method name="map_get_edge_connection_margin" qualifiers="const">
<return type="float">
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="1" name="point" type="Vector2">
</argument>
<description>
Returns the point closest to the provided [code]point[/code] on the navigation mesh surface.
Returns the edge connection margin of the map. The edge connection margin is a distance used to connect two regions.
</description>
</method>
<method name="map_get_closest_point_owner" qualifiers="const">
<return type="RID">
<method name="map_get_path" qualifiers="const">
<return type="PackedVector2Array">
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="1" name="point" type="Vector2">
<argument index="1" name="origin" type="Vector2">
</argument>
<argument index="2" name="destination" type="Vector2">
</argument>
<argument index="3" name="optimize" type="bool">
</argument>
<description>
Returns the owner region RID for the point returned by [method map_get_closest_point].
Returns the navigation path to reach the destination from the origin, while avoiding static obstacles.
</description>
</method>
<method name="map_is_active" qualifiers="const">
......
......@@ -164,28 +164,37 @@
Returns the map cell size.
</description>
</method>
<method name="map_get_edge_connection_margin" qualifiers="const">
<return type="float">
<method name="map_get_closest_point" qualifiers="const">
<return type="Vector3">
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="1" name="to_point" type="Vector3">
</argument>
<description>
Returns the edge connection margin of the map.
Returns the point closest to the provided [code]point[/code] on the navigation mesh surface.
</description>
</method>
<method name="map_get_path" qualifiers="const">
<return type="PackedVector3Array">
<method name="map_get_closest_point_normal" qualifiers="const">
<return type="Vector3">
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="1" name="origin" type="Vector3">
<argument index="1" name="to_point" type="Vector3">
</argument>
<argument index="2" name="destination" type="Vector3">
<description>
Returns the normal for the point returned by [method map_get_closest_point].
</description>
</method>
<method name="map_get_closest_point_owner" qualifiers="const">
<return type="RID">
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="3" name="optimize" type="bool">
<argument index="1" name="to_point" type="Vector3">
</argument>
<description>
Returns the navigation path to reach the destination from the origin.
Returns the owner region RID for the point returned by [method map_get_closest_point].
</description>
</method>
<method name="map_get_closest_point_to_segment" qualifiers="const">
......@@ -193,9 +202,9 @@
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="1" name="from" type="Vector3">
<argument index="1" name="start" type="Vector3">
</argument>
<argument index="2" name="to" type="Vector3">
<argument index="2" name="end" type="Vector3">
</argument>
<argument index="3" name="use_collision" type="bool" default="false">
</argument>
......@@ -203,37 +212,28 @@
Returns the closest point between the navigation surface and the segment.
</description>
</method>
<method name="map_get_closest_point" qualifiers="const">
<return type="Vector3">
<method name="map_get_edge_connection_margin" qualifiers="const">
<return type="float">
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="1" name="point" type="Vector3">
</argument>
<description>
Returns the point closest to the provided [code]point[/code] on the navigation mesh surface.
Returns the edge connection margin of the map.
</description>
</method>
<method name="map_get_closest_point_normal" qualifiers="const">
<return type="Vector3">
<method name="map_get_path" qualifiers="const">
<return type="PackedVector3Array">
</return>
<argument index="0" name="map" type="RID">
</argument>
<argument index="1" name="point" type="Vector3">
<argument index="1" name="origin" type="Vector3">
</argument>
<description>
Returns the normal for the point returned by [method map_get_closest_point].
</description>
</method>
<method name="map_get_closest_point_owner" qualifiers="const">
<return type="RID">
</return>
<argument index="0" name="map" type="RID">
<argument index="2" name="destination" type="Vector3">
</argument>
<argument index="1" name="point" type="Vector3">
<argument index="3" name="optimize" type="bool">
</argument>
<description>
Returns the owner region RID for the point returned by [method map_get_closest_point].
Returns the navigation path to reach the destination from the origin.
</description>
</method>
<method name="map_get_up" qualifiers="const">
......
......@@ -14,7 +14,7 @@
</return>
<argument index="0" name="packet_peer" type="PacketPeerUDP">
</argument>
<argument index="1" name="validate_certs" type="bool" default="false">
<argument index="1" name="validate_certs" type="bool" default="true">
</argument>
<argument index="2" name="for_hostname" type="String" default="&quot;&quot;">
</argument>
......
......@@ -45,7 +45,7 @@
if !connected:
# Try to contact server
udp.put_packet("The answer is... 42!".to_utf8())
if udp.get_available_packet_count() > 0:
if udp.get_available_packet_count() &gt; 0:
print("Connected: %s" % udp.get_packet().get_string_from_utf8())
connected = true
[/codeblock]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment