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 make AI patrol 2 points and repeat

Is there way to achieve this in blueprints so that it can be dragged and dropped anywhere in the level and act the same?

Product Version: UE 4.9
more ▼

asked Mar 19 '16 at 12:22 AM in Blueprint Scripting

avatar image

43 26 31 38

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

1 answer: sort voted first

Ok this is a really basic setup (you can expand upon it to fit your needs) but you essentially set the 2 locations or patrol points and tell the AI to move between them and loop back again I added a 2 to 3 second delay before they go to the next patrol point in the middle...like this:

alt text

aisimplepatrol.png (165.1 kB)
more ▼

answered Mar 20 '16 at 09:17 AM

avatar image

Black Phoenyx
4.2k 165 9 170

avatar image grandcoders.com Apr 03 '16 at 03:19 PM

Thank you, is the Self var a custom one? I don't have it in BP_PawnEnemy. doesn't work yet, I think because of Pawn possession

avatar image Black Phoenyx Apr 03 '16 at 10:34 PM

No it isn't a custom variable, to get that node drag off the pawn pin and start typing self and you should get a reference to self in the search that's what that variable it. As long as the controller is set to an AIController or a custom controller you create it should work.

(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