3
0
mirror of https://github.com/pragma-/pbot.git synced 2024-11-26 22:09:26 +01:00

Add some more commands to me/my-expansion exclusion-list

This commit is contained in:
Pragmatic Software 2017-08-23 19:22:03 -07:00
parent 6f9d9aba07
commit 375dd52b41

View File

@ -133,10 +133,10 @@ sub process_line {
} }
$processed += 100; $processed += 100;
} elsif($cmd_text =~ s/^$bot_trigger(.*)$//) { } elsif($cmd_text =~ s/^.?$botnick.?\s*(.*?)$//i) {
$command = $1; $command = $1;
$processed += 100; $processed += 100;
} elsif($cmd_text =~ s/^.?$botnick.?\s*(.*?)$//i) { } elsif($cmd_text =~ s/^$bot_trigger(.*)$//) {
$command = $1; $command = $1;
$processed += 100; $processed += 100;
} elsif($cmd_text =~ s/^(.*?),?\s*$botnick[?!.]*$//i) { } elsif($cmd_text =~ s/^(.*?),?\s*$botnick[?!.]*$//i) {
@ -204,7 +204,7 @@ sub interpret {
$tonick = $nick if defined $tonick and $tonick eq 'me'; $tonick = $nick if defined $tonick and $tonick eq 'me';
if ($keyword !~ /^(factadd|add|factfind|find|factshow|show|forget|factdel|factset|factchange|change|msg|tell)/) { if ($keyword !~ /^(factadd|add|factfind|find|factshow|show|forget|factdel|factset|factchange|change|msg|tell|cc|eval|u|udict|ud|actiontrigger|urban|perl)/) {
$keyword =~ s/(\w+)([?!.]+)$/$1/; $keyword =~ s/(\w+)([?!.]+)$/$1/;
$arguments =~ s/(?<![\w\/\-\\])me\b/$nick/gi if defined $arguments && $depth <= 2; $arguments =~ s/(?<![\w\/\-\\])me\b/$nick/gi if defined $arguments && $depth <= 2;
$arguments =~ s/(?<![\w\/\-\\])my\b/${nick}'s/gi if defined $arguments && $depth <= 2; $arguments =~ s/(?<![\w\/\-\\])my\b/${nick}'s/gi if defined $arguments && $depth <= 2;