Guideline Performance for Spawned Lights

What should I do for lights that are spawned when playing? It shows “5000” objects not built, and it makes my game extremely slow. Is there anything I can do, or I have to add them before the game starts?

If they are positioned at random locations then you should set their mobility to Movable(in which case you need to use AddComponent node instead of Spawn Actor), and disable Cast Shadows if you can. Otherwise place them manually as static or stationary lights and then build the lights before playing.

In that case just set the light’s mobility to Movable inside it’s own blueprint. Movable lights wont give you unbuilt lighting error but as i previously said you may need to disable their shadows as they can be quite performance heavy.

The light itself is a blueprint which has a change color depending on condition thing, so anything else I could do ?

I see, Ill give it a got. Thanks