From 075232db87b57901024fed0a036b288459222b1b Mon Sep 17 00:00:00 2001 From: peter Date: Mon, 9 Sep 2024 19:17:47 +0100 Subject: [PATCH] Make deck loading optional --- clashroyalebuildabot/bot/bot.py | 3 ++- clashroyalebuildabot/config.yaml | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/clashroyalebuildabot/bot/bot.py b/clashroyalebuildabot/bot/bot.py index 383d35f..9914ac5 100644 --- a/clashroyalebuildabot/bot/bot.py +++ b/clashroyalebuildabot/bot/bot.py @@ -66,7 +66,8 @@ def __init__(self, actions, auto_start=True): ) keyboard_thread.start() - self.emulator.load_deck(cards) + if config["load_deck"]: + self.emulator.load_deck(cards) @staticmethod def _log_and_wait(prefix, delay): diff --git a/clashroyalebuildabot/config.yaml b/clashroyalebuildabot/config.yaml index d104d13..12dafee 100644 --- a/clashroyalebuildabot/config.yaml +++ b/clashroyalebuildabot/config.yaml @@ -4,6 +4,9 @@ bot: # "WARNING" for warning messages, "ERROR" for error messages, and "CRITICAL" for critical issues. log_level: "DEBUG" + # Create a deck code when the game starts + load_deck: True + adb: # The IP address of your device or emulator. # Use 127.0.0.1 for a local emulator. If you're connecting to a physical device,