More Efficient / Less laggy lighting?

Hello, I’m in the process of building a new hotel and as the build has grown in size and detail over time, I have realized that the game’s part count will probably become an issue when I want to release the game. Currently, the lighting is similar to how it would be in real life, each individual lighting fixture emits light for the area under/around it. I wanted to test and see how much better the performance is without all of the extra parts from the hotel lighting, and it’s nearly half of the parts of the entire build.

With the lighting, as you can see here, there are 48.934 parts.

Without any lighting, there are 24.747 parts.

As you can tell, the atmosphere of the game without the lighting is much more dull compared to with all of the lighting. I’m a little stuck on what to do…I like how much quicker the game play is without all of the extra parts but it feels so lifeless. Is there a smarter or more efficient way that I could do the lighting? Maybe lights only being on for people if they are in range?? or would that cause more lag? The problem is each can light has 3 parts, the frame, the ‘bulb’, and the ‘lighting source’ (spotlight, pointlight); and other lighting has more parts depending on the type of fixture.

Anyways,
Not really sure; just in a weird place right now and other opinions/feedback on this subject would be appreciated. Thank you!

2 Likes

I don’t know is it possible ( I’m not much of a coder… ), but you could make something that allows players to be able to choose to have lightings or not. Hopefully I helped!

Your idea of loading lights in is a great idea in my opinion. Use Region3s to check if player is in the area, and if they are display certain lights to them.



You can add a “Low dettail mode button”