Bot::Cobalt::Plugin::Figlet - Bot::Cobalt plugin for displaying figlets
version 0.001
## In plugins.conf Figlet: Module: Bot::Cobalt::Plugin::Figlet Opts: fontdir: var/fonts # default: /usr/games/lib/figlet maxwidth: 160 # default: -1 (no maxwidth)
A Bot::Cobalt plugin.
This plugin provides commands to turn text into figlets and broadcast them in the channel.
It has two commands:
This command text a message, randomly chooses a figlet from the font directory and uses it to 'figify' the message via Text::FIGlet.
Broadcasts the name of the previous figlet used.
As of Bot::Cobalt 0.016002 there is a problem with Bot::Cobalt::IRC and it's use of POE::Component::IRC::State. Since figlets are multiple lines of text the flood check limits the figlet's broadcast pretty significantly, to the point of unusability.
A workaround is to modify Bot::Cobalt::IRC to turn pass in flood => 1 to the spawning of POE::Component::IRC::State:
At around line 213 of Bot::Cobalt::IRC simply change:
my %spawn_opts = ( resolver => core->resolver, + flood => 1,
Thanks to Jon Portnoy <avenj@cobaltirc.org> for tracking this down.
Scott Miller <scott.j.miller@gmail.com>
This software is copyright (c) 2014 by Scott Miller.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Bot::Cobalt::Plugin::Figlet, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Bot::Cobalt::Plugin::Figlet
CPAN shell
perl -MCPAN -e shell install Bot::Cobalt::Plugin::Figlet
For more information on module installation, please visit the detailed CPAN module installation guide.