class Questioner: name = "Questioner" character = '?' def __init__(self, board_size): board_width, board_height = board_size self.position = (board_width // 2, board_height // 2) def play_turn(self,game): person = game.get_agent_by_name('Person') if person: personx, persony = person.position questionerx, questionery = self.position if personx == questionerx and persony == questionery +1: prompt = input("Questioner: Are you ready to start the game? [[Y/N]] \n") if prompt.strip().upper() == "Y": print("Questioner: Well then, the rules are as follows... \n 1. You have 3 lives. \n 2. For every 200 points you accumulate during Starfall, you receive a question. \n 3. Each wrong answer costs you a life. You must answer 3 questions to escape this terminal. \n") begin = input("Questioner: Shall we begin? [[Y/N]] \n" ) if begin.strip().upper() == "Y": print("Questioner: Well then, good luck player! \n") game.state["begin"] = True elif prompt.strip().upper() == "N": print("Questioner: I'll be here when you're ready. \n") else: print("Questioner: What now?) \n")