Skip to content

Instantly share code, notes, and snippets.

@thatfunkymunki
Last active May 18, 2017 09:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save thatfunkymunki/44a19836298b46ac210ec88913a244f0 to your computer and use it in GitHub Desktop.
Save thatfunkymunki/44a19836298b46ac210ec88913a244f0 to your computer and use it in GitHub Desktop.
irc color spammer
#!/bin/perl
use strict;
use Irssi;
use Irssi::Irc;
use vars qw($VERSION %IRSSI);
$VERSION= '1.0';
%IRSSI = (
authors => 'munki props to vap0r and acidvegas',
contact => 'thatfunkymunki@gmail.com',
name => 'cspam',
description => "irc color spam",
license => "BSD",
url => "none",
changed =>"05-17-2017 2320"
);
sub cspam{
my ($data, $server, $witem) = @_;
my $color = [int rand 15, int rand 15];
# my $bullshit = substr("\x03${$color}[0],${$color}[1]$data\x03${$color}[1],${$color}[0]$data" x 100 , 0, 400);
my $bullshit = substr("\x03${$color}[0],${$color}[1]" . ("$data\x16$data\x16" x 100) , 0, 400);
$witem->command("SAY $bullshit");
}
Irssi::command_bind('cspam', 'cspam');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment