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 to: move a static mesh between a set of random points?

Hi. I am new to blueprints. I am learning by trying to make a simple VR experience in which 360 Video Spheres appear to be floating around a small level.

Here is an image of what I want to achieve: https://imgur.com/a/1JaVa

The black circle is the 360 video sphere (which I have already created). I just need to figure out how to use blueprints to achieve the movement.

I have tried using TargetPoints and SetActorLocation but am unable to figure out the precise scripting order. I am also new to programming so I am unsure how to approach this.

Perhaps it would be smart to create a node that generates a set of random points each time the level is loaded, and then have the sphere move in between each point, slowly. I do not know how to code this, however. Any help would be appreciated!

Product Version: UE 4.17
Tags:
more ▼

asked Sep 26 '17 at 09:41 PM in Blueprint Scripting

avatar image

JiNNN
31 2 5

avatar image Everynone Sep 27 '17 at 07:08 AM

Perhaps it would be smart to create a node that generates a set of random points each time the level is loaded, and then have the sphere move in between each point, slowly. I do not know how to code this, however. [...]

Yup, that's one way to do it. Depends on what you need, though. Could you clarify whether you need the object to move in straight lines between the points or your want it to turn corners smoothly? Your image indicates the former.

Also, the object does not seem to end up in the same starting position, as in, it's not looping. Is this the desired behaviour? Does it mean that you want it to snap back to the starting point once it has reached the very last one? Or do you want it to keep generating random points in as it goes, indefinitely.

Any of the above is perfectly doable. I'll try to chip in where I can.

Also, I'd like to add point 0 to the list Chaven conjured. Consider defining the exact behaviour first and only then start climbing the steps.

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

1 answer: sort voted first

One lesson I learn as a programmer was to first simply ones objective and then gradually add on complexity to achieve the required result.

Step 1) Can you move the sphere in a linear fashion between two points 2) Can you move the sphere in a sinusoidal fashion between two points 3) Can you create a random trajectory between two points confined to some volumetric bound 4) Can you create an array that can hold a Transform data type with the random trajectory 5) How many data points would you need to generate a smooth flowing animation

Break down your work flow in tasks like the above example.

more ▼

answered Sep 27 '17 at 02:58 AM

avatar image

Chaven
31 1 5 5

(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