mirror of
https://github.com/pragma-/pbot.git
synced 2024-12-23 19:22:40 +01:00
modules/math.pl: understand "ultimate question" a bit better
This commit is contained in:
parent
20f767e2f2
commit
0da1e02da1
4
modules/math.pl
vendored
4
modules/math.pl
vendored
@ -25,8 +25,8 @@ if ($#ARGV < 0)
|
|||||||
$arguments = join(' ', @ARGV);
|
$arguments = join(' ', @ARGV);
|
||||||
my $orig_arguments = $arguments;
|
my $orig_arguments = $arguments;
|
||||||
|
|
||||||
$arguments =~ s/(the )*answer.*question of life(,? the universe,? and everything)?\s?/42/gi;
|
$arguments =~ s/(the )*(ultimate )*answer.*question of life(,? the universe,? and everything)?\s?/42/gi;
|
||||||
$arguments =~ s/(the )*meaning of (life|existence|everything)?/42/gi;
|
$arguments =~ s/(the )*(ultimate )*meaning of (life|existence|everything)?/42/gi;
|
||||||
|
|
||||||
if ($arguments =~ s/(\d+\s?)([^ ]+)\s+to\s+([^ ]+)\s*$/$1/) {
|
if ($arguments =~ s/(\d+\s?)([^ ]+)\s+to\s+([^ ]+)\s*$/$1/) {
|
||||||
@conversion = ($2, $3);
|
@conversion = ($2, $3);
|
||||||
|
Loading…
Reference in New Issue
Block a user