aboutsummaryrefslogtreecommitdiff
path: root/src/client/client.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/client.cpp')
-rw-r--r--src/client/client.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/client.cpp b/src/client/client.cpp
index 61888b913..ef4a3cdfc 100644
--- a/src/client/client.cpp
+++ b/src/client/client.cpp
@@ -1196,7 +1196,7 @@ void Client::sendChatMessage(const std::wstring &message)
if (canSendChatMessage()) {
u32 now = time(NULL);
float time_passed = now - m_last_chat_message_sent;
- m_last_chat_message_sent = time(NULL);
+ m_last_chat_message_sent = now;
m_chat_message_allowance += time_passed * (CLIENT_CHAT_MESSAGE_LIMIT_PER_10S / 8.0f);
if (m_chat_message_allowance > CLIENT_CHAT_MESSAGE_LIMIT_PER_10S)
@@ -1832,7 +1832,7 @@ void Client::makeScreenshot()
sstr << "Failed to save screenshot '" << filename << "'";
}
pushToChatQueue(new ChatMessage(CHATMESSAGE_TYPE_SYSTEM,
- narrow_to_wide(sstr.str())));
+ utf8_to_wide(sstr.str())));
infostream << sstr.str() << std::endl;
image->drop();
}