Project Zomboid

Project Zomboid

Enhanced Flashlight Glow
 This topic has been pinned, so it's probably important
Gio  [developer] 22 Dec, 2024 @ 6:21pm
Bug Reports
Post bug reports here

Ideally include
-Any error messages
-Steps to reproduce
-Modlist


Known Issues
Edge-case when a player is holding a lit lighter while using a flashlight.
----Unsure how to fix without hard-coding everything, because it seems like the getters for the light properties always return the lighter values in this case.
Last edited by Gio; 23 Dec, 2024 @ 10:19am
< >
Showing 1-5 of 5 comments
MarshallSantini 23 Dec, 2024 @ 8:42am 
Here is the full error:
function: flashlightChecker -- file: light_controller.lua line # 59 | MOD: Enhanced Flashlight Glow

LOG : General , 1734970854327> Object tried to call nil in flashlightChecker
ERROR: General , 1734970854327> ExceptionLogger.logException> Exception thrown java.lang.RuntimeException: Object tried to call nil in flashlightChecker at KahluaUtil.fail line:82.
ERROR: General , 1734970854328> DebugLogStream.printException> Stack trace:
java.lang.RuntimeException: Object tried to call nil in flashlightChecker
at se.krka.kahlua.vm.KahluaUtil.fail(KahluaUtil.java:82)
at se.krka.kahlua.vm.KahluaThread.luaMainloop(KahluaThread.java:973)
at se.krka.kahlua.vm.KahluaThread.call(KahluaThread.java:163)
at se.krka.kahlua.vm.KahluaThread.pcall(KahluaThread.java:1980)
at se.krka.kahlua.vm.KahluaThread.pcallvoid(KahluaThread.java:1812)
at se.krka.kahlua.integration.LuaCaller.pcallvoid(LuaCaller.java:66)
at se.krka.kahlua.integration.LuaCaller.protectedCallVoid(LuaCaller.java:139)
at zombie.Lua.Event.trigger(Event.java:64)
at zombie.Lua.LuaEventManager.triggerEvent(LuaEventManager.java:92)
at zombie.characters.IsoPlayer.updateInternal2(IsoPlayer.java:2141)
at zombie.characters.IsoPlayer.updateInternal1(IsoPlayer.java:1935)
at zombie.util.lambda.Invokers$Params1$CallbackStackItem.run(Invokers.java:37)
at zombie.core.profiling.AbstractPerformanceProfileProbe.invokeAndMeasure(AbstractPerformanceProfileProbe.java:71)
at zombie.core.profiling.AbstractPerformanceProfileProbe.lambda$invokeAndMeasure$0(AbstractPerformanceProfileProbe.java:83)
at zombie.util.lambda.Stacks$Params3$CallbackStackItem.invoke(Stacks.java:230)
at zombie.util.lambda.Stacks$GenericStack.invokeAndRelease(Stacks.java:26)
at zombie.util.Lambda.capture(Lambda.java:130)
at zombie.core.profiling.AbstractPerformanceProfileProbe.invokeAndMeasure(AbstractPerformanceProfileProbe.java:81)
at zombie.characters.IsoPlayer.update(IsoPlayer.java:1924)
at zombie.MovingObjectUpdateSchedulerUpdateBucket.update(MovingObjectUpdateSchedulerUpdateBucket.java:79)
at zombie.MovingObjectUpdateScheduler.update(MovingObjectUpdateScheduler.java:145)
at zombie.iso.IsoCell.ProcessObjects(IsoCell.java:2955)
at zombie.iso.IsoCell.updateInternal(IsoCell.java:5750)
at zombie.util.lambda.Invokers$Params1$CallbackStackItem.run(Invokers.java:37)
at zombie.core.profiling.AbstractPerformanceProfileProbe.invokeAndMeasure(AbstractPerformanceProfileProbe.java:71)
at zombie.core.profiling.AbstractPerformanceProfileProbe.lambda$invokeAndMeasure$0(AbstractPerformanceProfileProbe.java:83)
at zombie.util.lambda.Stacks$Params3$CallbackStackItem.invoke(Stacks.java:230)
at zombie.util.lambda.Stacks$GenericStack.invokeAndRelease(Stacks.java:26)
at zombie.util.Lambda.capture(Lambda.java:130)
at zombie.core.profiling.AbstractPerformanceProfileProbe.invokeAndMeasure(AbstractPerformanceProfileProbe.java:81)
at zombie.iso.IsoCell.update(IsoCell.java:5696)
at zombie.iso.IsoWorld.updateInternal(IsoWorld.java:3499)
at zombie.util.lambda.Invokers$Params1$CallbackStackItem.run(Invokers.java:37)
at zombie.core.profiling.AbstractPerformanceProfileProbe.invokeAndMeasure(AbstractPerformanceProfileProbe.java:71)
at zombie.core.profiling.AbstractPerformanceProfileProbe.lambda$invokeAndMeasure$0(AbstractPerformanceProfileProbe.java:83)
at zombie.util.lambda.Stacks$Params3$CallbackStackItem.invoke(Stacks.java:230)
at zombie.util.lambda.Stacks$GenericStack.invokeAndRelease(Stacks.java:26)
at zombie.util.Lambda.capture(Lambda.java:130)
at zombie.core.profiling.AbstractPerformanceProfileProbe.invokeAndMeasure(AbstractPerformanceProfileProbe.java:81)
at zombie.iso.IsoWorld.update(IsoWorld.java:3427)
at zombie.gameStates.IngameState.updateInternal(IngameState.java:1617)
at zombie.gameStates.IngameState.update(IngameState.java:1333)
at zombie.gameStates.GameStateMachine.update(GameStateMachine.java:101)
at zombie.GameWindow.logic(GameWindow.java:298)
at zombie.core.profiling.AbstractPerformanceProfileProbe.invokeAndMeasure(AbstractPerformanceProfileProbe.java:71)
at zombie.GameWindow.frameStep(GameWindow.java:765)
at zombie.GameWindow.run_ez(GameWindow.java:681)
at zombie.GameWindow.mainThread(GameWindow.java:495)
at java.base/java.lang.Thread.run(Unknown Source)
LOG : General , 1734970854330> -----------------------------------------
STACK TRACE

Mods used:
mod = ModManager,
mod = BoH,
mod = 93lorevehiclepack,
mod = 90pierceArrow,
mod = 92amgeneralM998,
mod = 92AMGeneralM998MODIFIEDQUICKPATCH,
mod = FRUsedCars,
mod = autotsartrailers,
mod = tsarslib,
mod = FEP,
mod = VVehicleEnhancer,
mod = fhqMotoriusZone,
mod = fhqMotoriusZoneRealNames,
mod = VISIBLE_BACKPACK_BACKGROUND,
mod = BetterCarPhysics,
mod = ExtraMapSymbols,
mod = ExtraMapSymbolsUI,
mod = fuelsideindicator,
mod = GeneratorTimeRemaining,
mod = HandCrankFlashlights,
mod = P4HasBeenRead,
mod = VFExpansion1,
mod = LargeProgressIndicator,
mod = LightSwitchBacklight,
mod = MapLegendUI,
mod = MiniHealthPanel,
mod = modoptions,
mod = MoreZombieDeathSounds,
mod = OCCL,
mod = ProfessionFramework,
mod = PantyRaiders,
mod = PistolProficiencyMod,
mod = ReloadAllMagazines,
mod = RemoveDebris,
mod = RenameContainers,
mod = REORDER_THE_HOTBAR,
mod = SirenVariety,
mod = truemusic,
mod = vcr,
mod = sar,
mod = MapSymbolSizeSlider,
mod = TrueActionsDancing,
mod = SM4Vanilla3DShoesCompat,
mod = VFExpansion2,
mod = VehicleTweakerAPI,
mod = Replace Bandage,
mod = Southwood2.0,
mod = ExpandedHelicopterEvents,
mod = EasyConfigChucked,
mod = 4ColorBicPenFix,
mod = ATA_Mustang,
mod = SpnCloth,
mod = ATA_DeLorean,
mod = Ladders,
mod = 59meteor,
mod = 91range,
mod = CAR,
mod = Load Weapon And Magazine While Running,
mod = TrueCrouching,
mod = ATA_Mustang_x2,
mod = 99fordCVPI,
mod = bmwe30,
mod = 1967ChevroletImpala,
mod = 1989Porsche911Turbo,
mod = TSW_RadiosToAC,
mod = FishFarmMod,
mod = GenRange,
mod = tdm_sal_s281,
mod = AdvancedVolumeEnabler,
mod = AsianStyle,
mod = NepBatteryColor,
mod = ReasonableRepairZ,
mod = VOICE_FRAMEWORK,
mod = VOICES,
mod = NepEngineColor,
mod = NepNearbyTraps,
mod = 84merc,
mod = ATA_Jeep_x2,
mod = ATA_Jeep,
mod = BB_BreakingIn,
mod = UGImprovedCarExit,
mod = TreadsMilitaryVehicleDefs,
mod = TheStar,
mod = mileage-expansion,
mod = StartApocalypseTime-v1.0,
mod = SirenVarietyCompat,
mod = WalkieTalkieModelsB41,
mod = ChangeSandboxOptionsByStar,
mod = ATA_Mustang_66,
mod = DrivingSkill,
mod = RV_Interior_MP,
mod = TakeAnyAmount,
mod = city_pop_4_late_night,
mod = FRUsedCarsNRN,
mod = fhqMotoriusZoneImports,
mod = fhqMotoriusZoneExotics,
mod = fhqMotoriusZoneUSDM,
mod = RV_Interior_Vanilla,
mod = errorMagnifier,
mod = Shot Add Aiming XP,
mod = 69camaro,
mod = Diederiks Tile Palooza,
mod = DylansTiles,
mod = melos_tiles_for_miles_pack,
mod = tkTiles_01,
mod = PertsPartyTiles,
mod = simonMDsTiles,
mod = AddonATH,
mod = ATT_Hauler,
mod = Jump,
mod = TchernoLib,
mod = Lifestyle,
mod = OOG,
mod = CollectibleCarsfhq,
mod = CollectibleCarsLoreFriendlyMZfhq,
mod = fhqExpVehSpawn,
mod = Wallpapers,
mod = fhqMotoriousPosters,
mod = 67gt500,
mod = 90bmwE30,
mod = 93fordF350,
mod = KESVPackR,
mod = autohidehotbar,
mod = AutomaticGateMotors,
mod = CartographyModifier,
mod = Flip or Attach In Vehicle : Attach,
mod = Flip or Attach In Vehicle : Flip,
mod = BB_HighlightFavorites,
mod = KVsNearlyNew,
mod = OMS,
mod = BION_PlainMoodles,
mod = posters_period_accurate,
mod = BB_ScreecherZ,
mod = WCTP,
mod = fhqMotoriusZoneRVInt,
mod = SPH,
mod = AutoTurret,
mod = 87fordB700,
mod = BB_DressForSuccess,
mod = True_Music_Lonely_People,
mod = 93chevySuburban,
mod = 1992HUMMERH1,
mod = BirgetMaleBodyModel,
mod = BuildingMenu,
mod = BuildingMenuSimonMDsAddon,
mod = BuildingMenuMelosTilesAddon,
mod = BuildingMenuDylanAddon,
mod = BuildingMenuDaddyDirkieAddon,
mod = cheeryIntroTripleN,
mod = PlumbHelp,
mod = StartingMagnum,
mod = write_unique_id_use_any_letters,
mod = Wellsburg,
mod = KYRRealWeatherMod,
mod = STFR,
mod = STFRRN,
mod = 49ford8N,
mod = damnlib,
mod = 80manKat1,
mod = 87chevySuburban,
mod = 92jeepYJJP18,
mod = 92jeepYJ,
mod = 1969DodgeCharger,
mod = 1970WHITEFREIGHTLINERCOE,
mod = AquatsarYachtClub,
mod = amclubfix,
mod = amclub,
mod = BuildingMenuGreenhouseAddon,
mod = Greenhouse,
mod = NightKosh_CarDashboardEmergencyLightsAndSirenButtons,
mod = BirgetPMClothingCorrection,
mod = FirstAidVHSTapes,
mod = FixInsidePlayerBuilding,
mod = GPSNAVIGATION,
mod = GunFactory,
mod = MapItemAnimations,
mod = P4MedicalMeister,
mod = DG_MIVehicles,
mod = RainsFirearmsandGunParts,
mod = Taylorsville,
mod = wedivedeep,
mod = BB_WhereAmI,
mod = jemyo2519,
mod = 325i,
mod = US750IL,
mod = AirCond,
mod = HankBFuelTank,
mod = MutiesContextMenuIconsStorage,
mod = MutiesContextMenuIcons,
mod = PortHope,
mod = STFREHE,
mod = STFRLFN,
mod = FRUsedCarsNLF,
mod = SkillsMag,
mod = SnakeUtilsPack,
mod = StandardizedVehicleUpgradesKES_SEVFBI_FRVSR%,
mod = StandardizedVehicleUpgradesCore,
mod = StandardizedVehicleUpgradesFR,
mod = StandardizedVehicleUpgradesV,
mod = VNGarage,
mod = WolfExtractionQuest,
mod = ZFallDamage,
mod = shelters-tileset,
mod = shelter-2238,
mod = shelter-4912,
mod = shelter-4515,
mod = shelter-4125,
mod = shelter-4030,
mod = shelter-2926,
mod = shelter-2533,
mod = shelter-2228,
mod = BuildingMenuPertsPartyTilesAddon,
mod = newcontainersnc,
mod = SharedCheckList,
mod = BirgetFemaleBodyModel,
mod = LightSensor,
mod = SmarterStorage,
mod = TrueActionsDancingVHS,
mod = TrueActionsDancingVHS_MAG,
mod = BuildingMenuOujinjinsAddon,
mod = OujinjinTiles,
mod = BuildingMenuThrottlekittyAddon,
mod = BuildingMenuExtraNoisesFlagAddon,
mod = EN_Flags,
mod = EN_Flags_Craft,
mod = BuildIt,
mod = BuildingMenuExtraNoisesNewburbsAddon,
mod = EN_Newburbs,
mod = ForagignScreenIllustrations,
mod = KATTAJ1_ClothesCore,
mod = KATTAJ1_Military,
mod = [J&G] Desert Multicam Uniform,
mod = CustomizableBackpacks,
mod = Darker Water,
mod = AZA_FANTASY_TILES,
mod = AzaDesertTiles,
mod = Denseenvironment,
mod = DynamicWallClock,
mod = EvenMoreVHSTapes,
mod = HephasOccupationsAndTraits,
mod = Real Firearms,
mod = BB_RoadtripRadio,
mod = TVGuide,
mod = TksRVA2KEScompatibility,
mod = TksRVA2SFREVFBIcompatibility,
mod = TksRVA2ENcompatibility,
mod = TksRVA21993Compatiblity,
mod = TksRVA2frscompatibility,
mod = TksRVA2KI5compatibility,
mod = TksRVA2fhqwhgadscompatibility,
mod = TksVehicleAcceleration2,
mod = HnnssExorcist,
mod = enAutomobileExtravaganza,
mod = enAutomobileExtravaganzaReal,
mod = MutiesContextMenuIconsExpanded,
mod = 300PointsTrait,
mod = ATA_Petyarbuilt,
mod = ahmadrocklifestyleaddon,
mod = TomaroBlackouts01,
mod = CreepinsLifestyleAddon,
mod = CyberpunkGuitarRiffsAddon,
mod = EAGLECUMBALLS,
mod = FantasyMusicAddon,
mod = HephasOccupationsAndTraits_WithVanillaProfessions,
mod = HololiveAcousticAddonDer,
mod = LifestyleSimplePlayablePianos,
mod = LifestyleMoreAcoustic,
mod = NewWorldGuitarAddon,
mod = NIRVANAMUSICYARIKLOX,
mod = PlayableViolin,
mod = MetroLifestyleAddon,
mod = StalkerLifestyleAddon,
mod = StandardizedVehicleUpgradesP_TKSCompat,
mod = StandardizedVehicleUpgradesP,
mod = LastOfUsLifestyleAddon,
mod = UndeadHonor,
mod = ZBRPMusicaddon,
mod = 454604,
mod = discoaddon,
mod = imthesilentuknowlifestyle,
mod = ETO_FPS,
mod = LessGrime,
mod = [J&G] Alpine Multicam Uniform,
mod = ConditionOnDash,
mod = 82firebirdKITT,
mod = 82firebird,
mod = 98stagea,
mod = BiggerCharacterAvatar,
mod = Longer Stats,
mod = TLOUClothingFEDRA,
mod = TLOUClothingSeraphites,
mod = TLOUClothingRest,
mod = 91fordLTD,
mod = 1VCESTANDARD,
mod = 2VCESSPONGIESEXPANSION,
mod = 9VCEPACKRATMODE,
mod = 4VCESURPLUS,
mod = Architect,
mod = B42RainsFirearmsAndGunParts,
mod = Bandits,
mod = BanditsDayOne,
mod = Erikas_Tiles,
mod = Erikas_Furniture_Store,
mod = HashiraKatanas,
mod = JAMGS,
mod = Jerrycans&Hoses,
mod = Lite Backpack,
mod = SpiffophonicXtraLite,
mod = Lawlypops_TPMSIndicator,
mod = KI5trailers,
mod = VanillaAppliancesExtended,
mod = WallpapersBM,
mod = WeaponConditionIndicatorPatch,
mod = Zombie Hunter BackpackAddon,
mod = Zombie Hunter Backpack,
mod = Zombieproof,
mod = visual_sound_extended,
mod = WatchUI,
mod = VSE-FR,
mod = VSE-FR-RnB,
mod = StandardizedVehicleUpgradesZI,
mod = enhanced_flashlight_glow,


Error does not persist when using Katta's tactical flashlight. Error persist when using base game hand torch and flashlight(the yellow one). Error does not persist when using the hand crank flashlight, but the light itself will turn on, but not stay on. The light will immediately turn off.
Gio  [developer] 23 Dec, 2024 @ 9:03am 
@MarshallSantini

Judging by your mod list it looks like you're on B41. I haven't tested the mod on B41 at all, but I'm hoping that this new patch will make it mostly backwards-compatible.

As for the hand crank flashlight bug you mentioned, my mod wouldn't interact with that in any way that would turn the flashlight itself off.

All my mod does is check for a light, then spawn a light source at the player position which gets updated every player update tick.

Uploading the new version soon though which is basically a complete re-write, so let me know if it works.
MarshallSantini 23 Dec, 2024 @ 9:37am 
Thank you so much, I am sorry for bringing this up. I didnt see your mod was for B42. Thats likely where all my issues are coming from. The hand crank issue must be a conflict that I didnt come across until now, so that can be ignored.
MarshallSantini 28 Dec, 2024 @ 4:57pm 
Originally posted by Walter Blanco:
@MarshallSantini

Judging by your mod list it looks like you're on B41. I haven't tested the mod on B41 at all, but I'm hoping that this new patch will make it mostly backwards-compatible.

As for the hand crank flashlight bug you mentioned, my mod wouldn't interact with that in any way that would turn the flashlight itself off.

All my mod does is check for a light, then spawn a light source at the player position which gets updated every player update tick.

Uploading the new version soon though which is basically a complete re-write, so let me know if it works.

I dont know if it was your update or me cleansing my mods list. But the error is no longer persistent. Thank you for all your help and kindness!
Gio  [developer] 29 Dec, 2024 @ 8:53am 
@MarshallSantini

No problem, glad it works.

I will let you know, unfortunately for the mod settings, those are only supported on B42, as I'm using the native mod settings API vs the B41 way of using the mod someone made.

I'm not willing to port this functionality to B41 due to me having to require a dependency of a B41 deprecated mod.

Hope you understand, and are happy with the non-customizable version for B41.
< >
Showing 1-5 of 5 comments
Per page: 1530 50