Skip to content

Commit 23858fd

Browse files
committed
Fix fluid caravan interrupt migrations
Not all fluid conditions include the word "fluid"! Resolves pyanodon/pybugreports#1439
1 parent 2ab18b1 commit 23858fd

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

changelog.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
---------------------------------------------------------------------------------------------------
2+
Version: 3.0.64
3+
Date: ???
4+
Changes:
5+
- Fixed failure migrating certain fluid caravan interrupts
6+
---------------------------------------------------------------------------------------------------
27
Version: 3.0.63
38
Date: 2026-03-28
49
Changes:

scripts/caravan/caravan-prototypes.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,7 @@ py.on_event(py.events.on_init(), function(changes)
473473
for _, condition in pairs(interrupt_data.conditions or {}) do
474474
local elem_value = condition.elem_value
475475
if elem_value ~= nil then
476-
local elem_type = condition.type:find("fluid") and "fluid" or "item"
476+
local elem_type = (condition.type:find("fluid") or condition.type:find("tank")) and "fluid" or "item"
477477
condition.elem_value = migrate_proto(elem_value, elem_type, migrations)
478478
if condition.elem_value == nil then
479479
error_caravan(interrupt_name, elem_value, elem_type)

0 commit comments

Comments
 (0)