# Enable logging logging.basicConfig(format='%(asctime)s - %(name)s - %(levelname)s - %(message)s', level=logging.INFO) max_len=4 logger = logging.getLogger(__name__) SUGGEST_CARD, GENDER, PHOTO, LOCATION, BIO = range(5) game = Game(-1001390724742) conversation_handler = None for i in range(0, 10): game.add_player(Player(i, "user " + str(i))) game.add_player(Player(237713674, "mikaeel")) def start(update, context): reply_keyboard = [['Boy', 'Girl', 'Other']] keyboard = [ [InlineKeyboardButton("0", callback_data=str(0)), InlineKeyboardButton("4", callback_data=str(5)), InlineKeyboardButton("4", callback_data=str(0))] ] reply_markup = InlineKeyboardMarkup(keyboard) update.message.reply_text( 'Hi! My name is Professor Bot. I will hold a conversation with you. ' 'Send /cancel to stop talking to me.\n\n' 'Are you a boy or a girl?',
import threading import time from Models.Game import Game from Models.Player import Player game = Game(0) for i in range(0, 10): game.add_player(Player(i, "user " + str(i))) def run_game(): while len(game.players) > 2: print("number of players in this turn: " + str(len(game.players))) print("turn started, you can suggest cards") time.sleep(20) game.start_vote_time() print("vote time started, you can vote") time.sleep(20) print("turn ended") game.end_turn() game.start_new_turn() th = threading.Thread(target=run_game) th.start() while True: print("you can perform query") query = input() if query.split()[0] == 'suggest_card':