-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Candles, lighters, and inhalers not spawning with random charges anymore. #44071
Comments
Somewhat related, it's probably important to make sure that the solution to this shouldn't effect player's starting inventory, or at least shouldn't effect it as strongly. |
I'm trying the most current build and it looks like like random charges started appearing again. I'm not sure if something changed but I'm even seeing candles, lighters, and inhalers with random charges again. In earlier builds most items would either be empty or full. The only exception were guns. It still looks like lighters/refillable lighters namely that are zombie loot are still spawning with either 0/100 charge or 100/100 charges. Everything else looks to be fixed. |
I have also tried checking for items with charges that may do this.
Ill keep a lookout for anymore and add to the list. |
I think this is because of item group entries lacking both the "charges-min" and "charges-max" properties. I haven't managed to track down where in the C++ code this is handled, but it's pretty easily verifiable through inhalers. Every possible spawn for them where those properties are not defined results in empty inhalers, but the one spawn where those are defined (inside of house bathrooms) results in inhalers with proper amounts of albuterol. It looks like there are two solutions to this: add those properties to every single appropriate item spawn or adjust the code that checks for those properties. |
according to the comment from undeadmoose on sept 10th, this issue is solved already. please let me know if i'm closing this in error. |
I was under the impression that this issue refers to most item spawn, items spawning with the same amount of charges or without charges or magazines etc thus my interest in adding more randomization to items/itemgroups, see #44713 #44654 #44629 #44592 #44554 there are still some places where items still spawn empty and/or full always, not sure if this is a good enough argument to keep this issue open but I wanted to finish this branch https://github.com/casswedson/Cataclysm-DDA/tree/more-rando basically the same as the other pull request I mentioned, but a bit bigger, that will fix some charge/magazine issues, npc inventories, and other misc things I felt this issue refers to, such as the warehouse at the military base always spawning tons of empty batteries. |
Describe the solution you'd like
Having candles, lighters, inhalers, matchbooks, and other items have random charges again.
Describe alternatives you've considered
Leaving them how they are in a black and white phase of either having a full charge or no charge whatsoever.
Additional context
Seems odd that items are no longer spawning with random charges anymore. Wasn't sure if I should have put this as a bug report because I vaguely remember a PR getting merged (for lighters and candles) that made it so that items are either black and white with their charges (either 0/100 or 100/100). This also had the effect of making an asthmatic character slightly harder to play due to having full inhalers spawn at such a low rate. Seems weird from a realism perspective that there is no variation with charges on some of these items either.
The text was updated successfully, but these errors were encountered: