Resultclass

objectResult
Namespace
global
Assembly
Sandbox.Engine
Declaration
public sealed struct Sandbox.Engine.Utility.RayTrace.MeshTraceRequest.Result

Properties13

Showing 13 properties

public float Sandbox.Engine.Utility.RayTrace.MeshTraceRequest.Result.Distance { get; set; }PUBLICGETSET

The distance between start and end positions.

Returns:float

public float Sandbox.Engine.Utility.RayTrace.MeshTraceRequest.Result.Fraction { get; set; }PUBLICGETSET

A fraction [0..1] of where the trace hit between the start and the original end positions

Returns:float

public bool Sandbox.Engine.Utility.RayTrace.MeshTraceRequest.Result.Hit { get; set; }PUBLICGETSET

Returns:bool

public int Sandbox.Engine.Utility.RayTrace.MeshTraceRequest.Result.HitTriangle { get; set; }PUBLICGETSET

Returns:int

public Vector2 Sandbox.Engine.Utility.RayTrace.MeshTraceRequest.Result.HitTriangleUv { get; set; }PUBLICGETSET

This is the Uv coordinate on the triangle hit. 'x' represents the distance between Vertex 0-1, 'y' represents the distance between Vertex 0-2.

Returns:Vector2

public Vector3 Sandbox.Engine.Utility.RayTrace.MeshTraceRequest.Result.VertexInfluence { get; set; }PUBLICGETSET

Given the position on the triangle hit, this vector gives the influence of each vertex on that position. So for example, if the Vector is [1,0,0] that means that the hit point is right on vertex 0. If it's [0.33, 0.33, 0.33] then it's right in the middle of each vertex.

Returns:Vector3

On this page