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 do I increase A.I Speed

So I am developing an A.I for my game and I am using a behavior tree

My first branch has the highest value and it actives if the user is 1000 units away, the character will move to a given point

But I want them to run there but only on that branch none of the others

So I am trying to set my character movement to change but I am a bit stuck on how to do it (this is what I have so far)

Here is a look at my tree

alt text

and here is the movement bp thats not working for me

alt text

I have been able to tell thats its a problem in the movement bp as when I simulate it never stops, so it can move to the Movement execute (Which means he doesnt Move at all)

Any help would be great

Product Version: Not Selected
Tags:
ai1.png (59.2 kB)
ai2.png (154.7 kB)
more ▼

asked Mar 16 '16 at 12:37 AM in Blueprint Scripting

avatar image

Jamiex304
41 23 15 21

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

2 answers: sort voted first

Oh I just noticed the movement increase is set as a service, make it a task and give it a finish execute and it should start working....sorry I missed that earlier I thought it was a task already.

more ▼

answered Mar 16 '16 at 01:17 AM

avatar image

Black Phoenyx
4.2k 165 9 170

avatar image Jamiex304 Mar 16 '16 at 01:24 AM

It is a task and what do u mean by a finish execute ?

avatar image Black Phoenyx Mar 16 '16 at 01:28 AM

It says BTService in the screenshot after the set max walk speed you need to add a finish execute node right-click and start typing finish execute it should show up, once it does you need to connect it and check the bool to true, without it the task will never return as finished executing which is why it is stuck not doing anything.

avatar image Jamiex304 Mar 16 '16 at 01:43 AM

Thats just what I called it, (it is a task) and I tryed putting in the boolean and the excute no look that tree still gets stuck on the movement increase heres what i have alt text

ai3.png (109.4 kB)
avatar image Black Phoenyx Mar 16 '16 at 01:49 AM

OK I think your cast is failing, from cast failed add a print string and from Owning actor drag it to the string value on the print string node so it will print the owning actor display name. Where did you get the CheckTrue bool variable? I meant just check the box for the bool on finish execute you didn't have to make a new variable.

avatar image Jamiex304 Mar 16 '16 at 01:59 AM

I did that and it is failing it just prints out Aries Controller 23, if I stop and run again it gos to 24 on so on ?

avatar image Jamiex304 Mar 16 '16 at 02:01 AM

GOT IT, alt text

Thanks for the help debugging

ai4.png (123.2 kB)
avatar image Black Phoenyx Mar 16 '16 at 02:03 AM

Perfect glad you got it, don't forget to mark this as resolved/answered.

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

Once you are at the point that you no longer want the AI to run fast make another task to fire after to set the max walk speed back to the starting speed. That should allow for the rest of the tasks to execute with the AI moving at the normal speed.

more ▼

answered Mar 16 '16 at 12:42 AM

avatar image

Black Phoenyx
4.2k 165 9 170

avatar image Jamiex304 Mar 16 '16 at 01:03 AM

But the problem is that the A.I is not moving AT ALL ??

avatar image Black Phoenyx Mar 16 '16 at 01:07 AM

Oh...You never mentioned the AI wasn't moving at all, or I have missed it somewhere above. Do you have a NavMesh Bounds in the level?

avatar image Jamiex304 Mar 16 '16 at 01:14 AM

Yes I have a navmesh, the A.I was working grand before I added the movement increase, now he just stands still, I am assuming that my movement speed increase blueprint is not working

(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