Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dedicated settings for each streamer #36

Merged
merged 10 commits into from
Feb 1, 2021
Merged

Conversation

Tkd-Alex
Copy link
Owner

@Tkd-Alex Tkd-Alex commented Feb 1, 2021

  • Dedicated settings for each streamer. This will close Dedicated settings for each streamer #24
  • Huge code refactory. Move many classes inside entities folder.
  • Manage global settings (especially Logger.less) without passing as parameters.

You can customize the settings for each streamer. If not settings was provided the script will use the streamer_settings from TwitchChannelPointsMiner.
If no streamer_settings provided in TwitchChannelPointsMiner the script will use default settings.
The streamers array can be a String -> username or Streamer instance.

The settings priority are: settings in mine function, settings in TwitchChannelPointsMiner instance, default settings.
For example if in the mine function you don't provide any value for 'make_prediction' but you have set it on TwitchChannelPointsMiner instance the script will take the value from here.
If you haven't set any value even in the instance the default one will be used

twitch_miner.mine(
    [
        Streamer("streamer-username01", settings=StreamerSettings(make_predictions=True  , follow_raid=False , claim_drops=True  , watch_streak=True , bet=BetSettings(strategy=Strategy.SMART      , percentage=5 , percentage_gap=20 , max_points=234   ) )),
        Streamer("streamer-username02", settings=StreamerSettings(make_predictions=False , follow_raid=True  , claim_drops=False ,                     bet=BetSettings(strategy=Strategy.PERCENTAGE , percentage=5 , percentage_gap=20 , max_points=1234  ) )),
        Streamer("streamer-username03", settings=StreamerSettings(make_predictions=True  , follow_raid=False ,                     watch_streak=True , bet=BetSettings(strategy=Strategy.SMART      , percentage=5 , percentage_gap=30 , max_points=50000 ) )),
        Streamer("streamer-username04", settings=StreamerSettings(make_predictions=False , follow_raid=True  ,                     watch_streak=True                                                                                                        )),
        Streamer("streamer-username05", settings=StreamerSettings(make_predictions=True  , follow_raid=True  , claim_drops=True ,  watch_streak=True , bet=BetSettings(strategy=Strategy.ODDS       , percentage=7 , percentage_gap=20 , max_points=90    ) )),
        Streamer("streamer-username06"),
        Streamer("streamer-username07"),
        Streamer("streamer-username08"),
        "streamer-username09",
        "streamer-username10",
        "streamer-username11"
    ],                                 # Array of streamers (order = priority)
    followers=False                    # Automatic download the list of your followers (unable to set custom settings for you followers list)
)  

@Tkd-Alex Tkd-Alex added the enhancement New feature or request label Feb 1, 2021
@Tkd-Alex Tkd-Alex merged commit e13cd4b into master Feb 1, 2021
@Tkd-Alex Tkd-Alex deleted the dedicated-settings-refactory branch February 3, 2021 10:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Dedicated settings for each streamer
1 participant