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"

Is there a Spawn actor limit?

Been trying FOREVER to get a particle shotgun system to work.

see: https://forums.unrealengine.com/development-discussion/blueprint-visual-scripting/1484346-limit-on-spawn-actor-shotgun-not-spawning-all-projectiles and https://answers.unrealengine.com/questions/796225/how-to-make-a-shotgun-spread.html if interested

I cleaned up the blueprint finally to something much better, and found if there was ANY delay in the script before the next loop (.01) each particle would fully spawn with everything it was supposed to have. Yet upon removal the FINAL actor would spawn and nothing else.

Just fiddling, I turned off the mesh for the pellet's effect on lighting, shadows, reflection etc (that are all automatically on) deciding I didnt need them and it might improve performance in the end. The result was an increase in spawns of 1-2 to about 6-8.

Realizing that this meant it was probably a performance limitation of some kind i attempted to clear the material from the mesh (turns out that's kind of hard) and ultimately just changed the mesh to the 1x1x1 cube with no collisions generated for it. and it worked perfectly alt text When I dropped in a mesh that was a same size cube with pre-generated collisions the spawn once again dropped It seems that while the system generates the collisions the rest of the loop is operated and the variable used to exit the loop (which also feeds into the maths I set up for altering the angle) finish, causing the pellet to spawn towards the end of the angles. And then the loop exits before spawning the final

Can anyone explain why this happens and possibly elaberate on the limitations of spawning actors inside loops like this? Is there any way to cause them to all still spawn with collisions?alt text

Product Version: UE 4.18
untitled.jpg (26.8 kB)
untitled2.jpg (270.4 kB)
more ▼

asked Jun 05 '18 at 01:46 PM in Blueprint Scripting

avatar image

43 2 2 9

avatar image Cultusfit Jun 05 '18 at 03:27 PM

Reviewing several meshes I found that I can spawn with the shotgun 30+ bushes with material attached and particle effects.

Only thing I could find in common with the 1x1x1 cube and the bushes was that it says "collision prim: 0"

what are prim and might this be what is causing the problem?

avatar image a56444c Jun 05 '18 at 03:51 PM

Prim should be the abbreviation of "primitive". Think of a door mesh. It could have a collision box around the door and another collision box around the door handle. This mesh has 2 collision prims. 0 collision prim means no collision.

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

1 answer: sort voted first


just updating in case anyone comes across this needing help, or about to waste time answering.

I made the projectiles have simple collisions.

The 1x1x1 cube I was using isnt the basic one. It's one in the engine files, it's name includes xyzpiviot or something.  When I tried more complex objects without Primatives they would spawn. I GOT COMPLEX too. I was Spawning 40 trees at a time with full materials, lighting and shadows.

playing around I found anything without primatives would spawn just fine, while it seemed that anything i tried (think they were all imported from blender) what had convex primatives would only spawn up to 4.

I copied the little cube that had almost nothing to it and moved it into a different file, renamed it. At the top i choose collisions and "simple box". figured it would be the easiest to calculate.

Works great. Generates hit events, bounces (I might attempt to use sphere as the bounces are admittedly very strange in behavior at this time)

My theory on this is: Using such things as a quadproccesor there can be data being added/calculated etc in the different cores.

Attempting to calculate a primative for a really small UV Sphere with all that it entails might just take a fraction of a fraction of a second, but if one of the other cores has now processed the loop iterations.....the actor spawns in the wrong place. Then when it checks the loop again it's already completed. 

if anyone knows anything about this i would love more detail. And if there is a way to solve it as it was, such as setting a processing order

more ▼

answered Jun 06 '18 at 07:38 AM

avatar image

43 2 2 9

(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