Lint fixes

This commit is contained in:
dave 2017-01-01 21:17:59 -08:00
parent 3a1af88987
commit 2cb37e250f
1 changed files with 1 additions and 3 deletions

View File

@ -10,7 +10,6 @@ from pyircbot.modulebase import ModuleBase, ModuleHook
from random import randint
import time
import re
from operator import itemgetter
from threading import Thread
from pprint import pprint
import logging
@ -108,7 +107,6 @@ class UnoPlay(ModuleBase):
# After color change by bot
if "Current player " in trailing and "and chooses" in trailing:
print("BOT WILD")
color = trailing.split(" and chooses ")[1].split(" Current ")[0].strip()
self.current_card[2]['color'] = {'Blue': 'b', 'Red': 'r', 'Yellow': 'y', 'Green': 'g'}[color]
self.current_card[2]['number'] = -1
@ -208,7 +206,7 @@ class UnoPlay(ModuleBase):
child_chain.append(card)
child_cards = cards[:]
child_cards.remove(card)
child_cards.sort(reverse=True, key=lambda x: x[1]) # Explore high value cards first (does this help?)
child_cards.sort(reverse=True, key=lambda x: x[1]) # Explore high value cards first (this helps?)
assert len(child_cards) == len(cards) - 1
for subchain in chain_next(child_cards, child_chain):
subchains.append(subchain)