CleverRaven / Cataclysm-DDA

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

Solar Suitcase Bug #73796

Open Brroleg opened 1 month ago

Brroleg commented 1 month ago

Describe the bug

Undeploying deployed solar suitcase creates "deployed solar suitcase" copy

Attach save file

N/A

Steps to reproduce

  1. Get solar suitcase and deploy it
  2. Undeploy it
  3. There will be 2 objects on the ground - your packed solar suitcase and another object "deployed solar suitcase"

Expected behavior

Solar suitcase should not leave deployed copy of itself on the ground after undeploying

Screenshots

1057243

Versions and configuration

Experimental build 2024-05-15-0120

Additional context

No response

XtraButtery commented 1 month ago

I seem to be able to reproduce, probably related to this error I get when deploying a solar suitcase image Notably this didn't affect taking down an old solar suitcase that I had deployed several updates ago, until I re-deployed it (getting this error)

TheMurderUnicorn commented 1 month ago

So I did a little testing on this. When you remove the panel it's supposed to ignore the "item" line of the appliance entry and give you the "removes_as" line instead. However, it's giving both for some reason. I don't know why this is or how to fix it. That's why one of the removed panels is a 1/1 charged item, it's the battery magazine that's not supposed to ever appear in game. image This is also occurring for the smaller solar panel deployable, though it didn't kick me an error. These are the only two things in the game I found that use remove_as, so I can't test how broken it is.

Looking at the set base item error, I see the error output, and it appears to be because these are in fact different base items due to the remove_as field, but I have no idea what to do about any of this or if I'm even right in understanding it, I'm shit at reading code.