Only set player dirty flag if values change

This commit is contained in:
ShadowNinja 2014-08-28 20:22:19 -04:00
parent cd0df0d5e7
commit 8b3135a643

@ -142,18 +142,21 @@ public:
virtual void setPosition(const v3f &position)
{
if (position != m_position)
m_dirty = true;
m_position = position;
}
void setPitch(f32 pitch)
{
if (pitch != m_pitch)
m_dirty = true;
m_pitch = pitch;
}
virtual void setYaw(f32 yaw)
{
if (yaw != m_yaw)
m_dirty = true;
m_yaw = yaw;
}
@ -175,6 +178,7 @@ public:
virtual void setBreath(u16 breath)
{
if (breath != m_breath)
m_dirty = true;
m_breath = breath;
}