1
0

Added LOGREPLACELINE for line replacement

This commit is contained in:
Tiger Wang
2014-01-29 19:22:03 +00:00
parent ed7816419d
commit 7d03876a3e
5 changed files with 94 additions and 16 deletions

View File

@@ -100,13 +100,13 @@ protected:
{
for (;;)
{
LOG("%d chunks to load, %d chunks to generate",
LOGREPLACELINE("%d chunks to load, %d chunks to generate",
m_World->GetStorage().GetLoadQueueLength(),
m_World->GetGenerator().GetQueueLength()
);
// Wait for 2 sec, but be "reasonably wakeable" when the thread is to finish
for (int i = 0; i < 20; i++)
// Wait for 0.5 sec, but be "reasonably wakeable" when the thread is to finish
for (int i = 0; i < 5; i++)
{
cSleep::MilliSleep(100);
if (m_ShouldTerminate)
@@ -152,10 +152,10 @@ protected:
{
for (;;)
{
LOG("%d chunks remaining to light", m_Lighting->GetQueueLength()
LOGREPLACELINE("%d chunks remaining to light", m_Lighting->GetQueueLength()
);
// Wait for 2 sec, but be "reasonably wakeable" when the thread is to finish
// Wait for 0.5 sec, but be "reasonably wakeable" when the thread is to finish
for (int i = 0; i < 20; i++)
{
cSleep::MilliSleep(100);