What problem does it solve?
Provides a consistent way to perform physics queries and update physics settings in Unity projects so developers and automation tools can inspect collisions, tune materials, and control gravity without manual scene inspection.
Core Features & Use Cases
- Raycasts & Cast Variants: Single and multi-hit raycasts, spherecasts, and boxcasts that return structured hit data including point, normal, distance, and object metadata.
- Overlap Checks: Sphere and box overlap queries to detect nearby colliders for AI, spawning, or trigger logic.
- Physics Configuration: Get and set global gravity, create and assign PhysicMaterial assets, and read or modify the layer collision matrix for gameplay tuning and editor automation.
- Use Case: Use this Skill to debug why a character is not colliding with the environment by performing targeted raycasts, checking overlap volumes, and verifying layer collision settings.
Quick Start
Ask the unity-physics skill to perform a raycast from (0,1,0) downwards (0,-1,0) with maxDistance 10 and return the first hit's object name, point, normal, and distance.