diff options
author | Warr1024 <warr1024@gmail.com> | 2021-07-09 09:08:40 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-09 09:08:40 -0400 |
commit | 52128ae11e8b1a7ce66a87c53f1b15f3aabe69f4 (patch) | |
tree | dff52505d4b86b9934cc6f37f9b4ceeca5a54014 /src/map.cpp | |
parent | e9bc59e376f88f1d4d1c6d3fedf62d9049e3e60d (diff) | |
download | minetest-52128ae11e8b1a7ce66a87c53f1b15f3aabe69f4.tar.gz minetest-52128ae11e8b1a7ce66a87c53f1b15f3aabe69f4.tar.bz2 minetest-52128ae11e8b1a7ce66a87c53f1b15f3aabe69f4.zip |
Add API for mods to hook liquid transformation events (#11405)
Add API for mods to hook liquid transformation events
Without this API, there is no reliable way for mods to be
notified when liquid transform modifies nodes and mods are
forced to poll for changes. This allows mods to detect
changes to flowing liquid nodes and liquid renewal using
event-driven logic.
Diffstat (limited to 'src/map.cpp')
-rw-r--r-- | src/map.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/map.cpp b/src/map.cpp index 641287c3d..30ce064d6 100644 --- a/src/map.cpp +++ b/src/map.cpp @@ -829,7 +829,7 @@ void Map::transformLiquids(std::map<v3s16, MapBlock*> &modified_blocks, m_transforming_liquid.push_back(iter); voxalgo::update_lighting_nodes(this, changed_nodes, modified_blocks); - + env->getScriptIface()->on_liquid_transformed(changed_nodes); /* ---------------------------------------------------------------------- * Manage the queue so that it does not grow indefinately |