diff --git a/cocobot.py b/cocobot.py index 2c36eab..5249998 100755 --- a/cocobot.py +++ b/cocobot.py @@ -6,8 +6,6 @@ import logging from tools.base import CoboBot from tools.processors import MessageDispatcher, CommandsDispatcherProcessor, ConnectionDispatcher -from tools.processors.messages import RandomTrigger, PikaAttackCommand, \ - RandomCommandTrigger # setting up argument parser parser = argparse.ArgumentParser(description='Le lou bot') diff --git a/tools/coco/client.py b/tools/coco/client.py index b290d60..9772aa6 100644 --- a/tools/coco/client.py +++ b/tools/coco/client.py @@ -30,18 +30,15 @@ class Interlocutor: class CocoClient: - def __init__(self, nick: str, age: int, is_female: bool, zip_code: str): - self.nick = nick - self.age = age - self.is_female = is_female - self.zip_code = zip_code + def __init__(self): self.interlocutors = [] # type: List[Interlocutor] + self.current_interlocutor = None # type: Interlocutor self.user_id = None # type:str self.user_pass = None # type:str - def connect(self): - login_req = LoginRequest(self.nick, self.age, self.is_female, self.zip_code) + def connect(self, nick: str, age: int, is_female: bool, zip_code: str): + login_req = LoginRequest(nick, age, is_female, zip_code) self.user_id, self.user_pass = login_req.retrieve() logging.info("Logged in to coco as %s" % self.nick) post_login_req = PostLoginRequest(self.user_id, self.user_pass)