[MIRROR] Fixes an issue with un-hidden (alien, syndie etc.) nodes not being researchable. [MDB IGNORE] (#25122)

* Fixes an issue with un-hidden (alien, syndie etc.) nodes not being researchable. (#79763)

## About The Pull Request
Recently, I've been trying to unlock the ayy node, but couldn't even
after disassembling an alien tool. Looked into the variables viewer and
saw the node id wasn't set in the `available_nodes` list. It seems there
was no update after it being unhidden.

## Why It's Good For The Game
Fixing an issue with the destructive analyzer, maybe from the new UI
refactor, but I couldn't bother to git blame it.

## Changelog

🆑
fix: Fixed an issue with un-hidden (alien, syndie etc.) nodes not being
researchable.
/🆑

* Fixes an issue with un-hidden (alien, syndie etc.) nodes not being researchable.

---------

Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
This commit is contained in:
SkyratBot
2023-11-19 14:36:44 -05:00
committed by GitHub
co-authored by Ghom
parent 68b58cd630
commit 6603dbbdff
2 changed files with 4 additions and 2 deletions
@@ -179,10 +179,10 @@
var/datum/techweb_node/node_to_discover = SSresearch.techweb_node_by_id(id)
if(!istype(node_to_discover))
return FALSE
SSblackbox.record_feedback("nested tally", "item_deconstructed", 1, list("[node_to_discover.id]", "[loaded_item.type]"))
if(!destroy_item())
return FALSE
stored_research.unhide_node(SSresearch.techweb_node_by_id(node_to_discover.id))
SSblackbox.record_feedback("nested tally", "item_deconstructed", 1, list("[node_to_discover.id]", "[loaded_item.type]"))
stored_research.unhide_node(node_to_discover)
return TRUE
#undef DESTRUCTIVE_ANALYZER_DESTROY_POINTS
@@ -409,6 +409,8 @@
if(!istype(node))
return FALSE
hidden_nodes -= node.id
///Make it available if the prereq ids are already researched
update_node_status(node)
return TRUE
/datum/techweb/proc/update_tiers(datum/techweb_node/base)