The number of lights is 10

If the number of lights exceeds nine, the scene will crash if you solve the problem of multiple lights in the scene?

there will be a hardware specific limit and yes 10 sounds like the right ballpark. @kzhsw thread is a potential nice solution.