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"

Infinite Loop At Less Than 500 Iterations

I made a building system similar to Fortnite and when I destroy the bottom part of a structure with more than ~500 parts, I get an infinite loop error. The way I set up the destruction system is by calling functions and referencing variables on all connected structures but this is less than 500 iterations of the loop. I went into the project settings and tried increasing the max loop iterations to 100 million and that didn't make a difference. and I tried lowering it to 10,000 and I got an infinite loop error at around the same point. Are there other parameters that the infinite loop detection is based on besides iterations and is there a way to fix this?

Product Version: UE 4.20
Tags:
more ▼

asked Oct 03 '18 at 03:39 AM in Blueprint Scripting

avatar image

Fr8TrainWTF
1 2 2

avatar image birdfreeyahoo Oct 03 '18 at 05:06 AM

Post your blueprint, please

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

1 answer: sort voted first

Don't do it in loop then, insted do it in sequence and with timers which allow farther destruction happen in more then just 1 frame, i bet fortnite whatever i does use timers for it's sequential destruction

https://docs.unrealengine.com/en-us/Gameplay/HowTo/UseTimers/Blueprints

If you would do it in loop you would have potential frame freeze on destruction of huge strictures, remember that your code regardless if it's C++ or blueprint executes between frame renders, the longer you code executes the longer engine waits to render the frame, rether engine is being busy running your blueprint code. In case of C++ the code is part of the engine, so engine is not even executed but your code, loops in there will freeze entire engine

more ▼

answered Oct 03 '18 at 01:37 PM

avatar image

Shadowriver
35.8k 927 169 1105

(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