CleverRaven / Cataclysm-DDA

Cataclysm - Dark Days Ahead. A turn-based survival game set in a post-apocalyptic world.
http://cataclysmdda.org
Other
10.32k stars 4.14k forks source link

Lightstrips do nothing but delete batteries #54831

Closed ChucklesTheBeard closed 1 year ago

ChucklesTheBeard commented 2 years ago

Describe the bug

Lightstrips used to be a long-lasting but un-toggleable light source for reading at night.

Right now, they seem to instantly run out of charge, delete batteries, and revert to "lightstrip (inactive)" when activated.

Steps to reproduce

  1. Obtain lightstrip & light battery.
  2. Reload lightstrip with battery.
  3. Activate lightstrip.

Expected behavior

"You irreversibly activate the lightstrip."

"lightstrip (inactive)" turns into "lightstrip (active)", providing a small but un-toggle-able light source and slowly draining the attached battery.

Screenshots

https://www.twitch.tv/videos/1276924772?t=02h54m10s

Versions and configuration

Report taken from a stream, I don't have this in the debug menu's format, sorry.

Game version 9dbadbd

Mod list: Dark Days Ahead Disable NPC Needs No Fungal Growth Bionic Professions Aftershock

Additional context

also reported on Reddit - https://old.reddit.com/r/cataclysmdda/comments/sbtt05/lightstrips_dont_work_at_all/

coyo7e commented 2 years ago

Is this a dupe, or is another person bringing it up? I could swear someone posted the same basic thing within the last 24 or 48 hours but I cannot find it via searching now.

Lightstrips should not last that long in any case since they are just raw-dogging to a battery which ought to burn them out within moments, if not a couple minutes. That is the entire point of breadboards and resistors, etc. I am pretty sure the last post of this same issue last night or so, I said how you can put a motor onto a power source and not give it a load, and it'll literally explode on you within a few seconds.. I'm a redneck, you can youtube others doing the same thing and yeah, it legit melts the housing and throws molten metal all over the room within seconds of turning it on - giving "unlimited energy" to a engine (whether it's a v8 or a light bulb or a lawn mower motor) with no load, equals bad things dude, you need some friction to force those horse powers to not run free in molten metal-explosion form.

Friction/resistance is sort of important, to put it in a really dumbed-down form. I am only a bare amateur but I've blown up plenty of stuff mussing about with it to the point I always wear protective gear and have a fan blowing exhaust out the window before I even start to muss with that sort of thing anymore lol. I'm sure someone who wields a multimeter and voltmeter and soldering kit professionally and is certified could make me sound dumb however, I'm still pretty sure that basic safety protocols are important and putting an energy source to a output without resistance or load equals bad times.

Ignoring basic electronics theory is not the way to make light sources which have no negatives as opposed to actually learning the skill and making a flashlight or lamp, etc.

You can test this IRL - find an LED light, spread the contact and touch them both to a AAA battery, AA, or 9V etc. It'll go "pop!" and smell like burnt plastic, instantly. The light will never work again. I'm a hobbyist amateur electrical engineer which means I take apart a lot of small home appliances and then try to re-use the parts in other projects, often involving raspberry Pi's, etc.. And good lord I blow out lots of LEDS (if you want a good cheap source of LED lights to waste, look in the after christmas area at wal-mart etc, and buy a string of lights for like 99 cents - the non-strobing kind because the ones that flicker are extra complex and are hard to work with as a noob, and you'll spend legit hours taking them apart and love every minute, but they are legit way more complex than normal LED lights and it would take hours to discuss how and why)

Torches are a good alternative if you're really desperate for light in-game. The recipe ingredients are a bit iffy at times when you really SHOULD NOT be dipping a stick and a rag into raw gasoline, for safety's sake, but they're pretty easy to make and give as much light radius as a survivor headlamp. Just be sure, while crafting, to choose option 2 "drop on ground" so you do not unwield the torch and lose your light while working.

moxian commented 2 years ago

Lightstrips are not even craftable anymore (they used to be) I think the better way would be to completely remove them, and replace with light bulbs.

The only way to obtain lightstrips currently is by deconstructing flashlights anyway, and the only reason we are getting those, and not lightbulbs is a technicality of the components ordering in the recipe.

One can argue that it'd be nice to have a low-brightness night reading light recipe (out of a light bulb and some random hand-wavy electronic parts (treat them as appropriate resistors if you will)) that can be turned on and off at will "as a replacement", but given the existence of this bug, it'd be more of a new addition technically (or "re-introduction" maybe).

ChucklesTheBeard commented 2 years ago

Hm, I wasn't expecting electronics rants. This issue is regarding a cut and dry bug report. If there's a balance issue of where lightstrips are sourced from, or if the description doesn't line up, that should really be addressed separately.


I searched for duplicate issues. You may have seen it discussed elsewhere but I don't see anything on the issue tracker.


The negative for a lightstrip has always been the (rather silly imo) notion that you can't shut it off; it will, most definitely, use up a battery, and if you're spotted you must dispose of it to hide in the dark again instead of just toggling it inactive. Are individual components tracked in any other recipes? If not, does it really matter that much if a car headlight LED assembly or the electronics of a flashlight, which itself takes a battery gets plugged into a battery? Is it really that much of a stretch to suggest the survivor also used something so complicated as one resistor to bring the power draw & brightness down?

The description doesn't say "this is a simple LED" it says "This is a light-emitting circuit that can be wired directly to a battery"

chrispikula commented 2 years ago

@coyo7e Any lightstrip you can buy tends to have in-built smd resistors for every two or three LED's on the strip, no worries about burning them out, just apply the proper voltage range.

coyo7e commented 2 years ago

"Any lightstrip you can buy" As in the ones you install onto a pickup as a "bully-bar" or something? Yes of course they have everything needed installed to the point a drunk hick can put them onto a truck with nothing but a screwdriver and a drill however, taking apart a lamp or flashlight doesn't end up with a lightstrip and all resistance etc already included - the PCB is usually obscure and falls flat off the item(if you don't scorch it on accident as an amateur), which is why you cannot get a "breadboard" off every piece of electronics you take apart.

Most newer electronics also cut the leads off of everything that's soldered to a board, which means you cannot even re-use the parts unless you're really, really good at soldering and handling tiny bits of metal. I go out of my way to glean older electronics from the 70s-80s-90s IRL, largely because they were crafted by hand and that means you can disassemble them by hand and get usable parts from them.

Go to the dollar store, buy a few electronic doohickies, and take them apart, tell me how many usable parts you come away with - not many! They're designed that way.

chrispikula commented 2 years ago

Er, I was under the impression that lightstrips in this game were specifically a lightstrip, that is, a technological divergence from the real-world usage of bulbs everywhere. Has that changed? And by lightstrip, I was initially thinking the ones that you can stick under your counter. These things: image

Also, what would you buy today that is still monolithic through hole? :-p That stuff is bulky, and bulky=somewhere you can save money. I remember back when I did salvage old tech, and anything hand soldered always bent the leads so you couldn't even take them off even after removing the solder. Even with a solder pot, you couldn't reliably get em off without a decent chance of ripping a lead or two off an IC.

coyo7e commented 2 years ago

If they were that kind of thing, it wouldn't make sense to receive them from every flashlight.

And I'm sorry, but I honestly had no idea what "monolithic through hole" means however, it does represent most cheap electrical stuff you can find these days - nobody wants to waste extra material and nobody wants you to take it apart so it's more common than not, to open up a cheap piece of electronic gear and find that every lead was cut flush with the PCB before being machine soldered. At least with older stuff you have a chance to not break off a lead and end up with something usable.

Zireael07 commented 2 years ago

@coyo7e: Yep, probably some confusion and/or holdover from the time when CDDA was supposed to be set in more of a future/sci-fi-ish world.

chrispikula commented 2 years ago

And I'm sorry, but I honestly had no idea what "monolithic through hole" means however,

It if has leads that go 'through holes' in a pcb, and if it's a through hole IC, it's monolithic. If it's not though hole, it's surface mount. Surface mount components cost fractions ~80%-50% that of monolithic components.

Monolithic: image

Surface mount stuff with two via's (holes) for a monolithic component in the centre: image

I just looked up the cheapest 500ohm, non bulk order 500ohm resistor on digikey. Through hole: https://www.digikey.com/en/products/detail/vishay-beyschlag-draloric-bc-components/SFR2500002493FR500/595763 vs surface mount: https://www.digikey.com/en/products/detail/panasonic-electronic-components/ERJ-1GNF1500C/2036016

Savings for surface mount go up in bulk, at around 100 it's 20%, by 5000 it's 50%. You save on board surface area, fewer via's, you can use pick&place machines more easily, more convenient machine feed packages, smaller freight costs, smaller pcbs, you can use reflow ovens, etc. The other reason old stuff is called monolithic is because it's old, and out of date, from the stone age. :-p

Maleclypse commented 2 years ago

Has this been confirmed as a bug?

ChucklesTheBeard commented 2 years ago

It's happened to at least 2 people separately. I haven't confirmed it's still present since seeing it happen live in the linked stream.

On Tue, Feb 1, 2022, 2:44 PM Maleclypse @.***> wrote:

Has this been confirmed as a bug?

— Reply to this email directly, view it on GitHub https://github.com/CleverRaven/Cataclysm-DDA/issues/54831#issuecomment-1027219948, or unsubscribe https://github.com/notifications/unsubscribe-auth/AC7UVYKE3JZJMJF3TZ4Y2QDUZAZYTANCNFSM5M4NY4JA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

coyo7e commented 2 years ago

I just spawned a lightstrip (inactive) and stuck a battery into it, it immediately turned on, displayed the battery, and I was able to unload the battery with no ill effects.

FWIW there are two distinct lightstrip items in the debug spawn menu, one that seems to have no battery and is turned on and seems to run indefinitely and cannot be reloaded or unloaded (its item description says it has a battery wired to it), while the one labelled "(inactive)" can be reloaded normally and basically functions like a reading light, and says it's not wired to a battery. They seem to be distinct items although seemingly identical, so it may be an issue of the wrong one being the result of disassembling certain items.

image

image

image

image

The one NOT labeled as (inactive) spawned in turned on and providing light, but can't be reloaded, unloaded, or "i"nserted into, and wielding and attempting to disassemble it, it just doesn't show up in the inventory list of items. It seems to basically be a atomic reading lamp labeled as a lightstrip, but can't be activated etc:

image

The lightstrip (inactive) can be manually activated and is labeled as "turn on" in the activation menu, and works logically with a battery, and without a battery it gives feedback that it "is empty!" The item description says you cannot turn it off (or back on, logically), but you totally can.

ChucklesTheBeard commented 2 years ago

Confirmed

image

Steps to reproduce:

  1. Obtain flashlight.
  2. Disassemble flashlight to obtain lightstrip (inactive).
  3. Obtain light battery.
  4. Reload lightstrip.
  5. Activate lightstrip.

I also reproduced the issue by debug spawning a lightstrip (inactive) and light battery.

@coyo7e Could you run a debug report please? Debug menu -> info -> Generate game report

coyo7e commented 2 years ago

@ChucklesTheBeard No problem, I'm currently running the newest experimental version as of 2/1/2022 I think, I usually hit the update button in the morning each day. I can't upload a copy of the charfile I'm using since I didn't start the thread.

Any idea what version the stream you were watching was using by chance? If they were on 0.F on something, who knows what's been changed/fixed/etc since then.

I don't have a twitch account apparently anymore, so I can't easily access the stream you provided and/or comment to the creator asking them about the lightstrip thing. He does seem to dig hoarding flashlights though!

ChucklesTheBeard commented 2 years ago

A link to the VOD with a timestamp to skip ahead to when the bug is encountered is in the original report, under "Screenshots".

I copied the version from the main menu at the start of the stream.

LeahLuong commented 2 years ago

@Maleclypse Not sure "Vehicles" is the right tag here. OP confirms their own bug report but says they wrote the report based on seeing a Twitch stream. I guess that counts??

Maleclypse commented 2 years ago

@Maleclypse Not sure "Vehicles" is the right tag here. OP confirms their own bug report but says they wrote the report based on seeing a Twitch stream. I guess that counts??

I thought lightstrips were vehicle parts? If not happy to change the label.

stale[bot] commented 2 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. Please do not \'bump\' or comment on this issue unless you are actively working on it. Stale issues, and stale issues that are closed are still considered.

x-qq commented 2 years ago

This issue still very much exists.

Hirmuolio commented 2 years ago

Seems like the pocket data is on the wrong item. Only the inactive variant has pocket data so activating it makes the pocket go away and probably breaks things.

Probably best to use copy-from from one to the other.