I have a big problem. I use navmesh pathfinding. I have some enemy units with navmesh agent.
If is enemy unit standing, this unit has enabled navmesh obstacle with carving. Other units move around this. Problem is here:
Some of other navmesh agents don`t move(are stopped) , if I disable carving all works OK.
Iām running into the same problem. The autoRepath doesnāt work in some circumstances. Every time you carve you seem to risk a certain number of agents getting stuck. Carving again frees some but blocks others. Iām trying to turn off the autoRepath and do it myself but no joy sofar. Have you made any progress?
Has anyone found a solution to this bug? Was it fixed with 4.3.3? The changelog lists a few NavMesh bug fixes, but not this specific bug. Iām trying to figure out if I need to start the paperwork for the lengthy process of getting the update installed on our machines.
I gave up on using the carving on Navmesh obstacles, it seems they are changing the navigation mesh all the time, but fps drops from 60fps to 30fps just by the simple fact of adding a carved obstacle in the scene.
And yes, the distance to recalculate is big.
Also navmesh agents when I send them to move somewhere (around 40 navmesh agents), unity now crashes, while in 4.2 everything worked ok.
It sounds like youāre experiencing a related, but possibly slightly different bug Iāve noticed. In 4.3, the āMove Thresholdā setting on NavMeshObstacle seems to be completely broken; it doesnāt appear to have any effect at all. The nature of the FPS drop indicates that the obstacle is constantly carving the mesh, regardless of how much it has moved and regardless of the āMove Thresholdā setting. It does appear (based on FPS) to not re-carve if the obstacle stays in exactly the same position, but if there is any change in position, no matter how small, it does seem to be re-carving. We got our team updated to 4.3.4 and it appears to still be broken. I think Iāll put in a bug report and start a thread about that issue, because not being able to prevent it from recalculating the navmesh carving every single frame without giving up the ability to carve at all is completely breaking our game. The performance hit for recalculating the mesh carving every frame makes it borderline unplayable.
yup, I gave up on the carving, the fps hit was just too big.
Please do submit a bug report, I already submitted one regarding the crashes that now happen when we try to move about 40 agents at the same time, this was not a problem before.
Thanks for this thread; I found it very helpful. I also have the same problem where the Auto-Carving causes AI to get stuck. The downtime until an AI resumes movement seems far too long. Despite using Unity Pro I was almost about to totally remove the NavMesh navigation from my game; until I saw that, presently, objects with rigidbody components have a bug when dealing with carving. Iāll work on other aspects of the game for now and if required later I will change the movement to something else; if the bug isnāt fixed in the next version.
Gua - we are having that exact problem. Also, if there is a single carving navMeshObstacle in the scene then a lot of our AI agents (with rigidBodies) are simply walking through ordinary collider objects (doors etc.).
Having this exact same problem with Unity 5. 1 navmesh agent simply refuses to move if there are ANY navmesh obstacles in the scene with carving enabled and there are 4 or more agents in the scene.
Using Unity 4.6.5f1, Iāve run into a very similar problem. In my case, an agent is outside of a room and trying to path find into the room. If I ālockā the door by having it carve the nav mesh when shut, the agent halts, goes into the PathFinding state, and never leaves it, even when I change the destination to somewhere it can reach! Only by āunlockingā the door, causing (the original) valid path to be in existence again, does the agent start going to where ever its new destination was set. This is quite thoroughly frustrating.
The best workaround Iāve found until now, is to check for isPathStale on AI update or create an event for carving notifications. Everytime you carve or move a carved object, it will stale some paths, which need to be recalculated. The autorepath doesnāt seems to work, so using something like the code below, might be usefull. Another cause for massive agent freeze, is to set a destination.position out of the navmesh bounds, so check for partial paths and find a suitable point to calculate it.
Please iām having the same issue. I donāt even carve when objects are moved but itās enough to mess everything. Look at this, if I remove carving everything works fine but when itās enabled the NPC canāt find a way in the purple zone when it goes next to the door with obstacles. Itās just stuck runningā¦
This problem still persists with 5.6.3⦠any body have solution for this⦠I have 1 nav mesh obstacle on my player with carving On when player is moving then all nav mesh agent stop movingā¦I have to carving On because I donāt want other nav mesh agent is passing in playerā¦Can anybody Help me ??
With Unity 2018 usintg dynamic carving makes the enemies go crazy moving to random places and also jitter a lot like if the enemy was being shaked very fast instead going to the player as its programmed and as it does when carving is not enabled. Also when using navmesh obstacles in moving enemies makes them move animations much faster, i also in reduced spaces they move slower dont know why, using navmesh obstacles makes everything stop working as it should
Issue still persists in Unity 2017.4.9f1. I am having this exact same issue in my game. I run about 10-20 AI units at the same time and every time a NavMeshObstacle is added to the scene (which uses Carving), all of the units rotate for a second and then resume their path and a half of them just get stuck walking into NavMeshObstacles altogether.