Skip to content

Collision Detection with ShapeCast2D is inconsistent #532

@ZachjuKamashi

Description

@ZachjuKamashi

Collision Detection with ShapeCast2D is inconsistent with Rapier2D. This works perfectly fine when using Godots built in physics, but not with Rapier2D.

To Reproduce
Create a RigidBody2D and the children CollisionShape2D and ShapeCast2D, then apply a force towards RapierStaticBody2D with child CollisionShape2D

Then try detecting the collision with ShapeCast2D With ".IsColliding()" function. You will notice sometimes the detection does not happen even though it collides, which seems to be more consistent at not detecting when colliding at slower speeds.

Expected behavior
Collision to be always detected upon impact

Environment:

  • OS: [Windows 10 IoT Enterprise LTSC 21H2 19044.6937]
  • Version: [Latest]
  • Godot Version: [4.6.2.stable.mono]
  • Type: [cross platform deterministic 2D]

Example project(RapierBug.zip)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions