Modules/SebasIRC/ircIsConnected: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 2: Line 2:
__NOTOC__
__NOTOC__
{{ModuleFunction|SebasIRC}}
{{ModuleFunction|SebasIRC}}
<h2 style="margin:0; background:#990000; font-size:120%; font-weight:bold; border:1px solid #a3bfb1; text-align:left; color:#fff; padding:0.2em 0.4em;">This function is currently disabled in the ml_irc-rewrite branch!</h2>


This function will check if the irc bot is connected.
This function will check if the irc bot is connected.

Revision as of 18:54, 11 September 2009


Package-x-generic.png This function is provided by the external module SebasIRC. You must install this module to use this function.

This function is currently disabled in the ml_irc-rewrite branch!

This function will check if the irc bot is connected.

It sends simply a PING to the irc server.

Syntax

bool ircIsConnected()

Returns

True if connected, otherwise false.

Example

addCommandHandler("connected",
  function()
    if ircIsConnected() then
      outputChatBox("-IRC- Connection is ok!")
    else
      outputChatBox("-IRC- Not connected!")
    end
  end
)

See also

Connection:

Channel:

Bot: