mirror of
https://github.com/mt-mods/unifieddyes.git
synced 2024-12-25 02:00:27 +01:00
Replace deprecated call to 'get_look_yaw' with 'get_look_horizontal'
This commit is contained in:
parent
df177c26a7
commit
df3f1b18ab
4
init.lua
4
init.lua
@ -207,7 +207,7 @@ end)
|
|||||||
|
|
||||||
function unifieddyes.fix_rotation(pos, placer, itemstack, pointed_thing)
|
function unifieddyes.fix_rotation(pos, placer, itemstack, pointed_thing)
|
||||||
local node = minetest.get_node(pos)
|
local node = minetest.get_node(pos)
|
||||||
local yaw = placer:get_look_yaw()
|
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 pitch = placer:get_look_vertical()
|
||||||
|
|
||||||
@ -226,7 +226,7 @@ end
|
|||||||
|
|
||||||
function unifieddyes.fix_rotation_nsew(pos, placer, itemstack, pointed_thing)
|
function unifieddyes.fix_rotation_nsew(pos, placer, itemstack, pointed_thing)
|
||||||
local node = minetest.get_node(pos)
|
local node = minetest.get_node(pos)
|
||||||
local yaw = placer:get_look_yaw()
|
local yaw = placer:get_look_horizontal()
|
||||||
local dir = minetest.yaw_to_dir(yaw)
|
local dir = minetest.yaw_to_dir(yaw)
|
||||||
local fdir = minetest.dir_to_wallmounted(dir)
|
local fdir = minetest.dir_to_wallmounted(dir)
|
||||||
minetest.swap_node(pos, { name = node.name, param2 = fdir })
|
minetest.swap_node(pos, { name = node.name, param2 = fdir })
|
||||||
|
Loading…
Reference in New Issue
Block a user