@blackyps said in Removal of the Blinking lights:
How about a compromise? We get rid of the complicated color changing logic but keep the lights. We just have to decide on the color we want them to have.
I think a lot more people are aware that the lights exist than know that they change color on conditions. And I agree that keeping them for visual detail would be nice
I'd be fine with this compromise - as long as it entails it is a 'run and forget' action and no intermediate updating. There is really no value in that especially considering the low number of people that were actually aware of these lights to begin with.
@nine2 said in Removal of the Blinking lights:
How much performance impact does the blinking have?
Curious how you measure the performance before/after this change reliably, because that sounds quite hard to do.
Probably not possible but would be cool if blink effects didn't affect sim state - then enabling such fx could be a setting. And then we could have adaptive performance where the game automatically reduces settings when your fps sucks.
It isn't about the frames per seconds, it is about the simulation speed.
It involves logic that can cause a desync, but one that can be ignored as we're just skipping on emitters and not doing less damage or anything like that. Therefore one can make a comparison by running a saturated replay twice on the fastest possible speed: one with the blinking lights and one without and compute the difference in time. I've done this in the past for other pull requests - it is possible but tricky to setup.
Note that the expense is not so much in the lights itself, it is in the bookkeeping of the lights:
All of these involve table operations, in particular when changing the lights. And to make matters worse: the table.remove has a complexity of O(n). Every factory and storage has these lights (but is not limited to those) the table can easily have dozens if not more than a hundred entries. And as the destruction of factories and / or storages are not unusual this has an additional load on the simulation when fighting.
@mazornoob said in Removal of the Blinking lights:
Is it possible to change light color globally in some way, some shader magic or such? We could then have a single loop that checks stall status. All the factories and such would then only have to change the color when they start/stop producing, which is probably cheap.
Yes, this is possible in a similar fashion to what Nomads did. But that would be on an individual basis. But again - for what purpose? You can see a unit is being made by looking at the factory. The lights do not work through the fog of war.
I'll re-iterate what I've said in the past: there is a line where we as a community have to choose between features and performance. Some features are so critical that we take a hit on the performance and in return we get better gameplay. One example is the overspill feature, that we managed to improve with a factor of ~ 7 last month (going from 60 ms /tick to 10 ms / tick with a base line of 2ms / tick). Other features are so key to visuals (like tank tracks, explosion effects) that I too agree that it is best to take a hit on performance in trade for some visuals.
But is this feature worth taking a hit on the performance for?
I'd say no .