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

Debug render spatial queries #186

Merged
merged 5 commits into from
Oct 22, 2023
Merged

Debug render spatial queries #186

merged 5 commits into from
Oct 22, 2023

Conversation

Jondolf
Copy link
Owner

@Jondolf Jondolf commented Oct 17, 2023

Objective

It can often be useful to visualize spatial queries like raycasts and shapecasts.

Solution

Add debug rendering for RayCaster and ShapeCaster. SpatialQuery methods aren't debug rendered to avoid requiring mutable access to Gizmos in all of the methods, but PhysicsDebugRenderer now has utilities for rendering e.g. raycasts for those who need it.


Todo

  • Debug render raycasts
  • Debug render shapecasts

Other changes

  • Renamed "ray cast" and "shape cast" in docs to "raycast" and "shapecast"
  • Fixed issue with multiple hits in shapecasts
  • Fixed documentation for ShapeHitData

@Jondolf Jondolf added C-Enhancement New feature or request A-Debug-Rendering Relates to the debug plugin or any other useful debugging features labels Oct 17, 2023
@Jondolf Jondolf merged commit b9bad8d into main Oct 22, 2023
@Jondolf Jondolf deleted the debug-render-spatial-queries branch October 22, 2023 18:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Debug-Rendering Relates to the debug plugin or any other useful debugging features C-Enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant