]> git.xonotic.org Git - xonotic/xonotic.git/blobdiff - server/rcon2irc/joinsparts.pl
allow showing status number on irc
[xonotic/xonotic.git] / server / rcon2irc / joinsparts.pl
index 72bd544ce9236124ccb242763798b9d7db70a9f3..686244fb23bd5ac5571e54762eef95bfaeefb683 100644 (file)
@@ -1,4 +1,4 @@
-# Nexuiz rcon2irc plugin by Merlijn Hofstra licensed under GPL - joinsparts.pl
+# Xonotic rcon2irc plugin by Merlijn Hofstra licensed under GPL - joinsparts.pl
 # Place this file inside the same directory as rcon2irc.pl and add the full filename to the plugins.
 # Don't forget to edit the options below to suit your needs.
 
@@ -6,6 +6,7 @@
        irc_announce_joins => 1,
        irc_announce_parts => 1,
        irc_show_playerip => 0,
+       irc_show_statusnumber => 0,
        irc_show_mapname => 0,
        irc_show_amount_of_players => 0,
        irc_show_country => 0,
@@ -59,6 +60,7 @@ sub get_player_count
        if ($pj->{irc_announce_joins} && !$store{"playerid_byslot_$slot"}) {
                out irc => 0, "PRIVMSG $config{irc_channel} :\00309+ join\017: $nick\017" . 
                        ($pj->{irc_show_playerip} ? " (\00304$ip\017)" : '') .
+                       ($pj->{irc_show_statusnumber} ? " #\00304$slot\017 " : '') .
                        ($pj->{irc_show_country} && $cn ? " CN: \00304$cn\017" : '') .
                        ($clonenicks ? " Clone of:$clonenicks" : '') .
                        ($pj->{irc_show_mapname} ? " playing on \00304$store{map}\017" : '') .