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"

placing Instanced Static Meshes manually not randomly

Hi All!

I'm trying to manual place instanced Static Meshes in my scene. I see a lot of information on randomly doing this through spawning, but I want to be able to have control of where each mesh is placed. Am I over thinking this or is this complicated. I'm placing rocks around a scene and want them to be instances but I'm going to rotate them in different ways so they look more random. Please help with any information possible.

Product Version: Not Selected
Tags:
more ▼

asked Nov 07 '14 at 01:05 AM in Using UE4

avatar image

walkinginspace
26 12 17 20

avatar image walkinginspace Nov 07 '14 at 10:45 AM

This seems like it would be pretty easy...no takers on a simple setup?

avatar image walkinginspace Nov 07 '14 at 11:19 AM

3 Steps.

 Add StaticMesh (with selected mesh).
 Create an InstancedStaticMeshComponent variable and Set it using the Return Value on the Add StaticMesh node.
 Add Instance, with a Target Input of your InstancedStaticMeshComponent variable and a transform of wherever you want the instance to spawn.

You add the static mesh to get it in the level so it can be copied(not sure why this is needed but it is).

Can anyone show what this blueprint would look like? I tried it but can't get it to work. thanks

avatar image Ayewyn Nov 15 '14 at 05:56 AM

I'm interested in this as well. I have levels that consist primarily of lots of copies of the same the same two meshes. I want to get the performance as good as I can and I think something like this would be a good step in that direction.

avatar image walkinginspace Nov 15 '14 at 08:05 AM

yea, no one has responded so I'm not sure how to do this either. It would be great to find out!:)

avatar image erikhedvall Mar 18 '18 at 02:35 PM

An alternative method might be placing the rocks via foliage tool. They will all be instanced and using LODs. Then using the "foliage single select" (that one that looks like an arrow) you can select individual rocks and move/rotate/scale them. I just tried it with some rocks and it works pretty well, probably not as useful for building parts and such though as I think you have to "paint" them out to start with.

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

2 answers: sort voted first

Make a variable of type Transform Array. Check "Editable" & "Show 3D Widget" in the Details. Add this to your construction Script. https://gyazo.com/a22829420f2af062501653c1fa037098

Place the BP in your level and Select it. In the Details Panel you can Add Transforms to the Array by clicking the "+" sign. Select the Diamond shaped Widget and rotate/scale/move as you like. https://gyazo.com/ea12d7692c1588af87d1906d281ce651

more ▼

answered Jul 02 '16 at 07:00 PM

avatar image

Nachtmahr
6.9k 143 25 171

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

Hey walkinginspace

I think you may be over thinking it, unless there is some aspect of the question that I'm not getting. Make an actor BP that has the static mesh as a component and then add that to the scene manually.

more ▼

answered Nov 15 '14 at 08:08 AM

avatar image

robbiecooper
756 79 60 233

avatar image walkinginspace Nov 15 '14 at 08:19 AM

When i do that, it doesn't see any of the copies of the BP as instances...because the Instancer isn't being called. I tried just making the BP and dragging in. I talked with another user and he said all the copies are still getting a draw call, because they aren't instances.

avatar image walkinginspace Nov 15 '14 at 08:21 AM

Here's what he said

"

Ok, for each copy of that blueprint you are getting a draw call on the static mesh it is spawning.

The reason instancing saves performance is because draw calls are limited by only have 1 mesh that is then copied without the same overhead.

So if you have an instanced mesh, say a Tree, you want all of those trees coming from the same blueprint. You could put other instances in other blueprints, but that really depends on what you are doing. "

avatar image robbiecooper Nov 15 '14 at 08:25 AM

I see what you mean. Definitely an aspect of your question that I wasnt getting... ;)

avatar image walkinginspace Nov 15 '14 at 08:29 AM

:) There must be some way to do this. But as of yet, it has eluded me.

(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