diff options
author | doy <doy@tozt.net> | 2009-01-23 22:52:14 -0500 |
---|---|---|
committer | doy <doy@tozt.net> | 2009-01-23 22:52:14 -0500 |
commit | cd5e21bb6036d410017c3b863c5ffb4d9270bcb6 (patch) | |
tree | c90e18a23d61be46ae2a9a7cba1903609fe56c49 /lib/Bot/Games/Game | |
parent | 14160c23b5a8d26fa47e08075b214200ebf04897 (diff) | |
download | bot-games-cd5e21bb6036d410017c3b863c5ffb4d9270bcb6.tar.gz bot-games-cd5e21bb6036d410017c3b863c5ffb4d9270bcb6.zip |
make turn use augment/inner so that the after modifier in the base class works
Diffstat (limited to 'lib/Bot/Games/Game')
-rw-r--r-- | lib/Bot/Games/Game/24.pm | 2 | ||||
-rw-r--r-- | lib/Bot/Games/Game/Ghostlike.pm | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/Bot/Games/Game/24.pm b/lib/Bot/Games/Game/24.pm index cbe0edc..63221f3 100644 --- a/lib/Bot/Games/Game/24.pm +++ b/lib/Bot/Games/Game/24.pm @@ -23,7 +23,7 @@ sub init { return $self->generate_24; } -sub turn { +augment turn => sub { my $self = shift; my ($player, $expr) = @_; diff --git a/lib/Bot/Games/Game/Ghostlike.pm b/lib/Bot/Games/Game/Ghostlike.pm index 2505ddf..35d0101 100644 --- a/lib/Bot/Games/Game/Ghostlike.pm +++ b/lib/Bot/Games/Game/Ghostlike.pm @@ -51,7 +51,7 @@ around state => sub { return $self->$orig($state); }; -sub turn { +augment turn => sub { my $self = shift; my ($player, $state) = @_; @@ -71,7 +71,7 @@ sub turn { $self->current_player($self->next_player); return $self->state($state); -} +}; command challenge => sub { my $self = shift; |