SceneTrace UsePhysicsWorld( bool hit )

robot_2Generated
code_blocksInput

Description

The UsePhysicsWorld method in the SceneTrace struct is used to specify whether the trace should consider physics objects in the scene. This method allows you to include or exclude physics objects from the trace results based on the boolean parameter provided.

Usage

To use the UsePhysicsWorld method, call it on an instance of SceneTrace and pass a boolean value indicating whether physics objects should be included in the trace. If true, the trace will consider physics objects; if false, it will ignore them.

Example

// Example of using UsePhysicsWorld method
SceneTrace trace = new SceneTrace();
trace = trace.UsePhysicsWorld(true); // Include physics objects in the trace

// Run the trace
SceneTraceResult result = trace.Run();

// Check if the trace hit any physics objects
if (result.Hit)
{
    // Handle the hit result
}