x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

How to prevent multiple AI from trying to walk through a door and getting stuck?

I have a zombie wave spawner and it works fine but when a lot of zombies spawn two or more will start to get stuck as the try to go through the same door or converge on the same nav point link. What could I do to avoid this without having to drastically change my levels? Thanks!

Product Version: UE 4.14
Tags:
more ▼

asked Apr 08 '17 at 12:20 AM in Blueprint Scripting

avatar image

Ratatat_RandyTTV
118 5 4 8

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

This @vanlacke solution with volume is good and you will use it too for sure, but firstly you should check you basic AI setup.

For example:

  1. your mesh character by default have disabled "Can Ever Affect Navigation" - is false, should be true

  2. maybe your capsule is used instead, it is disabled too by default;

  3. Use CCD (collision settings can help too)

You can check you path (is blocked or not) in many ways. For example: https://docs.unrealengine.com/latest/INT/API/Runtime/Engine/AI/Navigation/UNavigationSystem/TestPathSync/index.html

with decorators DoesPathExists: https://docs.unrealengine.com/latest/INT/Engine/AI/BehaviorTrees/NodeReference/Decorators/#doespathexist

If not, you can tell you ai what to do - like nothing, find random location, back to start, back ... units etc. I think it will be key.

This in not whole solution, because this is not that easy. You should look for tutorial on youtube or elsewhere, but my tips can help on start I hope.

Here is something more in project settings, I forgot it now :P Check Engine - Crowd Manager in project settings, this is very important too (if you are using Crowd, what can help a lot with many ai).

Don't forget also to take a look on https://docs.unrealengine.com/latest/INT/Engine/AI/EnvironmentQuerySystem/UserGuide/

more ▼

answered Apr 08 '17 at 04:43 PM

avatar image

Vaheva
1.3k 24 29 52

avatar image Ratatat_RandyTTV Apr 10 '17 at 07:49 PM

Thank you for the in-depth comment. I will try what you have suggested and will post/vote once I know more.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

You could have a volume that adds each zombie to an array as it enters. Then, you could tell each zombie individually to go through the door, and once the zombie passes the threshold or exits the volume, remove him from the array and tell the next zombie to go.

more ▼

answered Apr 08 '17 at 02:59 AM

avatar image

vanlacke
1.5k 65 132 103

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question