<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.multitheftauto.com/wiki/Modules/bIRC/ircGetConnectedChannels?action=history&amp;feed=atom</id>
	<title>Modules/bIRC/ircGetConnectedChannels - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.multitheftauto.com/wiki/Modules/bIRC/ircGetConnectedChannels?action=history&amp;feed=atom"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Modules/bIRC/ircGetConnectedChannels&amp;action=history"/>
	<updated>2026-05-15T12:55:08Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=Modules/bIRC/ircGetConnectedChannels&amp;diff=20929&amp;oldid=prev</id>
		<title>Awwu: Created page with '{{ml_birc}} __NOTOC__ This function can be used to list out all the channels a specified {{ml_birc|ircbot}} has connected to.  ==Syntax==  &lt;syntaxhighlight lang=&quot;lua&quot;&gt; table ircGetConnectedChan…'</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=Modules/bIRC/ircGetConnectedChannels&amp;diff=20929&amp;oldid=prev"/>
		<updated>2009-07-30T10:55:42Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;#039;{{ml_birc}} __NOTOC__ This function can be used to list out all the channels a specified {{ml_birc|ircbot}} has connected to.  ==Syntax==  &amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt; table ircGetConnectedChan…&amp;#039;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{ml_birc}}&lt;br /&gt;
__NOTOC__&lt;br /&gt;
This function can be used to list out all the channels a specified {{ml_birc|ircbot}} has connected to.&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
table ircGetConnectedChannels ( ircbot theBot )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''theBot:''' The ircbot which connected channels you want to get&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns a [[table]] over all connected channels. Returns an empty table if the ircbot isn't connected to any channel.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
This example adds a command ''listchannels'' which can be used to print out all channels where the specified ircbot is connected to the console.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function printOutChannels ( thePlayer, commandName, name )&lt;br /&gt;
    local theBot = ircGetBotByName ( name )&lt;br /&gt;
    if not theBot then&lt;br /&gt;
        outputConsole ( &amp;quot;There's no ircbot called &amp;quot; .. name .. &amp;quot;!&amp;quot;, thePlayer )&lt;br /&gt;
    else&lt;br /&gt;
        local channels = ircGetConnectedChannels ( theBot )&lt;br /&gt;
        outputConsole ( name .. &amp;quot; is on &amp;quot; .. #channels .. &amp;quot; channels:&amp;quot;, thePlayer ) &lt;br /&gt;
        for key, value in ipairs ( channels ) do&lt;br /&gt;
            outputConsole ( &amp;quot;- &amp;quot; .. value, thePlayer )&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
addCommandHandler ( &amp;quot;listchannels&amp;quot;, printOutChannels )&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==See Also==&lt;br /&gt;
{{ml_birc functions}}&lt;/div&gt;</summary>
		<author><name>Awwu</name></author>
	</entry>
</feed>