[MIRROR] Fixes beakers disappearing when switching in chem heater [MDB IGNORE] (#23229)

* Fixes beakers disappearing when switching in chem heater (#77770)

## About The Pull Request
Fixes #77762

The function to replace beakers in the Chem Heater unregistered the
signal from the beaker after removing it, causing it to break and the
beaker to disappear. This fixes that by unregistering the signal first.
## Why It's Good For The Game
Beakers don't disappear when you try to swap them in the Chem Heater
anymore.
## Changelog
🆑
fix: fixed beakers disappearing when swapped in a chem heater
/🆑

* Fixes beakers disappearing when switching in chem heater

---------

Co-authored-by: Ical <86125936+Ical92@users.noreply.github.com>
This commit is contained in:
SkyratBot
2023-08-20 22:01:08 -04:00
committed by GitHub
co-authored by Ical
parent 16e86d7962
commit 3e2e59d862
@@ -78,8 +78,8 @@
if(!user)
return FALSE
if(beaker)
try_put_in_hand(beaker, user)
UnregisterSignal(beaker.reagents, COMSIG_REAGENTS_REACTION_STEP)
try_put_in_hand(beaker, user)
beaker = null
if(new_beaker)
beaker = new_beaker