Project Zomboid

Project Zomboid

[OBSOLETE] Improved Light Bulb Longevity
24 Comments
Laires 6 Jan, 2023 @ 3:23pm 
Alright, I'll finish my current run and then start using that instead. Thank you very much for making this mod. It really made my playthroughs better. Being able to light up bases in areas without natural electrical lights was huge game changer for me and reignited my passion for base building. :)
GenChadT  [author] 4 Jan, 2023 @ 8:14pm 
@Laires No idea. This mod is only a dozen lines of simple code so it's likely the in-game setting is better.
Laires 3 Jan, 2023 @ 1:52pm 
How does it work now with the new sandbox setting that allows us changing the longevity?
PaddiSson_ 17 Sep, 2022 @ 8:37pm 
@GenChadT After further testing, I have the impression that the unused colored light bulbs are updated with this mod. Only partially consumed colored bulbs will not be updated and keep same condition after adding this mod.
GenChadT  [author] 17 Sep, 2022 @ 6:01pm 
@PaddiSson I was mistaken with Alternative Inventory Rendering. I was under the impression that bulb condition would be shown in an expanded view but I had mistaken the feature with something else.

Also regarding the pre-existing bulbs, the mod isn't supposed to update existing items since the code is run on map initialization but if it is currently doing so that's good to know, though I am unsure of how it's doing that.

Glad you're enjoying the mod!
PaddiSson_ 17 Sep, 2022 @ 10:38am 
@GenChadT I tried your mod on my dedicated server, and it seems to work fine. Thanks for your contribution!

" Preexisting bulbs in world will not see their condition settings modified! "
I feel that this is not correct. I just tested the mod on my dedicated multiplayer server with an existing save and the conditions of the colored bulbs in my containers (already spawned) have been upgraded to 100.
I specified 100 as the value for LightBulbsColor_ConditionMax = 100 in the SandboxVars.lua
PaddiSson_ 17 Sep, 2022 @ 8:11am 
@GenChadT, you said " Try the mod Alternative Inventory Rendering. IIRC it will show condition of bulbs when the stack is expanded in your inventory. "
I also use this mod but I don't see the bulb condition indication. I only see this indication for batteries for example. Are you using another mod that could indicate this?
https://imgur.com/a/595H5pM
Laires 5 Sep, 2022 @ 5:10am 
Works great, I absolutely love it. Exactly the type of QoL mod that this game needs more of. I find the vanilla very unrealistic and annoying everytime I have to replace lightbulbs in every lamp after a week. This opens up a lot for me, especially in combination with the generator longevity mod. Both staples for anyone wanting to build their own home from scratch having the only lights consuming lightbulbs. The generator mod also allows you to make near infinite generator condition so you can put them next to roads just to turn on street lights or in different parts of the city you intend on turning into your very own gated community.

The only thing I'm missing now is a battery longevity mod to buff duration for the flashlights on pillars, radios and boomboxes from the True Action mod, but I can make do without that. :)
Madforce2k 27 Jul, 2022 @ 10:50am 
@GenChadT Thank you for the suggestion for bulb condition, the mod looks great for the most part, but lacks some support around relearned recipes if using SkillRecoverJournal mod and marking magazines 'read' if you know the recipe. That's a dealbreaker for our server currently. 'Has Been Read' supports this. So those two mods are in conflict currently. :/
GenChadT  [author] 27 Jul, 2022 @ 10:10am 
I have a beta version ready to support other mods if anyone needs it!
GenChadT  [author] 26 Jul, 2022 @ 12:40am 
@Madforce2k Try the mod Alternative Inventory Rendering. IIRC it will show condition of bulbs when the stack is expanded in your inventory.
Brother Retardicus 25 Jul, 2022 @ 11:39pm 
Thanks!
Madforce2k 25 Jul, 2022 @ 11:03pm 
A great addition would be if there was a way to see light bulb condition on the tooltip. When looking at a stack of bulbs, i can't tell one from the other. Which is 42% which is 100%? It's really a vanilla problem as well, but would be great to know what bulbs I'm truly carrying. Otherwise, I've got to try to install them in a car to see...
GenChadT  [author] 25 Jul, 2022 @ 10:47pm 
@Deus Vult, Infidel The mod affects all newly generated bulbs. You can use it on old saves, but it will only modify the condition of the ones freshly spawned after it's installed.
Brother Retardicus 25 Jul, 2022 @ 10:21pm 
"It is advised to use this mod on new saves only. Preexisting bulbs in world will not see their condition settings modified!"

Does this mean that it will affect light bulbs in undiscovered places or in places which have recently respawned loot?
GenChadT  [author] 18 Jul, 2022 @ 9:22pm 
@wapaks yes it works on MP, provided you are able to start a new save.
WaPaKs 18 Jul, 2022 @ 5:41pm 
working for MP? should i enable on mods and also on server mod?
GenChadT  [author] 17 Jul, 2022 @ 9:44am 
No worries!
KodeMan 17 Jul, 2022 @ 4:16am 
I apologize, it was right there the whole time. Time to get my eyes checked
GenChadT  [author] 16 Jul, 2022 @ 1:22pm 
GenChadT  [author] 16 Jul, 2022 @ 1:20pm 
@KodeMan Just installed the mod on a fresh install. Options appear normally. They are however NOT in their own tab, instead under the regular "World" options. Example given in new screenshot.

Our server is also running the mod and the option is available.

You can also edit the settings in your Sandbox Vars config with these lines:

ImprovedLightBulbLongevity = {
-- Minimum=1 Maximum=1000 Default=100
LightBulbs_ConditionMax = 300,
-- Minimum=1 Maximum=1000 Default=10
LightBulbsColor_ConditionMax = 300,
},
GenChadT  [author] 16 Jul, 2022 @ 1:12pm 
@KodeMan @wapaks Looking into it now
KodeMan 16 Jul, 2022 @ 5:52am 
@wapaks is right, there is no option to change condition.
WaPaKs 14 Jul, 2022 @ 7:56pm 
there is no option