jawikas / hamsterkombat

This is a bot that can help you to run hamsterkombat telegram bot which has quite complete features with auto upgrade (3 methods), auto complete combo & auto complete daily cipher/morse.
https://t.me/hamster_kombat_Bot/start?startapp=kentId1323733375
68 stars 24 forks source link

Autostart after first setup #22

Closed krisproger closed 5 days ago

krisproger commented 1 month ago

Thank you for the good job! That repo is the best practices to knows how it works inside the tap apps (IMHO), but... )) when i setup options at first time i want to launch script without questions in future. What i mean: at first app wrote options to config.json after setup and than always try to get settings from config in main() core.py

    auto_upgrade = config.get('auto_upgrade', False)
    combo_upgrade = config.get('combo_upgrade', False)
    daily_cipher_on = config.get('daily_cipher_on', False)
    claim_key_on = config.get('claim_key_on', False)
    tasks_on = config.get('tasks_on', False)
    _method = config.get("upgrade_method", "1")
    taps_on = config.get("taps_on", False)
    promo_on = config.get("promo_on", False)

the second one is to setup autostart option in menu in choices and config read:

    autostart = config.get("autostart", False)

the last one is to check autostart option in while|try:

            if not autostart:
                choice = show_menu(auto_upgrade, taps_on, combo_upgrade, daily_cipher_on, claim_key_on, tasks_on, promo_on)
            else:
                choice = "0"
jawikas commented 1 month ago

as you want ! :)

krisproger commented 4 weeks ago

just as advice to improve app in stock ;-)