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"

Why is my AI only patrolling and not detecting the player?

Hello

I'm trying to setup some simple AI, so I followed this tutorial: https://www.youtube.com/watch?v=VAAHKNoIg0w∈dex=1&list=PLV0qBSMhzPz4-x3bYt2q01c2PjXmUl1eX

But my AI is only patrolling, it never seems to find the player..

Inside my BTS Detect Enemies blueprint it never active attack/chase..

The first screenshot the player is in front of the AI.. Second is when AI patrols..

alt text

alt text

Can anyone help me?

Product Version: Not Selected
Tags:
ai_detected.jpg (406.9 kB)
ai_patrol.jpg (405.5 kB)
more ▼

asked Aug 02 '14 at 09:13 PM in Blueprint Scripting

avatar image

Xenosis
32 16 22 26

avatar image Xenosis Aug 03 '14 at 02:22 PM

No one know how to fix or can provide a working sample?

avatar image Roy Aug 04 '14 at 04:02 PM

Hi I'm Roy I would give you a tutorial. Are you using Navmesh?

avatar image Xenosis Aug 05 '14 at 08:10 AM

Thanks for the offer Roy, But with samples and images the other nice people have provided, I think I got enough to start experimenting with AI..

avatar image Roy Aug 06 '14 at 09:46 PM

Hi, Here are some video tutorials of AI system implementation UE4 AI System implementation

avatar image Roy Aug 06 '14 at 09:46 PM

I will be updating the list.

avatar image Senyor Festuc Jan 09 '16 at 01:15 PM

Man, i'm having exactly the same problem after so long. Did you solve it? If then, how? I just don't know what else to do :(

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

4 answers: sort voted first

IT seems that the enemy detection is breaking on reading "enemy actor" key value from the blackboard. Do you set this BB key value somewhere?

As a side node, you can always put a break point on any blueprint node, and once the execution breaks on that node mouse over pins to read their current values.

Let me know if you have any more questions.

--mieszko

more ▼

answered Aug 04 '14 at 04:02 PM

avatar image

MieszkoZ STAFF
7.3k 223 57 412

avatar image Xenosis Aug 05 '14 at 08:16 AM

Thanks..

I will try to look at my BB files and see if I can spot my mistake..

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

I followed the same tutorial and had some issues myself. When I started, I had never seen, much less used, a behavior tree before. I did manage to get enough out of the tutorial that I was able to rework a good bit of it, and I got a working setup now. I can't guarantee this will work for you, or that it's even the right way, but it works... I made some screenshots, but I'm not sure how many I can attach to a post, so this may be multiple posts :)

hmmm.... seems I can't post pics at the moment :( I'll keep trying... In the meantime, I created a zip of the screenshots and put them on my dropbox: BehaviorTreeService.zip

more ▼

answered Aug 04 '14 at 07:28 PM

avatar image

Kronykus
144 1 5 7

avatar image Kronykus Aug 04 '14 at 07:37 PM

Looks like switching browsers worked. Here's what I have (5 shots total):

alt text

alt text

bts_1.png (275.7 kB)
bts_2.png (298.9 kB)
avatar image Kronykus Aug 04 '14 at 07:45 PM

alt text

alt text

bts_3.png (421.0 kB)
bts_4.png (381.9 kB)
avatar image Kronykus Aug 04 '14 at 07:46 PM

alt text

bts_5.png (370.8 kB)
avatar image Kronykus Aug 04 '14 at 07:54 PM

I just realized that I'm using a library function I made to check line of sight, so to be complete:

alt text

library_los.png (376.4 kB)
avatar image Xenosis Aug 05 '14 at 08:24 AM

Cool thanks.. Definitely very useful..

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

Hey Guys Whats Up,

I'm including the updated A.I. Project from the tutorial above here for you. It also includes Owen shooting.

https://www.dropbox.com/s/jad8wmx959ozb9s/AIProject.rar

Thanks,
Peter

more ▼

answered Aug 05 '14 at 05:28 AM

avatar image

PeterLNewton
2.1k 75 36 110

avatar image Xenosis Aug 05 '14 at 08:34 AM

Thank you so much for uploading..

And great work on the tutorial, even though I manged to mess up somewhere :)

I will play around with it and see if add some more functions to the AI..

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

answered Aug 06 '14 at 09:55 PM

avatar image

Roy
25 10 12 16

(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