From: Perttu Ahola Date: Fri, 30 Mar 2012 10:33:59 +0000 (+0300) Subject: Fix walking sound of other players (and other objects) X-Git-Url: http://81.2.79.47:8989/gitweb/?a=commitdiff_plain;h=6b20ea075268863141f8e5e2e7a4f6926e0b3e1f;p=zefram%2Fminetest%2Fminetest_engine.git Fix walking sound of other players (and other objects) --- diff --git a/src/content_cao.cpp b/src/content_cao.cpp index 90e99dc0..03387d03 100644 --- a/src/content_cao.cpp +++ b/src/content_cao.cpp @@ -885,7 +885,8 @@ public: m_step_distance_counter = 0; if(!m_is_local_player && m_prop.makes_footstep_sound){ INodeDefManager *ndef = m_gamedef->ndef(); - v3s16 p = floatToInt(getPosition()+v3f(0,-0.5*BS, 0), BS); + v3s16 p = floatToInt(getPosition() + v3f(0, + (m_prop.collisionbox.MinEdge.Y-0.5)*BS, 0), BS); MapNode n = m_env->getMap().getNodeNoEx(p); SimpleSoundSpec spec = ndef->get(n).sound_footstep; m_gamedef->sound()->playSoundAt(spec, false, getPosition());