Cataclysm-dda: Cannot install batteries into vehicles (git bisected)

Created on 18 Feb 2020  路  3Comments  路  Source: CleverRaven/Cataclysm-DDA

Describe the bug

Attempting to install car batteries and storage batteries (possibly others) shows the battery as missing on the vehicle screen, even though it's in the same tile as the character.

Responsible commit

With the magic of git bisect, 3ef0d466ca90e25cc6c25eacd4ffcc07a6c9042e is identified as the commit that introduces this bug. Any build before that commit will let batteries be installed fine, any build after does not.

Steps To Reproduce

  1. Load the attached save
  2. Attempt to install a storage or car battery in the luxury RV
  3. Observe you can't, even though you're standing on them.

Expected behavior

Batteries can be installed as per normal.

Versions and configuration

Discovered on 2f4a7498d1b8c86ab3296cc6dabb6b9ffe0f0db8, but introduced in 3ef0d466ca90e25cc6c25eacd4ffcc07a6c9042e.

Files

<Bug> Vehicles

Most helpful comment

So I'm not sure about my ammotype changes, so when I get home tonight I will see about undoing those. Lines 7275, 7351 and 7748. They relate to batteries and I saw some other weirdness with one elsewhere so I figure that's a good chance of fixing it.

All 3 comments

This is part of @Ramza13 's amazing work in cleaning up constants, and I have no idea why it's impacting battery installation for vehicles.

So I'm not sure about my ammotype changes, so when I get home tonight I will see about undoing those. Lines 7275, 7351 and 7748. They relate to batteries and I saw some other weirdness with one elsewhere so I figure that's a good chance of fixing it.

If it helps at all, I have had the same issue and found that fabricating a fresh new battery allows it to be reinstalled. However, after removing the said fresh battery from the vehicle, it cannot be reinstalled again.

Was this page helpful?
0 / 5 - 0 ratings