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"

Trouble with reindexing instances after removing some


I'm trying to add instances around the character player and destruct them when they are too far away.

  • The problem:

The destruction works fine the first time, but once the playerchar move again (and despite that the destruction loop is not triggered), it destroys more instances. It looks like there is as much secondary destructed meshes as the first time, as if it was a trouble with the reallocation of the index. I know that removing instances shrinks the array, but does it explain the subsequent disparitions?

  • The setup:

I'm using a double loop to add instances around by comparing is current and previous location. It checks if there is not already an instance at this location and spawn it. However, to remove instances I have an array who stacks the transformation of each instance. This array is connected to a reverseforeachloop and on key input, if the location transform is too far away from the PlayerChar, the corresponding index item of the instance mesh is removed. The TransformationArray is cleared at each loop and refilled with instanced mesh infos so I'm sure there is no twist between them.

This blueprint is just a test and i could live without solving it but still it bugs me to not understand what doesn't works here.

With apologies for my english and many thanks for any help.


Product Version: UE 4.18
more ▼

asked Jan 20 '18 at 11:18 AM in Blueprint Scripting

avatar image


(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