diff --git a/mods/nc_api/compat_soundpos.lua b/mods/nc_api/compat_soundpos.lua new file mode 100644 index 00000000..a93ecf31 --- /dev/null +++ b/mods/nc_api/compat_soundpos.lua @@ -0,0 +1,15 @@ +-- LUALOCALS < --------------------------------------------------------- +local minetest, string + = minetest, string +local string_format + = string.format +-- LUALOCALS > --------------------------------------------------------- + +local oldplay = minetest.sound_play +function minetest.sound_play(spec, params, ...) + if not (params and (params.pos or params.to_player or params.object)) then + minetest.log("warning", string_format("global sound %q params %s", + spec, minetest.serialize(params))) + end + return oldplay(spec, params, ...) +end diff --git a/mods/nc_api/init.lua b/mods/nc_api/init.lua index 266feafb..8fc126f5 100644 --- a/mods/nc_api/init.lua +++ b/mods/nc_api/init.lua @@ -91,6 +91,7 @@ include("compat_issue10127") include("compat_legacyent") include("compat_nodealpha") include("compat_authcache") +include("compat_soundpos") include("util_settings") include("util_privs")