diff --git a/enchanting.lua b/enchanting.lua index 2eb5880..362c6b9 100644 --- a/enchanting.lua +++ b/enchanting.lua @@ -150,7 +150,7 @@ function enchanting.timer(pos) acceleration = {x=0, y=-2.2, z=0}, expirationtime = 1, size = 2, - texture = "xdecor_glyph"..math.random(1,14)..".png" + texture = "xdecor_glyph"..math.random(1,18)..".png" }) end return true diff --git a/handlers/registration.lua b/handlers/registration.lua index 9c136c2..6b7ab1f 100644 --- a/handlers/registration.lua +++ b/handlers/registration.lua @@ -1,10 +1,3 @@ ---[[ local default_can_dig = function(pos, _) - local meta = minetest.get_meta(pos) - local inv = meta:get_inventory() - - return inv:is_empty("main") -end --]] - xbg = default.gui_bg..default.gui_bg_img..default.gui_slots local default_inventory_size = 32 @@ -44,24 +37,9 @@ local function get_formspec_by_size(size) return formspec or default_inventory_formspecs end -local function drop_stuff() - return function(pos, oldnode, oldmetadata, digger) - local meta = minetest.get_meta(pos) - meta:from_table(oldmetadata) - local inv = meta:get_inventory() - - for i=1, inv:get_size("main") do - local stack = inv:get_stack("main", i) - if not stack:is_empty() then - local p = { - x = pos.x + math.random(0,5) / 5 - 0.5, - y = pos.y, - z = pos.z + math.random(0,5) / 5 - 0.5 - } - minetest.add_item(p, stack) - end - end - end +local default_can_dig = function(pos) + local inv = minetest.get_meta(pos):get_inventory() + return inv:is_empty("main") end function xdecor.register(name, def) @@ -94,8 +72,7 @@ function xdecor.register(name, def) inv:set_size("main", size) meta:set_string("formspec", (inventory.formspec or get_formspec_by_size(size))..xbg) end - def.after_dig_node = def.after_dig_node or drop_stuff() - --def.can_dig = def.can_dig or default_can_dig + def.can_dig = def.can_dig or default_can_dig elseif infotext and not def.on_construct then def.on_construct = function(pos) local meta = minetest.get_meta(pos) diff --git a/textures/xdecor_glyph1.png b/textures/xdecor_glyph1.png index da77892..a5ac3f5 100644 Binary files a/textures/xdecor_glyph1.png and b/textures/xdecor_glyph1.png differ diff --git a/textures/xdecor_glyph10.png b/textures/xdecor_glyph10.png index 27c7c8d..d002147 100644 Binary files a/textures/xdecor_glyph10.png and b/textures/xdecor_glyph10.png differ diff --git a/textures/xdecor_glyph11.png b/textures/xdecor_glyph11.png index 76493c9..c9cd9ff 100644 Binary files a/textures/xdecor_glyph11.png and b/textures/xdecor_glyph11.png differ diff --git a/textures/xdecor_glyph12.png b/textures/xdecor_glyph12.png index 72f18fb..dc5dd1d 100644 Binary files a/textures/xdecor_glyph12.png and b/textures/xdecor_glyph12.png differ diff --git a/textures/xdecor_glyph13.png b/textures/xdecor_glyph13.png index 70ca494..45c6d5a 100644 Binary files a/textures/xdecor_glyph13.png and b/textures/xdecor_glyph13.png differ diff --git a/textures/xdecor_glyph15.png b/textures/xdecor_glyph15.png new file mode 100644 index 0000000..0db3a9e Binary files /dev/null and b/textures/xdecor_glyph15.png differ diff --git a/textures/xdecor_glyph16.png b/textures/xdecor_glyph16.png new file mode 100644 index 0000000..d10a72b Binary files /dev/null and b/textures/xdecor_glyph16.png differ diff --git a/textures/xdecor_glyph17.png b/textures/xdecor_glyph17.png new file mode 100644 index 0000000..2b374e8 Binary files /dev/null and b/textures/xdecor_glyph17.png differ diff --git a/textures/xdecor_glyph18.png b/textures/xdecor_glyph18.png new file mode 100644 index 0000000..e762e35 Binary files /dev/null and b/textures/xdecor_glyph18.png differ diff --git a/textures/xdecor_glyph2.png b/textures/xdecor_glyph2.png index a6da2d1..eb1e74f 100644 Binary files a/textures/xdecor_glyph2.png and b/textures/xdecor_glyph2.png differ diff --git a/textures/xdecor_glyph3.png b/textures/xdecor_glyph3.png index 456e030..e82145e 100644 Binary files a/textures/xdecor_glyph3.png and b/textures/xdecor_glyph3.png differ diff --git a/textures/xdecor_glyph5.png b/textures/xdecor_glyph5.png index c79537f..f0635bf 100644 Binary files a/textures/xdecor_glyph5.png and b/textures/xdecor_glyph5.png differ diff --git a/textures/xdecor_glyph6.png b/textures/xdecor_glyph6.png index f735354..c93976c 100644 Binary files a/textures/xdecor_glyph6.png and b/textures/xdecor_glyph6.png differ diff --git a/textures/xdecor_glyph7.png b/textures/xdecor_glyph7.png index 3f91a32..1e4ff02 100644 Binary files a/textures/xdecor_glyph7.png and b/textures/xdecor_glyph7.png differ diff --git a/textures/xdecor_glyph8.png b/textures/xdecor_glyph8.png index 6c65994..2f2b86c 100644 Binary files a/textures/xdecor_glyph8.png and b/textures/xdecor_glyph8.png differ