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"

AI perception update slow already with 20 actors

How to optimize AI perception update to stay fast? When having some near 100 characetrs in pool, I cant find away to prevent it having effect on AI perception update speed. Delay gets around 5-20seconds. When having 20actors the delay is already 0.3-0.6seconds (the debug ball updates with that rate). Tested this in empty map only with the actors. View distances are 5500 at most, and half view cone 90.

I have set component tick off for AI perception component, stopped brain component logic, disabled tick for whole AI controller, but no effect.

If affiliation settings have effect, would need to way to mark wanted pawns as enemies. Also disable wanted pawns to show in perception system at all. All animals are currently showing.

Not using AIPerception component events. Instead having own timers to slowly copy currently perceived actors to variable and then checking it with slow rate.

Is there some more tricks how to get it faster. Would hope to have around 40-60AI at one time without response times getting over human reaction time.

Else having smooth fps staying over 60, so bit lost why it behaves like that.

EDIT: Looks like its only the sight that is slowing down. Hearing is instant.

Product Version: UE 4.17
more ▼

asked Nov 02 '17 at 06:59 PM in Blueprint Scripting

avatar image

333 15 33 41

avatar image jimd667 Jan 15 '18 at 09:20 PM

Did you ever figure this out? I'm curious myself because perception is an important part of the AI system and if its being slowed down I want to know if its the engine or the code you wrote causing the slowness.

(comments are locked)
10|2000 characters needed characters left

1 answer: sort voted first

I don't think, you can have dozens of ai, all tick with perception and other complicated behaviors. Crows have no individual intelligence, but mostly following leader (or "game director").

You need different approach (code solution, no matter bp or c++). For example you can make group leaders, for every 10 or more ai. Only leaders will use perception, others will just follow leaders. However, perception system is as I know obsolete and it will be mark soon if not already.

Would be nice game with 100 characters and they all have sophisticated ai, perception etc working same time, but I don't know game like this, maybe I'm wrong.

Use crowds with leader, and better create own perception system.

In your case, from memory - check perception and/or stimuli update. Maybe is every tick for every ai actor...

more ▼

answered Jan 15 '18 at 10:33 PM

avatar image

1.3k 24 25 49

avatar image SaOk Jan 16 '18 at 12:16 AM

I have moved civilians, zombies and animals to use simple traces (sphere trigger detecting pawns slowly near the pawn, only then checking line of sight with trace). That gave nice boost for perception, but not yet tried with heavy amount of AI. Shouldnt have much problem at the end. Could use different tricks like that group leader focus if needed.

(comments are locked)
10|2000 characters needed characters left
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