Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Fix crash when using the screwdriver on an unknown node
- Loading branch information
Showing
with
1 addition
and
2 deletions.
-
+1
−2
mods/screwdriver/init.lua
|
@@ -71,9 +71,8 @@ local function screwdriver_handler(itemstack, user, pointed_thing) |
|
|
return |
|
|
end |
|
|
local node = minetest.get_node(pos) |
|
|
local node_name = node.name |
|
|
local ndef = minetest.registered_nodes[node.name] |
|
|
if ndef.paramtype2 == "facedir" then |
|
|
if ndef and ndef.paramtype2 == "facedir" then |
|
|
if ndef.drawtype == "nodebox" and ndef.node_box.type ~= "fixed" then |
|
|
return |
|
|
end |
|
|