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"

automatic movement of a static mesh as blueprint

hello, i am quit new and messing around with blueprints. I am not sure wow to make my static mesh to move up and down automatically. When I start the game it shall move up like 1 and then down 1 and repeat it again and agian.... Thats all. I already know how to make my mesh roating automatically. Tnaks in davance! :D

Product Version: UE 4.19
Tags:
more ▼

asked Mar 31 '18 at 06:11 PM in Blueprint Scripting

avatar image

Max2066
10 1 4

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

1 answer: sort voted first

one method would be to use a timeline to set the relative location of the mesh. this method allows a great amount of control at to where and how fast the mesh moves. it is also a simple method that doesnt require any movement component.

the basics of what ive shown in the picture below is you have a custom event that activates a flip flip (each time a flip flop is called it switched the output). depending on the output of the flip flop the timeline will either play forwards or in reverse. a timeline is basically a curve that allows you to change a value overtime. in this case i set the timeline to go from 0 to 1 over 3 sec using a float curve. the upgrade pin of the timeline is called every frame so if you connect it to a set location it will make movement look smooth. ok back to the timeline, once you create a curve there will now be a output pin on the node which is that value of the curve you can use this to either directly change a value on the set location or as ive done using the curve value as the alpha for a vector lerp. in the example below i also called the function again when the timeline finished so that the movement would loop. it may sound confusing but its pretty simple. oh also on begin play i also called the event to initially start the loop.

alt text

capture.png (249.8 kB)
more ▼

answered Mar 31 '18 at 06:29 PM

avatar image

ThompsonN13
10.1k 33 10 25

(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