Remove infinite inertia and ray shapes from CharacterBody

Infinite inertia:
Not needed anymore, since it's now possible to set one-directional
collision layers in order for characters to ignore rigid bodies, while
rigid bodies still collide with characters.

Ray shapes:
They were introduced as a work around to allow constant speed on slopes,
which is now possible with the new property in CharacterBody instead.
This commit is contained in:
PouleyKetchoupp
2021-08-10 11:48:19 -07:00
parent ac1dab5062
commit 4da3a87f7d
46 changed files with 220 additions and 1634 deletions

View File

@@ -569,11 +569,9 @@
<argument index="0" name="body" type="RID" />
<argument index="1" name="from" type="Transform3D" />
<argument index="2" name="motion" type="Vector3" />
<argument index="3" name="infinite_inertia" type="bool" />
<argument index="4" name="margin" type="float" default="0.001" />
<argument index="5" name="result" type="PhysicsTestMotionResult3D" default="null" />
<argument index="6" name="exclude_raycast_shapes" type="bool" default="true" />
<argument index="7" name="exclude" type="Array" default="[]" />
<argument index="3" name="margin" type="float" default="0.001" />
<argument index="4" name="result" type="PhysicsTestMotionResult3D" default="null" />
<argument index="5" name="exclude" type="Array" default="[]" />
<description>
Returns [code]true[/code] if a collision would result from moving in the given direction from a given point in space. Margin increases the size of the shapes involved in the collision detection. [PhysicsTestMotionResult3D] can be passed to return additional information in.
</description>
@@ -851,11 +849,6 @@
<description>
</description>
</method>
<method name="ray_shape_create">
<return type="RID" />
<description>
</description>
</method>
<method name="set_active">
<return type="void" />
<argument index="0" name="active" type="bool" />
@@ -1178,34 +1171,31 @@
<constant name="SHAPE_PLANE" value="0" enum="ShapeType">
The [Shape3D] is a [WorldMarginShape3D].
</constant>
<constant name="SHAPE_RAY" value="1" enum="ShapeType">
The [Shape3D] is a [RayShape3D].
</constant>
<constant name="SHAPE_SPHERE" value="2" enum="ShapeType">
<constant name="SHAPE_SPHERE" value="1" enum="ShapeType">
The [Shape3D] is a [SphereShape3D].
</constant>
<constant name="SHAPE_BOX" value="3" enum="ShapeType">
<constant name="SHAPE_BOX" value="2" enum="ShapeType">
The [Shape3D] is a [BoxShape3D].
</constant>
<constant name="SHAPE_CAPSULE" value="4" enum="ShapeType">
<constant name="SHAPE_CAPSULE" value="3" enum="ShapeType">
The [Shape3D] is a [CapsuleShape3D].
</constant>
<constant name="SHAPE_CYLINDER" value="5" enum="ShapeType">
<constant name="SHAPE_CYLINDER" value="4" enum="ShapeType">
The [Shape3D] is a [CylinderShape3D].
</constant>
<constant name="SHAPE_CONVEX_POLYGON" value="6" enum="ShapeType">
<constant name="SHAPE_CONVEX_POLYGON" value="5" enum="ShapeType">
The [Shape3D] is a [ConvexPolygonShape3D].
</constant>
<constant name="SHAPE_CONCAVE_POLYGON" value="7" enum="ShapeType">
<constant name="SHAPE_CONCAVE_POLYGON" value="6" enum="ShapeType">
The [Shape3D] is a [ConcavePolygonShape3D].
</constant>
<constant name="SHAPE_HEIGHTMAP" value="8" enum="ShapeType">
<constant name="SHAPE_HEIGHTMAP" value="7" enum="ShapeType">
The [Shape3D] is a [HeightMapShape3D].
</constant>
<constant name="SHAPE_SOFT_BODY" value="9" enum="ShapeType">
<constant name="SHAPE_SOFT_BODY" value="8" enum="ShapeType">
The [Shape3D] is a [SoftBody3D].
</constant>
<constant name="SHAPE_CUSTOM" value="10" enum="ShapeType">
<constant name="SHAPE_CUSTOM" value="9" enum="ShapeType">
This constant is used internally by the engine. Any attempt to create this kind of shape results in an error.
</constant>
<constant name="AREA_PARAM_GRAVITY" value="0" enum="AreaParameter">