mirror of
https://github.com/minetest/minetest.git
synced 2024-12-24 15:12:23 +01:00
Fix automatic rotate for attached entities (#12392)
This commit is contained in:
parent
7b6c4bf2e0
commit
d400a98ef0
@ -1197,7 +1197,7 @@ void GenericCAO::step(float dtime, ClientEnvironment *env)
|
||||
}
|
||||
}
|
||||
|
||||
if (!getParent() && node && fabs(m_prop.automatic_rotate) > 0.001f) {
|
||||
if (node && fabs(m_prop.automatic_rotate) > 0.001f) {
|
||||
// This is the child node's rotation. It is only used for automatic_rotate.
|
||||
v3f local_rot = node->getRotation();
|
||||
local_rot.Y = modulo360f(local_rot.Y - dtime * core::RADTODEG *
|
||||
|
Loading…
Reference in New Issue
Block a user