Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
1
Question by iso250 · Apr 29, 2015 at 02:11 PM · navmeshnavmeshagent

Can NavMeshAgent navigate tight mazes?

Hello.

I'm using NavMeshAgent to make objects navigate through a maze. I'm having an issue with speed, however. Whenever I increase the speed of the NavMeshAgents I'm finding that rather than slow down to take the corners they just bump and bounce off the walls.

I have searched the forums for an answer and haven't found one. I've tried adjusting the Speed, Angular Speed, Acceleration and Stopping Distance in every permutation I can think of trying to stop the objects from bouncing but to no avail.

Is this a known issue or am I missing something?

Thank you!!

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by brunopava · Apr 29, 2015 at 02:19 PM

That is dictated by its radius. If he can fit in the maze it will navigate. Also you need to bake the mesh with the correct radius.

alt text

alt text


unity-64bit-untitled-testeuma-pc-mac-linux-standal.jpg (25.4 kB)
unity-64bit-testunity-testeuma-pc-mac-linux-standa.jpg (17.8 kB)
Comment
Add comment · Show 3 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image iso250 · Apr 29, 2015 at 02:38 PM 0
Share

Thank you for that.

At high speeds the Agent slams in to the walls, however. Is there any way to make it decelerate as it approaches the corners so its path is smooth? Having it slam in to walls looks a little ugly.

avatar image brunopava · Apr 29, 2015 at 04:53 PM 0
Share

I did some research about this and came up with a few ideas.

1: You could mix waypoints with the Nav$$anonymous$$esh, so he must reach a corner waypoint before turning.

2: You could use Corners like this:

alt text

3: It's possible to use Nav$$anonymous$$esh.Raycast to figure out if he is about to collide with something. Thats a bit more complicated, but I guess the result is more accurate. http://docs.unity3d.com/ScriptReference/Nav$$anonymous$$esh.Raycast.html

PS: Have your tried tweeking the agent parameters? I remember once I had some issues with an agent and the config I used was this:

Speed 7 Acceleration 10 Angular Speed 999

unity-64bit-untitled-tcc-prototype-android-dx11-on.jpg (20.5 kB)
avatar image iso250 · Apr 30, 2015 at 08:38 PM 0
Share

Unfortunately my skill isn't high enough to use raycasting and tweaking the agent parameters didn't work.

The game I'm making is 2D so i have decided to use PolyNav as that system uses the same raycasting that i'm not skilled enough to use to slow down the agents as they approach a tight bend.

Thank you for your help, though!!

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

Navmesh Teleporting (With Server) 1 Answer

How to sample a point on a navMesh Agent path 0 Answers

NavMeshAgent not calculating shortest route. 3 Answers

Make Navmesh Agents more consistent 0 Answers

Enemy follow Camera 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges