Overview

Namespaces

  • Budabot
    • Core
      • Modules
    • User
      • Modules
  • None
  • Tyrence
    • Modules

Classes

  • AdminController
  • AliasController
  • AltInfo
  • AltsController
  • BanController
  • BuddylistController
  • ColorsController
  • CommandlistController
  • CommandSearchController
  • ConfigController
  • EventlistController
  • HelpController
  • LogsController
  • PlayerLookupController
  • ProfileCommandReply
  • ProfileController
  • SettingsController
  • SQLController
  • SystemController
  • UsageController
  • WhitelistController

Functions

  • read_input
  • Overview
  • Namespace
  • Class

Class BanController

Namespace: Budabot\Core\Modules
Definecommand(:

command = 'ban', accessLevel = 'mod', description = 'Ban a character from this bot', help = 'ban.txt', defaultStatus = '1' )


Definecommand(:

command = 'banlist', accessLevel = 'mod', description = 'Shows who is on the banlist', help = 'ban.txt', defaultStatus = '1' )


Definecommand(:

command = 'unban', accessLevel = 'mod', description = 'Unban a character from this bot', help = 'ban.txt', defaultStatus = '1' )


Instance: Commands this controller contains:
Located at BAN/BanController.class.php
Methods summary
public
# setup( )

Setup

This handler is called on bot startup.
public
# initializeBanList( $eventObj )

Defaultstatus("1")

Description("upload

banlist into memory")

Event("connect")

public
# banPlayerWithTimeAndReasonCommand( $message, $channel, $sender, $sendto, $args )

Command parameters are: - name of the character - time of ban - banning reason string

Command parameters are: - name of the character - time of ban - banning reason string

Handlescommand("ban")

Matches("/^ban

([a-z0-9-]+) ([a-z0-9]+) (for|reason) (.+)$/i")
public
# banPlayerWithTimeCommand( $message, $channel, $sender, $sendto, $args )

This command handler bans a player from this bot.

This command handler bans a player from this bot.

Command parameters are: - name of the player - time of ban

Handlescommand("ban")

Matches("/^ban

([a-z0-9-]+) ([a-z0-9]+)$/i")
public
# banPlayerWithReasonCommand( $message, $channel, $sender, $sendto, $args )

This command handler bans a player from this bot.

This command handler bans a player from this bot.

Command parameters are: - name of the player - banning reason string

Handlescommand("ban")

Matches("/^ban

([a-z0-9-]+) (for|reason) (.+)$/i")
public
# banPlayerCommand( $message, $channel, $sender, $sendto, $args )

This command handler bans a player from this bot.

This command handler bans a player from this bot.

Command parameter is: - name of the player

Handlescommand("ban")

Matches("/^ban

([a-z0-9-]+)$/i")
public
# banlistCommand( $message, $channel, $sender, $sendto, $args )

This command handler shows who is on the banlist.

This command handler shows who is on the banlist.

Handlescommand("banlist")

Matches("/^banlist$/i")

public
# unbanCommand( $message, $channel, $sender, $sendto, $args )

This command handler unbans a player from this bot.

This command handler unbans a player from this bot.

Command parameter is: - name of the player

Handlescommand("unban")

Matches("/^unban

(.+)$/i")
public
# checkTempBan( $eventObj )

Defaultstatus("1")

Description("check

temp bans to see if they have expired")

Event("timer(1min)")

private
# banPlayer( $who, $sender, $length, $reason, $sendto )

This helper method bans player with given arguments.

This helper method bans player with given arguments.

public
# add( $charId, $sender, $length, $reason )
public
# remove( $charId )
public
# uploadBanlist( )
public
# isBanned( $charId )
public
# getBanlist( )
Properties summary
public $moduleName

Name of the module. Set automatically by module loader.

Name of the module. Set automatically by module loader.

#
public $accessManager

Inject

#
public $util

Inject

#
public $chatBot

Inject

#
public $settingManager

Inject

#
public $text

Inject

#
public $db

Inject

#
private array $banlist
# array()
public string $defaultNotifyBannedPlayer

Accesslevel("mod")

Description("notify

character when banned from bot")

Intoptions("1;0")

Options("true;false")

Setting("notify_banned_player")

Type("options")

Visibility("edit")

# "1"
Budabot 4 Docs API documentation generated by ApiGen