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"

Use Timeline to move actor in relative X-axis

I'm using the timeline to animate an actor forward on the x-axis using the Add Timeline node. Just noticed that it's been moving them forward in the world x-axis. Any way to have this move their forward personal x-axis?

Thanks, Jack

Product Version: UE 4.18
more ▼

asked Feb 02 '18 at 06:44 PM in Blueprint Scripting

avatar image

Jack W Lewis
9 4 5 8

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

1 answer: sort voted first

All you need to do is calculate target location by multiplying actor's forward vector with desired distance and then adding to current location. This is corrected version alt text alt text

asd.png (154.8 kB)
asdf.png (30.6 kB)
asddd.png (173.1 kB)
more ▼

answered Feb 02 '18 at 11:29 PM

avatar image

407 8 4 8

avatar image ThompsonN13 Feb 03 '18 at 12:04 AM

I do agree with your overall method here but i see one problem. the problem is that every time there is an update from the timeline you are getting the actor location this could lead to problems toward the end of the timeline, essentially if im not mistaken it could lead to an exponential increase of the movement speed of the object being moved. in general it will move much faster than it should. to combat this problem set two stationary points for the lerp. so when the input is pressed set both the start and endpoint as variables.

Edit: Sardorian updated his picture so my comment can now be ignored.

avatar image Sardorian Feb 05 '18 at 02:13 PM

Yes you are damn right. Setting both endpoints is vital in here =D

avatar image Jack W Lewis Feb 03 '18 at 04:46 PM

Thanks. That worked perfect.

(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