Merge pull request #19 from Billy-S/master

Added protection check for steel signs as well
This commit is contained in:
Elkien3 2018-09-07 22:30:46 -05:00 committed by GitHub
commit 309cdf7aeb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -96,6 +96,13 @@ minetest.register_node(":default:sign_wall_steel", {
on_place = function(itemstack, placer, pointed_thing) on_place = function(itemstack, placer, pointed_thing)
local above = pointed_thing.above local above = pointed_thing.above
local under = pointed_thing.under local under = pointed_thing.under
pname = placer:get_player_name()
if minetest.is_protected(above, pname) then
minetest.record_protection_violation(above, pname)
return itemstack
end
local dir = {x = under.x - above.x, local dir = {x = under.x - above.x,
y = under.y - above.y, y = under.y - above.y,
z = under.z - above.z} z = under.z - above.z}