From dcdc1e4ac2404fb90b9d5f3390614c5cc46b3e0f Mon Sep 17 00:00:00 2001 From: doy Date: Fri, 24 Apr 2009 22:49:19 -0500 Subject: temporary fix to allow canceling ghostlike games --- lib/Bot/Games/Game/Ghostlike.pm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/Bot/Games/Game/Ghostlike.pm b/lib/Bot/Games/Game/Ghostlike.pm index a025eb2..fc6229a 100644 --- a/lib/Bot/Games/Game/Ghostlike.pm +++ b/lib/Bot/Games/Game/Ghostlike.pm @@ -121,6 +121,12 @@ command valid_word_from_state => sub { return uc($word) eq $self->state; }; +command give_up => sub { + my $self = shift; + $self->is_over(1); + return "Game over!"; +}; + sub current_player_index { my $self = shift; for (0..($self->num_players - 1)) { -- cgit v1.2.3-54-g00ecf