2019-03-17 10:47:19 +01:00
<?xml version="1.0" encoding="UTF-8" ?>
2023-07-06 10:08:05 +02:00
<class name= "HeightMapShape3D" inherits= "Shape3D" xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation= "../class.xsd" >
2019-03-17 10:47:19 +01:00
<brief_description >
2023-04-28 22:59:03 +02:00
A 3D height map shape used for physics collision.
2019-03-17 10:47:19 +01:00
</brief_description>
<description >
2023-04-28 22:59:03 +02:00
A 3D heightmap shape, intended for use in physics. Usually used to provide a shape for a [CollisionShape3D]. This is useful for terrain, but it is limited as overhangs (such as caves) cannot be stored. Holes in a [HeightMapShape3D] are created by assigning very low values to points in the desired area.
[b]Performance:[/b] [HeightMapShape3D] is faster to check collisions against than [ConcavePolygonShape3D], but it is significantly slower than primitive shapes like [BoxShape3D].
2019-03-17 10:47:19 +01:00
</description>
<tutorials >
</tutorials>
2024-02-02 23:07:53 +01:00
<methods >
<method name= "get_max_height" qualifiers= "const" >
<return type= "float" />
<description >
Returns the largest height value found in [member map_data]. Recalculates only when [member map_data] changes.
</description>
</method>
<method name= "get_min_height" qualifiers= "const" >
<return type= "float" />
<description >
Returns the smallest height value found in [member map_data]. Recalculates only when [member map_data] changes.
</description>
</method>
</methods>
2019-03-17 10:47:19 +01:00
<members >
2019-09-24 19:45:03 +02:00
<member name= "map_data" type= "PackedFloat32Array" setter= "set_map_data" getter= "get_map_data" default= "PackedFloat32Array(0, 0, 0, 0)" >
2024-02-02 23:07:53 +01:00
Height map data. The array's size must be equal to [member map_width] multiplied by [member map_depth].
2019-03-17 10:47:19 +01:00
</member>
2019-06-29 12:38:01 +02:00
<member name= "map_depth" type= "int" setter= "set_map_depth" getter= "get_map_depth" default= "2" >
2023-01-24 17:56:49 +01:00
Number of vertices in the depth of the height map. Changing this will resize the [member map_data].
2019-03-17 10:47:19 +01:00
</member>
2019-06-29 12:38:01 +02:00
<member name= "map_width" type= "int" setter= "set_map_width" getter= "get_map_width" default= "2" >
2023-01-24 17:56:49 +01:00
Number of vertices in the width of the height map. Changing this will resize the [member map_data].
2019-03-17 10:47:19 +01:00
</member>
</members>
</class>