diff options
-rw-r--r-- | technic/textures/technic_paint.png | bin | 182 -> 174 bytes | |||
-rw-r--r-- | technic/tools/spray_painter.lua | 13 |
2 files changed, 7 insertions, 6 deletions
diff --git a/technic/textures/technic_paint.png b/technic/textures/technic_paint.png Binary files differindex b052757..4210991 100644 --- a/technic/textures/technic_paint.png +++ b/technic/textures/technic_paint.png diff --git a/technic/tools/spray_painter.lua b/technic/tools/spray_painter.lua index cea42b4..41b8a6a 100644 --- a/technic/tools/spray_painter.lua +++ b/technic/tools/spray_painter.lua @@ -28,9 +28,9 @@ minetest.register_node ("technic:paint_layer", { tiles = {"technic_paint.png"}, node_box = { type = "wallmounted", - wall_bottom = {-0.5, -0.5, -0.5, 0.5, -0.499, 0.5}, - wall_top = {-0.5, 0.499, -0.5, 0.5, 0.5, 0.5}, - wall_side = {-0.5, -0.5, -0.5, -0.499, 0.5, 0.5}, + wall_bottom = {-0.5, -0.5, -0.5, 0.5, -0.49, 0.5}, + wall_top = {-0.5, 0.49, -0.5, 0.5, 0.5, 0.5}, + wall_side = {-0.5, -0.5, -0.5, -0.49, 0.5, 0.5}, }, drop = "", groups = {attached_node = 1, dig_immediate = 2, not_in_creative_inventory = 1}, @@ -90,9 +90,10 @@ local function spray_paint(itemstack, user, pointed_thing) }) -- player needs to own both the wall and its surface - if minetest.is_protected(pointed_thing.under, user:get_player_name()) or - minetest.is_protected(pointed_thing.above, user:get_player_name()) then - minetest.record_protection_violation(pointed_thing.under, name) + local pname = user:get_player_name() + if minetest.is_protected(pointed_thing.under, pname) or + minetest.is_protected(pointed_thing.above, pname) then + minetest.record_protection_violation(pointed_thing.under, pname) return itemstack end |