Fixed initial player head rotation when a player is being spawned on another client
Fixed showing correct item in the player hand when spawned on another client (it didn't include metadata/health before) Fixed player head rotation when moving and looking around at the same time git-svn-id: http://mc-server.googlecode.com/svn/trunk@914 0a769ca7-a7f5-676a-18bf-c427514a06d6
This commit is contained in:
parent
789be67922
commit
1d8921c151
@ -151,9 +151,11 @@ void cPlayer::SpawnOn(cClientHandle & a_Client)
|
|||||||
);
|
);
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if (m_bVisible)
|
if (m_bVisible && (m_ClientHandle != (&a_Client)))
|
||||||
{
|
{
|
||||||
a_Client.SendPlayerSpawn(*this);
|
a_Client.SendPlayerSpawn(*this);
|
||||||
|
a_Client.SendEntHeadLook(*this);
|
||||||
|
a_Client.SendEntityEquipment(*this, 0, m_Inventory.GetEquippedItem() );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -200,6 +202,7 @@ void cPlayer::Tick(float a_Dt)
|
|||||||
if (m_bDirtyOrientation)
|
if (m_bDirtyOrientation)
|
||||||
{
|
{
|
||||||
m_World->BroadcastEntRelMoveLook(*this, (char)(DiffX * 32), (char)(DiffY * 32), (char)(DiffZ * 32), m_ClientHandle);
|
m_World->BroadcastEntRelMoveLook(*this, (char)(DiffX * 32), (char)(DiffY * 32), (char)(DiffZ * 32), m_ClientHandle);
|
||||||
|
m_World->BroadcastEntHeadLook(*this, m_ClientHandle);
|
||||||
m_bDirtyOrientation = false;
|
m_bDirtyOrientation = false;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user