mirror of
https://github.com/mt-mods/unifieddyes.git
synced 2024-11-22 15:33:52 +01:00
rotation fixes for compat with minetest 0.4.16
This commit is contained in:
parent
9dd533f4a0
commit
8b20a069d3
4
init.lua
4
init.lua
@ -208,7 +208,7 @@ end)
|
||||
function unifieddyes.fix_rotation(pos, placer, itemstack, pointed_thing)
|
||||
local node = minetest.get_node(pos)
|
||||
local yaw = placer:get_look_horizontal()
|
||||
local dir = minetest.yaw_to_dir(yaw-1.5)
|
||||
local dir = minetest.yaw_to_dir(yaw) -- -1.5)
|
||||
local pitch = placer:get_look_vertical()
|
||||
|
||||
local fdir = minetest.dir_to_wallmounted(dir)
|
||||
@ -227,7 +227,7 @@ end
|
||||
function unifieddyes.fix_rotation_nsew(pos, placer, itemstack, pointed_thing)
|
||||
local node = minetest.get_node(pos)
|
||||
local yaw = placer:get_look_horizontal()
|
||||
local dir = minetest.yaw_to_dir(yaw)
|
||||
local dir = minetest.yaw_to_dir(yaw+1.5)
|
||||
local fdir = minetest.dir_to_wallmounted(dir)
|
||||
minetest.swap_node(pos, { name = node.name, param2 = fdir })
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user