Przeglądaj źródła

Changed help message and count reply message.

Mihawk 12 lat temu
rodzic
commit
0ccb92b16d
2 zmienionych plików z 3 dodań i 4 usunięć
  1. 1 1
      ActiveClient.cpp
  2. 2 3
      Client.cpp

+ 1 - 1
ActiveClient.cpp

@@ -112,7 +112,7 @@ void ActiveClient::run()
   if(!myBroadcastReplyTimer->isActive() && myReplyTimerWasActive)
   {
     myApp->activeClientsReplyCounters(&myUniqueServerCount, &myUniquePlayerCount, this); //add our servers to the list
-    myClient->say("::cims:: Sent to " + QString::number(myUniqueChannelCount) + " channels " + QString::number(myUniqueUserCount) + " unique users and to " + QString::number(myUniqueServerCount) + " servers " + QString::number(myUniquePlayerCount) + " unique players.");
+    myClient->say("Sent to " + QString::number(myUniqueChannelCount) + " channels " + QString::number(myUniqueUserCount) + " unique users and to " + QString::number(myUniqueServerCount) + " servers " + QString::number(myUniquePlayerCount) + " unique players.");
     myUniqueServerCount = myUniquePlayerCount = myUniqueChannelCount = myUniqueUserCount = 0;
   }
   myReplyTimerWasActive = myBroadcastReplyTimer->isActive();

+ 2 - 3
Client.cpp

@@ -57,7 +57,7 @@ void Client::print(const QString &msg)
 {
 	QString str;
 
-  str = QString(host()) + ":" + QString::number(port()) + "> " + msg;
+  str = "[" + QTime::currentTime().toString(Qt::ISODate) + "] " + QString(host()) + ":" + QString::number(port()) + "> " + msg;
 	QByteArray b = str.toAscii();
 	Client::stripColor(b.data());
 	str = QString::fromAscii(b.data());
@@ -164,7 +164,6 @@ void Client::parsePrintedLine()
     say("> Commands:");
     say("> Broadcast a message: .qw <message> and .spam <message>, beware of the floodprot limits 600s for .qw and 300s for .spam");
     say("> Mute/Unmute: .qw_mute and .qw_unmute or .spam_mute or .spam_unmute");
-    say("> .help to show this help message.");
 		return;
 	}
 
@@ -251,7 +250,7 @@ void Client::onPrint(int, const char *msg)
 	{
 		myPrintLine.append(text);
 		parsePrintedLine();
-		print(myPrintLine);
+    print(myPrintLine);
 		myPrintLine.clear();
 	}
 	else