The WithoutTag
method of the PhysicsTraceBuilder
class allows you to exclude specific tags from the physics trace. This is useful when you want to ignore certain objects during a trace operation based on their tags.
The WithoutTag
method of the PhysicsTraceBuilder
class allows you to exclude specific tags from the physics trace. This is useful when you want to ignore certain objects during a trace operation based on their tags.
To use the WithoutTag
method, call it on an instance of PhysicsTraceBuilder
and pass the tag you want to exclude as a string parameter. This method returns the modified PhysicsTraceBuilder
instance, allowing for method chaining.
// Example of using WithoutTag method PhysicsTraceBuilder traceBuilder = new PhysicsTraceBuilder(); traceBuilder = traceBuilder.WithoutTag("IgnoreThisTag"); // Continue building the trace traceBuilder = traceBuilder.FromTo(startPosition, endPosition); // Run the trace PhysicsTraceResult result = traceBuilder.Run();