Bot reference
From Botdom Wiki
| → |
It is suggested that this page should be moved to Botdom Documentation. Please do not move the page by hand. It will be moved by an administrator with the full edit history. In the meantime, you may continue to edit the page as normal. You can discuss this decision on the talk page. |
This is a technical reference on the most common methods in different bots.
PHP Bots
| dAmnBot/NoodleBot | xbot | Futurism | |
|---|---|---|---|
| dAmn functions | |||
Join $channel
| dAmn_Join( $channel );
| $sys_cl -> join( $channel );
| $dAmn -> joinRoom( $channel );
|
Part $channel
| dAmn_Part( $channel );
| $sys_cl -> part( $channel );
| $dAmn -> partRoom( $channel );
|
Say $msg in $channel with $type (msg, npmsg or action)
| dAmn_msg( $msg, $channel, $type );
| $sys_cl -> msg( $channel, $msg, $type );
| $dAmn -> say( $msg, $channel );
|
Kick $user from $channel for $reason
| dAmn_Kick( $user, $channel, $reason );
| $sys_cl -> kick( $channel, $user, $reason );
| $dAmn -> kick( $user, $channel, $reason );
|
Promote/demote $user to $privclass in $channel
| N/A |
|
|
Ban/unban $user from $channel
| N/A |
|
|
Set $channel's $property (topic or title)
| dAmn_Set( $channel, $property, $value );
| $sys_cl -> set( $channel, $property, $value );
| $dAmn -> set( $property, $value, $channel );
|
Admin function in $channel
| dAmn_Admin( $channel, $type, $typeval, $priv, $vals ); (NoodleBot only)
| $sys_cl -> admin( $channel, $type, $typeval, $priv, $vals );
| $dAmn -> admin( $command, $channel );
|
Parses $priv (a channel privclass name or a channel privclass value)
| N/A |
|
. |
| Bot user functions | |||
Get whois information for $user
| N/A
| $sys_cl -> whois( $user )
| $dAmn -> getUserInfo( $user )
|
See whether $user has $priv or more.
| user_has( $user, $priv )
| hasMinPriv( $user, $priv )
| $user -> has( $user, $priv )
|
See whether $user has $priv or less.
| N/A
| hasMaxPriv( $user, $priv )
| None yet. |
Parses $priv (a bot privclass name or a bot privclass value)
| N/A |
|
|
| System variables | |||
| Channel data |
$properties = array ( channel = array ( "title", "topic" = array ( p, by, ts, data ), "privclasses" = array ( number => name, name => number, ), "members"/**/ = array ( name => array ( pc, usericon, symbol, realname, typename, gpc, count ), "privclassmembers"/***/ = array ( privclassname => array ( membername ) ) ) )
|
$sys_ch = array( $channel => dAmnChan ( name, title,topic = array ( p, by, ts, data, ), members* = array ( name => array ( pc, count, ) ), pcs = array ( number => array ( name, perms**, members** => array(), ) ) ) )
|
Still unfinished. $properties = array( "c" => array( $channel => array( "ti" => $title, "to" => $topic, "pc" => $privclasses, "u" => $users ) ), "u" => array( ), // Unfinished, probably reorganizing ); |
| User data |
$users = array ( $name => priv, ) |
$sys_users = array ( $name => User ( name, priv, info => array ( usericon, symbol, realname, typename, gpc, ) connections* => array ( $index => array ( online, onlinesince, idle, channels => array(), ) ) ) )
|
$user->users = array ( $privclassNumber = array ( "__classname" => $privclassName, $username => $privclassNumber, // repeat ) // repeat ) |
| Event data | Assortment of variables. See process.php |
$sys_trg* = array ( type, mod, subj, obj, chan, cmd, args, )
| |

