Description
The SkipToolsMaterials
method is part of the Editor.Trace
struct and is used to configure a trace operation to ignore materials that have the tools.toolsmaterial
attribute. This is particularly useful when you want to perform trace operations that should not interact with certain tool-specific materials, allowing for more precise and relevant trace results.
Usage
To use the SkipToolsMaterials
method, you need to call it on an instance of Editor.Trace
. This method modifies the trace configuration to skip over any materials marked with the tools.toolsmaterial
attribute. This is typically used in scenarios where you want to avoid interactions with tool-specific materials during trace operations.
Example
// Example of using SkipToolsMaterials in a trace operation
Editor.Trace trace = new Editor.Trace();
trace = trace.SkipToolsMaterials();
// Assuming you have a MapWorld instance
Editor.MapDoc.MapWorld world = GetMapWorld();
Editor.TraceResult result = trace.Run(world);
// Process the trace result
if (result.Hit)
{
// Handle the hit result
}