diff options
author | archshift <admin@archshift.com> | 2014-04-26 23:01:48 +0200 |
---|---|---|
committer | archshift <admin@archshift.com> | 2014-04-26 23:05:00 +0200 |
commit | 7841bad27ad97736ddf21b86e2409f20c6392e69 (patch) | |
tree | 0328313dd23d62d875e2e52cbb92f6d7dfda967a /src | |
parent | Moar alignment. (diff) | |
download | cuberite-7841bad27ad97736ddf21b86e2409f20c6392e69.tar cuberite-7841bad27ad97736ddf21b86e2409f20c6392e69.tar.gz cuberite-7841bad27ad97736ddf21b86e2409f20c6392e69.tar.bz2 cuberite-7841bad27ad97736ddf21b86e2409f20c6392e69.tar.lz cuberite-7841bad27ad97736ddf21b86e2409f20c6392e69.tar.xz cuberite-7841bad27ad97736ddf21b86e2409f20c6392e69.tar.zst cuberite-7841bad27ad97736ddf21b86e2409f20c6392e69.zip |
Diffstat (limited to '')
-rw-r--r-- | src/ClientHandle.cpp | 18 | ||||
-rw-r--r-- | src/Entities/FallingBlock.cpp | 2 | ||||
-rw-r--r-- | src/MCLogger.cpp | 2 |
3 files changed, 11 insertions, 11 deletions
diff --git a/src/ClientHandle.cpp b/src/ClientHandle.cpp index f7147fd2b..fc3f98aaf 100644 --- a/src/ClientHandle.cpp +++ b/src/ClientHandle.cpp @@ -189,7 +189,7 @@ void cClientHandle::GenerateOfflineUUID(void) AString cClientHandle::FormatChatPrefix(bool ShouldAppendChatPrefixes, AString a_ChatPrefixS, AString m_Color1, AString m_Color2) { if (ShouldAppendChatPrefixes) - return Printf("%s%s %s", m_Color1.c_str(), a_ChatPrefixS.c_str(), m_Color2.c_str()); + return Printf("%s[%s] %s", m_Color1.c_str(), a_ChatPrefixS.c_str(), m_Color2.c_str()); else return Printf("%s", m_Color1.c_str()); } @@ -203,14 +203,14 @@ AString cClientHandle::FormatMessageType(bool ShouldAppendChatPrefixes, eMessage switch (a_ChatPrefix) { case mtCustom: return AString(); - case mtFailure: return FormatChatPrefix(ShouldAppendChatPrefixes, "[INFO]", cChatColor::Rose, cChatColor::White); - case mtInformation: return FormatChatPrefix(ShouldAppendChatPrefixes, "[INFO]", cChatColor::Yellow, cChatColor::White); - case mtSuccess: return FormatChatPrefix(ShouldAppendChatPrefixes, "[INFO]", cChatColor::Green, cChatColor::White); - case mtWarning: return FormatChatPrefix(ShouldAppendChatPrefixes, "[WARN]", cChatColor::Rose, cChatColor::White); - case mtFatal: return FormatChatPrefix(ShouldAppendChatPrefixes, "[FATAL]", cChatColor::Red, cChatColor::White); - case mtDeath: return FormatChatPrefix(ShouldAppendChatPrefixes, "[DEATH]", cChatColor::Gray, cChatColor::White); - case mtJoin: return FormatChatPrefix(ShouldAppendChatPrefixes, "[JOIN]", cChatColor::Yellow, cChatColor::White); - case mtLeave: return FormatChatPrefix(ShouldAppendChatPrefixes, "[LEAVE]", cChatColor::Yellow, cChatColor::White); + case mtFailure: return FormatChatPrefix(ShouldAppendChatPrefixes, "INFO", cChatColor::Rose, cChatColor::White); + case mtInformation: return FormatChatPrefix(ShouldAppendChatPrefixes, "INFO", cChatColor::Yellow, cChatColor::White); + case mtSuccess: return FormatChatPrefix(ShouldAppendChatPrefixes, "INFO", cChatColor::Green, cChatColor::White); + case mtWarning: return FormatChatPrefix(ShouldAppendChatPrefixes, "WARN", cChatColor::Rose, cChatColor::White); + case mtFatal: return FormatChatPrefix(ShouldAppendChatPrefixes, "FATAL", cChatColor::Red, cChatColor::White); + case mtDeath: return FormatChatPrefix(ShouldAppendChatPrefixes, "DEATH", cChatColor::Gray, cChatColor::White); + case mtJoin: return FormatChatPrefix(ShouldAppendChatPrefixes, "JOIN", cChatColor::Yellow, cChatColor::White); + case mtLeave: return FormatChatPrefix(ShouldAppendChatPrefixes, "LEAVE", cChatColor::Yellow, cChatColor::White); case mtPrivateMessage: { if (ShouldAppendChatPrefixes) diff --git a/src/Entities/FallingBlock.cpp b/src/Entities/FallingBlock.cpp index 50140de67..bcdac0291 100644 --- a/src/Entities/FallingBlock.cpp +++ b/src/Entities/FallingBlock.cpp @@ -87,7 +87,7 @@ void cFallingBlock::Tick(float a_Dt, cChunk & a_Chunk) AddSpeedY(MilliDt * -9.8f); AddPosition(GetSpeed() * MilliDt); - //If not static (One billionth precision) broadcast movement. + // If not static (One billionth precision) broadcast movement. static const float epsilon = 0.000000001; if ((fabs(GetSpeedX()) > epsilon) || (fabs(GetSpeedZ()) > epsilon)) { diff --git a/src/MCLogger.cpp b/src/MCLogger.cpp index d56c1a5a8..583438d65 100644 --- a/src/MCLogger.cpp +++ b/src/MCLogger.cpp @@ -81,7 +81,7 @@ void cMCLogger::InitLog(const AString & a_FileName) { CONSOLE_SCREEN_BUFFER_INFO sbi; GetConsoleScreenBufferInfo(g_Console, &sbi); - m_DefaultConsoleAttrib = sbi.wAttributes; + g_DefaultConsoleAttrib = sbi.wAttributes; } #elif defined (__linux) && !defined(ANDROID_NDK) m_ShouldColorOutput = isatty(fileno(stdout)); |