Project Zomboid

Project Zomboid

Enhanced Flashlight Glow
37 件のコメント
Gio  [作成者] 10月18日 13時52分 
@Ġedryht of Wōden
Fair point, I really only considered the implications of using the mod in singleplayer since b42 doesn't have multiplayer yet. I'd be willing to look into it once b42 adds multiplayer.
Ġedryht of Wōden 10月18日 4時40分 
If this was a game setting rather then a user setting, wouldn't this make it more balanced for multiplayer use?
Guicsr_ 6月30日 20時54分 
I didn't notice, but I have to change it in the menu because it's set to default on standard.
Gio  [作成者] 6月30日 20時28分 
@Guicsr_ I just tested it on 42.10 and it's working perfectly. If you can't notice the effect, it might be that the brightness setting is too low for your monitor/setup. Try increasing it in the in-game mod settings.

There are 3 settings for brightness included in the mod.
Guicsr_ 6月29日 21時10分 
Is the mod still working? It seems like nothing changed when I activated it, this was on b42.9
Amroth 3月16日 8時23分 
That's what I initially assumed because the car would glow when turning on the headlights. Turns out, another mod was going through each vehicle light every in-game minute and setting their intensity to maximum, lol.

Sorry for the false alarm. And thanks for the mod, absolutely essential +1
Gio  [作成者] 3月15日 17時40分 
@Amroth I see. I was thinking maybe that turning on car headlights would give increase a player's torch strength or something. Thanks for testing
Amroth 3月15日 17時13分 
I did some more testing, false alarm. Seems to work fine together. It was another mod causing issues.
Gio  [作成者] 3月15日 17時09分 
Looking into it @Amroth
Amroth 3月13日 13時03分 
Is there a way to make this compatible with Nepenthe's High Beams mod?

Both are absolutely essential, but having this on breaks high beams.
Gio  [作成者] 2月8日 0時11分 
@Drestalos The b41 version should work fine I think? It's just lacking the settings like changing brightness level and toggling the lantern radius. I have personally had problems with the texture mod in b41 before though. Definitely remember some sort of flickering occurring with that mod.

To be completely honest though, I haven't tested the b41 version, but the logic is exactly the same for how the light is generated, so it should be identically to the version I have tested. I don't think anything has changed in terms of APIs for what I'm touching since b41 (minus the mod settings).
Drestalos 2月7日 15時59分 
Yea, probably just something on my end, it does shine light outward, but it also flickers; could it be Every Texture Optimised or something? I'm running build 41 for what it's worth. I don't think it's your mod, just wanted to see if it was something easily fixed or required some other testing. I appreciate you getting back to me!
Gio  [作成者] 2月7日 7時48分 
@Drestalos Additionally, the method used for generating light is such that it would be impossible for it to only light your character model. The minimum lightsource that can be made would light up a bigger radius than just the tile your character is on, let alone just your character model.
Gio  [作成者] 2月7日 7時43分 
@Drestalos The mod should only be in effect when your character is actively using a lightsource. I.e. your character's torch strength > 0. Did you try running the mod by itself?
Drestalos 2月2日 18時16分 
Hey big guy, dunno if it's some sort of mod conflict, or a setting I may have on the base game, but when I add your mod, it causes a faint constant lighting flicker on my character model
MyScreamers 1月28日 13時26分 
How cain i expand the brightness radius from all the light sources in general?
Mr. Sinister 1月7日 7時05分 
Need to have Brights for Headlights modded. Now that nighttime is so dark, you can't see anything while driving.
sanki mermer 1月6日 3時06分 
car headlight mods would be awesome!
cause they're real problem you cant drive at night
Dima.V 1月5日 0時03分 
How do you activate a bigger brightness?
Gio  [作成者] 2024年12月26日 15時42分 
@Krow I'd consider it. Not sure on if I'd be able to dynamically apply it like with this mod vs having to hard code it. Seems like a natural evolution after doing this mod though.
Krow 2024年12月25日 19時46分 
This is great! Any chance you'd be interested in doing something similar for cars? Blows my mind that you can only see five feet infront of you while driving
Gio  [作成者] 2024年12月23日 15時22分 
@black_rose

I created the mod pretty quickly, but the problem is the precision in the grid squares make it look extremely bad. Think like, when your character is moving the light radius moving isn't smooth, because it's only updated when moving to a new grid square (since I need to spawn the light on the square).

You can see what I mean if you do something like "right click > walk to". That's the grid the lights are being spawned on, but the player can move quite a distance in one square without it moving, so it causes the jittery light moving that I'm mentioning.

This effect isn't noticeable on this mod because there's already so much light from the other source that it gets really smoothed out.


I can throw you the code if you want to do it yourself, but I don't feel like bothering releasing something that I would never use / think looks bad.
black_rose 2024年12月23日 14時08分 
thats how it always is with these things lol.

also, outside the scope of this mod, but i have an idea for a mod where in the dark theres still a small, grey, lit area around the player to represent your ability to sense/feel your surroundings. idk how simple or similar what you've done here is though
Gio  [作成者] 2024年12月23日 10時27分 
@black_rose

Thanks lol. I love how I made the estimate of 10mins, then I realized my lantern detection code wasn't working, so had to find a fix.

Hope you enjoy the new version!
black_rose 2024年12月23日 10時23分 
A1 job my guy!
Gio  [作成者] 2024年12月23日 8時59分 
@Markovicz

Thanks for catching that lol. I'll fix it

@MarshallSantini

Nice job finding the conflict, like I said, I think this new patch will hopefully fix everything, going to upload in the next 10mins or so.
Markovicz 2024年12月23日 8時34分 
Workshop title: Enchanced ... .. In-game title: Enhanced ... . Just saying :cherrypie:
MarshallSantini 2024年12月23日 8時30分 
Thank you so much for looking into this so immensely! I did some more testing yesterday and found that Katta's clothes comes with a flashlight that I didnt realize. When I turn on that flash light, the error does not appear. So I assume the conflict is with Katta's clothing mod which is overriding your mod. I can still post the mod list and full error if youd like.
I also checked the hand crank flashlight. For me it will turn on, then immediately off. The charge will still go down as if its staying on.
Gio  [作成者] 2024年12月23日 6時54分 
@MarshallSantini

I found a way to not rely on checking items directly. Hopefully this should fix most if not all errors, working on a patch right now, should be done soon.
Gio  [作成者] 2024年12月22日 20時19分 
@MarshallSantini

I tried for a while and couldn't reproduce this error.

The line it's referring to is just making some function calls for a branch decision. The function calls depend on the secondaryItem object, or in other words, what the player is holding in their left hand. I'm pretty new to lua, so not sure if my syntax was slightly off on checking if such an object existed. I tried to make a correction, however like I said I wasn't even able to reproduce it in any configuration of main-hand, off-hand, modded lights, vanilla lights, etc..

If you could please consider posting steps to reproduce along with a screenshot or plain-text of your mod list I would greatly appreciate it.

Sorry if too much technical jargon btw, just letting you know I looked into it. Thanks for reporting.
Gio  [作成者] 2024年12月22日 18時20分 
@MarshallSantini

I'll take a look tonight, can you post your modlist? I'll make a bug report thread to put your mods.
MarshallSantini 2024年12月22日 17時56分 
I must have a conflict of some sort, is there any known incompatibilities? The only flashlight related mod I believe I have is the crank flash light. But I am getting an immense amount of errors as soon as I turn on a flash light. I tired using multiple flashlights, but the error stayed.

function: flashlightChecker -- file: light_controller.lua line # 63 | MOD: Enhanced Flashlight Glow

LOG : General , 1734918722041> Object tried to call nil in flashlightChecker
ERROR: General , 1734918722041> ExceptionLogger.logException> Exception thrown java.lang.RuntimeException: Object tried to call nil in flashlightChecker at KahluaUtil.fail line:82.
ERROR: General , 1734918722041> DebugLogStream.printException> Stack trace:
java.lang.RuntimeException: Object tried to call nil in flashlightChecker
black_rose 2024年12月22日 17時03分 
you are "the bomb" ;)
Mongrel Man 2024年12月22日 14時50分 
@Walter Blanco thanks man
Gio  [作成者] 2024年12月22日 14時37分 
@Mongrel Man

Done.
Mongrel Man 2024年12月22日 14時30分 
Can you add a before and after photo?
CozyCouch 2024年12月22日 14時12分 
thank you! this is a livesaver after the power shutdown!