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 can I do Simple Flying ai Movement?

I am new to blueprints in unreal and I have spent a while trying and failing to get my ai working, I was just wondering if there is a simple way to create an ai that gets a point from a 360* radius and moves there- no navmesh or gravity- like a fish would swim

Thanks for anyone who has the time to help

Product Version: UE 4.18
more ▼

asked Jun 20 '18 at 02:38 PM in Blueprint Scripting

avatar image

10 1 4

avatar image ThompsonN13 Jun 20 '18 at 02:47 PM

for a dynamic system you would need a 3d pathing system. there isnt one built into the engine so you have to come up with your own or buy one. alternatively you could use a set location node and maybe a timeline or interp to just set the location. its not as elegant of of a solution but it would do the trick. this method also has its own limitations though as well.

avatar image Cogganator Jun 29 '18 at 02:39 PM

Sorry for the delayed response but thanks for the help I will look into this

avatar image Nebula Games Inc Jun 29 '18 at 03:54 PM

I created a "simple" 3D flight system similar to what @ThompsonN13 mentioned. I used a collision volume to determine the world bounds and then randomly chose a point within the volume for spaceships to fly towards. Once they were within a certain distance of the target point, I would call a function to select a new point and then calculate the new vector direction from the current direction to the new point. Next I used those 2 vectors and did a linear interpolation between them to change flight direction. It works better than simply changing the location once the AI reaches the target so it feels more "smooth". However, I was unable to get this to work as well as I would like, The linear interpolation really isn't how true aircraft would change direction. You would need more of an "arc" path to the next point with a set turning radius. But for the basics, this would work.

avatar image Cogganator Aug 16 '18 at 04:29 PM

Thanks for the help I'll work on that

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

0 answers: sort voted first
Be the first one to answer this question
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