Localize player_vel_yaw

This commit is contained in:
Lizzy Fleckenstein 2021-02-27 15:10:25 +01:00
parent a923b61ac8
commit e5263d854e
1 changed files with 2 additions and 1 deletions

View File

@ -35,8 +35,9 @@ minetest.register_globalstep(function(dtime)
local pitch = degrees(player:get_look_vertical()) * -1
local yaw = degrees(player:get_look_horizontal()) * -1
local player_vel_yaw = 0
if degrees(minetest.dir_to_yaw(player_velocity)) == 0 then
player_vel_yaw = 0
yaw = 0
else
player_vel_yaw = degrees(minetest.dir_to_yaw(player_velocity))