summaryrefslogtreecommitdiff
path: root/data/rbot/plugins/games/uno.rb
diff options
context:
space:
mode:
authorGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2008-04-11 15:31:40 +0200
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2008-04-11 15:31:40 +0200
commitf4d25ccbbcb4235ed7d85e31df4e31c509387c45 (patch)
tree835f241b643d1d9595df592ccff6713b90135d16 /data/rbot/plugins/games/uno.rb
parent5aeef49abc6959b45989bc65d25357b16f062030 (diff)
uno plugin: allow playing a double +2 card
Diffstat (limited to 'data/rbot/plugins/games/uno.rb')
-rw-r--r--data/rbot/plugins/games/uno.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/data/rbot/plugins/games/uno.rb b/data/rbot/plugins/games/uno.rb
index f1573dc7..e25d5580 100644
--- a/data/rbot/plugins/games/uno.rb
+++ b/data/rbot/plugins/games/uno.rb
@@ -326,7 +326,7 @@ class UnoGame
def play_card(source, cards)
debug "Playing card #{cards}"
p = get_player(source)
- shorts = cards.gsub(/\s+/,'').match(/^(?:([rbgy]\d){1,2}|([rbgy](?:\+\d|[rs]))|(w(?:\+4)?)([rbgy])?)$/).to_a
+ shorts = cards.gsub(/\s+/,'').match(/^(?:([rbgy]\+?\d){1,2}|([rbgy][rs])|(w(?:\+4)?)([rbgy])?)$/).to_a
debug shorts.inspect
if shorts.empty?
announce _("what cards were that again?")