Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[3.6] ShapeCast exhibits unexpected behavior. #101675

Open
Ikanaut opened this issue Jan 17, 2025 · 0 comments
Open

[3.6] ShapeCast exhibits unexpected behavior. #101675

Ikanaut opened this issue Jan 17, 2025 · 0 comments

Comments

@Ikanaut
Copy link

Ikanaut commented Jan 17, 2025

Tested versions

Reproducible in: 3.6

System information

Linux MInt 22 Cinnamon - Godot 3.6.0

Issue description

  1. When given a negative value in ShapeCast.target_position it will register hits in any direction, even 180 degrees in the opposite direction. This bug respects the variable's magnitude, but only respects it's directionality in positive directions.
  2. When placed inside of a RigidBody's CollisionShape, it does not register any hits even with ShapeCast.target_position set to true. It is important to clarify that it is detecting nothing, at all. This bug is inverted when the target position is negative.

Steps to reproduce

Behavior 1:

  1. Create a new ShapeCast and rotate it 180 degrees so that it points straight up.
  2. Position above a collider and no more that 1 meter away from touching it.
  3. Run the scene with visible collision shapes and observe how it detects a collision despite facing away from the StaticBody.
  4. Play around with the ShapeCast's position and rotation.

Behavior 2:
I'm unable to figure out a reliable sequence of steps to reproduce one. It's affected by the node's position and the 'target_position' variable, but it doesn't always work. It might be a byproduct of Behavior 1 based on how my attempt to recreate it in the MRP turned out, but it doesn't seem like it would be related.

I'll post a proper list of steps in the comments if I find one. Try playing around with "test 3" and "test 4" in the MRP to see if you can trigger this behavior.

Minimal reproduction project (MRP)

shapecast_issues.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants