Officially support choosing a card twice, as it was already possible due to a bug
This commit is contained in:
parent
fc19e7c442
commit
846deec537
|
@ -1047,11 +1047,7 @@ def game(send, notice, voice, devoice, get_event):
|
||||||
selected_cards = []
|
selected_cards = []
|
||||||
for choice in choices:
|
for choice in choices:
|
||||||
if 0 <= choice < len(player.hand):
|
if 0 <= choice < len(player.hand):
|
||||||
if player.hand[choice] not in selected_cards:
|
selected_cards.append(player.hand[choice])
|
||||||
selected_cards.append(choice)
|
|
||||||
else:
|
|
||||||
notice(nick, 'Can\'t play the same card twice')
|
|
||||||
break
|
|
||||||
else:
|
else:
|
||||||
notice(nick, '%i not in your hand' % choice)
|
notice(nick, '%i not in your hand' % choice)
|
||||||
break
|
break
|
||||||
|
@ -1060,8 +1056,6 @@ def game(send, notice, voice, devoice, get_event):
|
||||||
# Failed to use some choice
|
# Failed to use some choice
|
||||||
continue
|
continue
|
||||||
|
|
||||||
selected_cards = [player.hand[i] for i in selected_cards]
|
|
||||||
|
|
||||||
card_choices[player] = selected_cards
|
card_choices[player] = selected_cards
|
||||||
if player in choosers:
|
if player in choosers:
|
||||||
choosers.remove(player)
|
choosers.remove(player)
|
||||||
|
|
Loading…
Reference in New Issue