1
0
Fork 0

Removed some unneeded BroadcastWholeWindow()s

This commit is contained in:
Tiger Wang 2014-02-12 22:06:13 +00:00
parent f97ce30151
commit e915a0df4c
4 changed files with 2 additions and 23 deletions

View File

@ -170,18 +170,3 @@ void cChestEntity::OpenNewWindow(void)
void cChestEntity::OnSlotChanged(cItemGrid * a_Grid, int a_SlotNum)
{
super::OnSlotChanged(a_Grid, a_SlotNum);
cWindow * Window = GetWindow();
if (Window != NULL)
{
Window->BroadcastWholeWindow();
}
}

View File

@ -47,7 +47,6 @@ public:
virtual void SaveToJson(Json::Value & a_Value) override;
virtual void SendTo(cClientHandle & a_Client) override;
virtual void UsedBy(cPlayer * a_Player) override;
virtual void OnSlotChanged(cItemGrid * a_Grid, int a_SlotNum) override;
/// Opens a new chest window for this chest. Scans for neighbors to open a double chest window, if appropriate.
void OpenNewWindow(void);

View File

@ -99,13 +99,6 @@ void cDropSpenserEntity::DropSpense(cChunk & a_Chunk)
}
m_World->BroadcastSoundParticleEffect(2000, m_PosX, m_PosY, m_PosZ, SmokeDir);
m_World->BroadcastSoundEffect("random.click", m_PosX * 8, m_PosY * 8, m_PosZ * 8, 1.0f, 1.0f);
// Update the UI window, if open:
cWindow * Window = GetWindow();
if (Window != NULL)
{
Window->BroadcastWholeWindow();
}
}

View File

@ -56,6 +56,8 @@ public:
virtual void UsedBy(cPlayer * a_Player) override;
virtual void SendTo(cClientHandle & a_Client) override;
static const char * GetClassStatic(void) { return "cSignrEntity"; }
private: