]> jfr.im git - irc/evilnet/x3.git/commitdiff
If we have 0.5.0 specific features then use this conf option in the code
authorsirvulcan <redacted>
Sun, 21 May 2006 05:58:32 +0000 (05:58 +0000)
committersirvulcan <redacted>
Sun, 21 May 2006 05:58:32 +0000 (05:58 +0000)
src/proto-p10.c
x3.conf.example

index c75ae806b878244b66e6809d99d817cd10f5375f..a9731da75b8d1b302f2236b525c8a2afcaee514d 100644 (file)
@@ -903,13 +903,18 @@ irc_part(struct userNode *who, struct chanNode *what, const char *reason)
 void
 irc_topic(struct userNode *service, struct userNode *who, struct chanNode *what, const char *topic)
 {
-/* UNCOMMENT FOR NEFARIOUS 0.5.0 TOPIC SUPPORT
- *    putsock("%s " P10_TOPIC " %s %s " FMT_TIME_T " " FMT_TIME_T " :%s", service->numeric, what->name, who->nick, what->timestamp, now, topic);
- * UNCOMMENT FOR NEFARIOUS 0.5.0 TOPIC SUPPORT */
 
-    who = service; /* REMOVE LINE FOR NEFARIOUS 0.5.0 */
-
-    putsock("%s " P10_TOPIC " %s :%s", who->numeric, what->name, topic);
+   int type = 4;
+   const char *str;
+   str = conf_get_data("server/type", RECDB_QSTRING);
+   type = atoi(str);
+
+   if (type == 5) {
+     putsock("%s " P10_TOPIC " %s %s " FMT_TIME_T " " FMT_TIME_T " :%s", service->numeric, what->name, who->nick, what->timestamp, now, topic);
+   } else {
+     who = service; /* REMOVE LINE FOR NEFARIOUS 0.5.0 */
+     putsock("%s " P10_TOPIC " %s :%s", who->numeric, what->name, topic);
+   }
 }
 
 void
index 13948a869b93b5dbd2caac0fbf380d33992aaa93..7c10a99bd53a749403ceb2c4c0192d4ed3066089 100644 (file)
@@ -48,6 +48,7 @@
      * x3 does not set the host suffix for users, but must know it when making
      * things like bans, where it should not show the user's real hostname. */
     "numeric" "51"; // hint: If you get collisions on link, CHANGE THIS.
+    "type" "4" // Only change this to 5 if you are using Nefarious 0.5.0 off SVN
     "max_users" "256"; // You can save a little memory by setting this to a lower value.
     "force_n2k" "1"; // Use extended (5-digit) numnick for self, even if 3 are possible.
     "ping_freq" "60";