mirror of
https://github.com/moparisthebest/minetest
synced 2024-11-15 13:55:11 -05:00
Dont teleport back if holding sneak when detaching/turn freemove off
This commit is contained in:
parent
cc92e45b78
commit
bc66f46323
@ -73,6 +73,7 @@ void LocalPlayer::move(f32 dtime, ClientEnvironment *env, f32 pos_max_d,
|
|||||||
if(isAttached)
|
if(isAttached)
|
||||||
{
|
{
|
||||||
setPosition(overridePosition);
|
setPosition(overridePosition);
|
||||||
|
m_sneak_node_exists = false;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -85,6 +86,7 @@ void LocalPlayer::move(f32 dtime, ClientEnvironment *env, f32 pos_max_d,
|
|||||||
{
|
{
|
||||||
position += m_speed * dtime;
|
position += m_speed * dtime;
|
||||||
setPosition(position);
|
setPosition(position);
|
||||||
|
m_sneak_node_exists = false;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user