Getting ready

This technique uses the RaycastHit structure and the Raycast function from the physics engine, so it's recommended that you look at the documents for a refresher in case you're a little rusty on the subject.

Get Unity 2018 Artificial Intelligence Cookbook - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.