Class PhysicsTestMotionResult2D
Describes the motion and collision result from PhysicsServer2D.body_test_motion.
- Inheritance
-
PhysicsTestMotionResult2D
Remarks
Describes the motion and collision result from PhysicsServer2D.body_test_motion.
Methods
get_collider
Qualifiers: const
Returns the colliding body's attached Object, if a collision occurred.
Object get_collider
get_collider_id
Qualifiers: const
Returns the unique instance ID of the colliding body's attached Object, if a collision occurred. See get_instance_id.
int get_collider_id
get_collider_rid
Qualifiers: const
Returns the colliding body's RID used by the PhysicsServer2D, if a collision occurred.
RID get_collider_rid
get_collider_shape
Qualifiers: const
Returns the colliding body's shape index, if a collision occurred. See CollisionObject2D.
int get_collider_shape
get_collider_velocity
Qualifiers: const
Returns the colliding body's velocity, if a collision occurred.
Vector2 get_collider_velocity
get_collision_depth
Qualifiers: const
Returns the length of overlap along the collision normal, if a collision occurred.
float get_collision_depth
get_collision_local_shape
Qualifiers: const
Returns the moving object's colliding shape, if a collision occurred.
int get_collision_local_shape
get_collision_normal
Qualifiers: const
Returns the colliding body's shape's normal at the point of collision, if a collision occurred.
Vector2 get_collision_normal
get_collision_point
Qualifiers: const
Returns the point of collision in global coordinates, if a collision occurred.
Vector2 get_collision_point
get_collision_safe_fraction
Qualifiers: const
Returns the maximum fraction of the motion that can occur without a collision, between 0
and 1
.
float get_collision_safe_fraction
get_collision_unsafe_fraction
Qualifiers: const
Returns the minimum fraction of the motion needed to collide, if a collision occurred, between 0
and 1
.
float get_collision_unsafe_fraction
get_remainder
Qualifiers: const
Returns the moving object's remaining movement vector.
Vector2 get_remainder
get_travel
Qualifiers: const
Returns the moving object's travel before collision.
Vector2 get_travel