Modules/IRCEcho/ircGetStatus

From Multi Theft Auto: Wiki
Revision as of 19:18, 13 January 2008 by Mountnl (talk | contribs) (New page: __NOTOC__ {{ModuleFunction|IRCEcho}} Can be used to check if the user has Op or higher ==Syntax== <syntaxhighlight lang="lua"> function ircGetStatus ( IRCConnection irc, string channel, string nick ) </...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search


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

Can be used to check if the user has Op or higher

Syntax

function ircGetStatus ( IRCConnection irc, string channel, string nick )

Required arguments

  • irc: The IRCConnection
  • channel: The channel that you want to check on
  • nick: The person that you want to check on

Example

Example 1: This script can be used from irc, so people can check their rights

function irc_onPrivMsg( szChannel, szNick, szText )
  	if string.find( szText, "!rights" ) == 1 then
		ircMessage( pIRC, szChannel,  szNick .. ", you have level " .. tostring( ircGetStatus( pIRC, szChannel, szNick ) )
	end
end