Exemplo n.º 1
0
 /// <summary>
 /// Perform a physics world swept sphere test and return the closest hit.
 /// </summary>
 public void SphereCast(ref PhysicsRaycastResult result, Urho.Ray ray, float radius, float maxDistance, uint collisionMask)
 {
     Runtime.ValidateRefCounted(this);
     PhysicsWorld_SphereCast(handle, ref result, ref ray, radius, maxDistance, collisionMask);
 }
Exemplo n.º 2
0
 /// <summary>
 /// Perform a physics world segmented raycast and return the closest hit. Useful for big scenes with many bodies.
 /// </summary>
 public void RaycastSingleSegmented(ref PhysicsRaycastResult result, Urho.Ray ray, float maxDistance, float segmentDistance, uint collisionMask)
 {
     Runtime.ValidateRefCounted(this);
     PhysicsWorld_RaycastSingleSegmented(handle, ref result, ref ray, maxDistance, segmentDistance, collisionMask);
 }
Exemplo n.º 3
0
 internal static extern void PhysicsWorld_SphereCast(IntPtr handle, ref PhysicsRaycastResult result, ref Urho.Ray ray, float radius, float maxDistance, uint collisionMask);
Exemplo n.º 4
0
 internal static extern void PhysicsWorld_RaycastSingleSegmented(IntPtr handle, ref PhysicsRaycastResult result, ref Urho.Ray ray, float maxDistance, float segmentDistance, uint collisionMask);
Exemplo n.º 5
0
 /// <summary>
 /// Return whether or not the ray is inside geometry.
 /// </summary>
 public bool IsInside(Urho.Ray ray)
 {
     Runtime.ValidateRefCounted(this);
     return(Geometry_IsInside(handle, ref ray));
 }
Exemplo n.º 6
0
 internal static extern bool Geometry_IsInside(IntPtr handle, ref Urho.Ray ray);
Exemplo n.º 7
0
 /// <summary>
 /// Return ray hit distance or infinity if no hit. Requires raw data to be set. Optionally return hit normal and hit uv coordinates at intersect point.
 /// </summary>
 public float GetHitDistance(Urho.Ray ray, Vector3 *outNormal, Vector2 *outUV)
 {
     Runtime.ValidateRefCounted(this);
     return(Geometry_GetHitDistance(handle, ref ray, outNormal, outUV));
 }
Exemplo n.º 8
0
 internal static extern float Geometry_GetHitDistance(IntPtr handle, ref Urho.Ray ray, Vector3 *outNormal, Vector2 *outUV);