diff --git a/changelog.txt b/changelog.txt index 4965da0d76..c632f6f75f 100644 --- a/changelog.txt +++ b/changelog.txt @@ -36,6 +36,7 @@ Template for new versions: ## Fixes - `position`: support for adv mode look cursor +- `gui/liquids`: using the remove tool with magma selected will no longer create unexpected unpathable tiles ## Misc Improvements - `hide-tutorials`: handle tutorial popups for adventure mode diff --git a/modtools/spawn-liquid.lua b/modtools/spawn-liquid.lua index 419b0b4595..9a3d2417e8 100644 --- a/modtools/spawn-liquid.lua +++ b/modtools/spawn-liquid.lua @@ -21,6 +21,10 @@ function spawnLiquid(position, liquid_level, liquid_type) local map_block = dfhack.maps.getTileBlock(position) local tile = dfhack.maps.getTileFlags(position) + if liquid_level == 0 then + liquid_type = df.tile_liquid.Water + end + tile.flow_size = liquid_level or 3 tile.liquid_type = liquid_type tile.flow_forbid = liquid_type == df.tile_liquid.Magma or liquid_level >= 4 @@ -34,6 +38,8 @@ function spawnLiquid(position, liquid_level, liquid_type) z_level.update = true z_level.update_twice = true + df.global.world.reindex_pathfinding = true + resetTemperature(position) end