summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--entities.lua9
-rw-r--r--textures/digtron_no_entry.pngbin0 -> 556 bytes
2 files changed, 9 insertions, 0 deletions
diff --git a/entities.lua b/entities.lua
index fa109b7..5f265a9 100644
--- a/entities.lua
+++ b/entities.lua
@@ -60,6 +60,15 @@ minetest.register_entity("digtron:marker_crate", {
},
on_activate = function(self, staticdata)
+ local pos = self.object:getpos()
+ local node = minetest.get_node(pos)
+ local node_def = minetest.registered_nodes[node.name]
+ if not node_def.buildable_to then
+ local props = self.object:get_properties()
+ props.textures = {"digtron_no_entry.png", "digtron_no_entry.png", "digtron_no_entry.png", "digtron_no_entry.png", "digtron_no_entry.png", "digtron_no_entry.png"}
+ self.object:set_properties(props)
+ end
+
minetest.after(5.0,
function(self)
self.object:remove()
diff --git a/textures/digtron_no_entry.png b/textures/digtron_no_entry.png
new file mode 100644
index 0000000..89c4875
--- /dev/null
+++ b/textures/digtron_no_entry.png
Binary files differ