summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--init.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/init.lua b/init.lua
index e928737..bac2d6e 100644
--- a/init.lua
+++ b/init.lua
@@ -475,7 +475,7 @@ doc.new_category("nodes", {
---- Sounds
local function is_silent(def, soundtype)
- return def.sounds == nil or def.sounds[soundtype] == nil or def.sounds[soundtype] == "" or (type(data.def.sounds[soundtype]) == "table" and (data.def.sounds[soundtype].name == nil or data.def.sounds[soundtype].name == ""))
+ return type(def.sounds) ~= "table" or def.sounds[soundtype] == nil or def.sounds[soundtype] == "" or (type(data.def.sounds[soundtype]) == "table" and (data.def.sounds[soundtype].name == nil or data.def.sounds[soundtype].name == ""))
end
local silentstep, silentdig, silentplace = false, false, false
if data.def.walkable and is_silent(data.def, "footstep") then