How could I prevent endless collisions in a "magnetic field"?
So what I tried to do is to create a custom "magnetic field". I spawn 1300 Blueprint-Actors (in the picture: all the white bubbles) to which I apply a force towards a center point (in the picture: the big white bubble above. Grafity is also applied, thats why they "blob" below the attraction-center). Another side-note: The force is dependent on the distance from the center-point (white bubble above).
The problem is the performance - framerate drops extremely when the blob has formed.
So I tried to separate what exactly causes the huge performance drop and switched off the "magnetic force towards the center" and just let them all fall to the ground after spawning. There was no major performance drop (ofc a bit because I still spawn 1300 actors).
I have the notion that the endless collisions inside this "blob" could be the reason for the performance-problems! The bubbles move all the time because of course there is still a force applied to them.
So general question: How could I achieve a similar effect (magnet force towards a center) and reduce the amount of collisions? I tried "linear damping" which wasn't so successful. I basically want to attract all actors and want them to form a blob like that. Is there another way to achieve this or maybe a trick to improve performance?
Side question: I am not sure whether the collisions are the only problem, since it also might be, that just applying force to so many actors could be the reason, what do you think?
Thank you already very much for you help and opinion.
asked May 26 '17 at 09:24 PM in Blueprint Scripting
Follow this question
Once you sign in you will be able to subscribe for any updates here