Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Game Development How to Make a Video Game Score, Enemies, and Game State Create Enemy Navigation and AI

Difference between NavMesh and NavMesh Agent

I have some questions regarding this video

  1. What exactly is the difference between NavMesh and NavMesh Agent? I tried watching the video again as well as searched the Unity documentation for some help but couldn't exactly understand the difference between the two.
  2. How does the movement of the frog and the bird differ from each other? The frog has a jump movement whereas the bird is taking small steps. Is it due to the Animators folder in the assets provided?

I am just a beginner in Unity so any kind of help would be really useful :)

1 Answer

The NavMesh gathers information from the scene and the NavMeshAgent uses that information to do whatever you have programmed it to do with the information. Its like the automatic doors at a convenient store. The automatic doors would be the NavMeshAgent and the sensor that tells the doors when to open would be the NavMesh.

The frog and the bird movements are determined by the animations that are attached to each game object.

The example that you provided really made sense and helped me to understand the basic difference between the two terms. Thank you so much :)