From 362e49c0bc9c0c5cde28e1e9ff3a0ae427e27dd8 Mon Sep 17 00:00:00 2001 From: Nilsolm Date: Sun, 12 Apr 2020 11:02:26 +0200 Subject: [PATCH 1/2] autogems: check bin content in linked stockpiles --- plugins/autogems.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/plugins/autogems.cpp b/plugins/autogems.cpp index 4121b562f..f22d20d30 100644 --- a/plugins/autogems.cpp +++ b/plugins/autogems.cpp @@ -167,6 +167,16 @@ void create_jobs() { stockpiled.insert(item->id); piled[item->getMaterialIndex()] += 1; } + else if (item->flags.bits.container) { + std::vector binneditems; + Items::getContainedItems(item, &binneditems); + for (df::item *it : binneditems) { + if (valid_gem(it)) { + stockpiled.insert(it->id); + piled[it->getMaterialIndex()] += 1; + } + } + } } // Decrement current jobs from all linked workshops, not just this one. From f7630a52707b9d8e5e4d0ae82ed98244c71a7b8b Mon Sep 17 00:00:00 2001 From: Nilsolm Date: Sun, 12 Apr 2020 11:03:28 +0200 Subject: [PATCH 2/2] update changelog --- docs/changelog.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/changelog.txt b/docs/changelog.txt index d2404c951..ba75f09fb 100644 --- a/docs/changelog.txt +++ b/docs/changelog.txt @@ -40,6 +40,7 @@ changelog.txt uses a syntax similar to RST, with a few special sequences: # Future ## Fixes +- `autogems`: fixed an issue with binned gems being ignored in linked stockpiles - `tweak` embark-profile-name: fixed handling of the native shift+space key ## Misc Improvements