1
0
mirror of https://github.com/Sokomine/locks.git synced 2025-07-14 20:20:14 +02:00

4 Commits

2 changed files with 5 additions and 4 deletions

View File

@ -801,3 +801,5 @@ dofile(minetest.get_modpath("locks").."/shared_locked_chest.lua");
dofile(minetest.get_modpath("locks").."/shared_locked_sign_wall.lua"); dofile(minetest.get_modpath("locks").."/shared_locked_sign_wall.lua");
dofile(minetest.get_modpath("locks").."/shared_locked_xdoors2.lua"); dofile(minetest.get_modpath("locks").."/shared_locked_xdoors2.lua");
dofile(minetest.get_modpath("locks").."/shared_locked_furnace.lua"); dofile(minetest.get_modpath("locks").."/shared_locked_furnace.lua");
minetest.log("action", "[locks] loaded.")

View File

@ -138,7 +138,7 @@ minetest.register_node("locks:door", {
description = "Shared locked Wooden Door", description = "Shared locked Wooden Door",
node_placement_prediction = "", node_placement_prediction = "",
inventory_image = 'locks_xdoors2_door.png', inventory_image = 'locks_xdoors2_door.png',
wield_image = 'xdoors2_door.png', wield_image = 'locks_xdoors2_door.png',
stack_max = 1, stack_max = 1,
sunlight_propogates = true, sunlight_propogates = true,
on_place = function(itemstack, placer, pointed_thing) on_place = function(itemstack, placer, pointed_thing)
@ -157,12 +157,11 @@ minetest.register_node("locks:door", {
local fdir = 0 local fdir = 0
local placer_pos = placer:get_pos() local placer_pos = placer:get_pos()
if placer_pos then if placer_pos then
dir = { fdir = minetest.dir_to_facedir({
x = above.x - placer_pos.x, x = above.x - placer_pos.x,
y = above.y - placer_pos.y, y = above.y - placer_pos.y,
z = above.z - placer_pos.z z = above.z - placer_pos.z
} })
fdir = minetest.dir_to_facedir(dir)
end end
local t = 1 local t = 1