PokemonGoF/PokemonGo-Bot

Config Overhaul

Open

#5218 opened on Sep 5, 2016

View on GitHub
 (20 comments) (3 reactions) (0 assignees)Python (3,816 stars) (1,628 forks)batch import
EnhancementHelp WantedWaiting on Changes

Description

I've been giving a lot of thought to how we setup our configuration files. Here on my thoughts on how we can clean up a whole lot of what we have going on there, as well as our documentation.

Our base config includes global goodies, such as our debug, distance_unit, reconnecting_timeout, etc. Could be split into like types (sleep, output, etc). Also includes a list of all tasks with a simple enable/disable option.

A config file per task. When we update a task, we update a single doc about that task's configuration. If we have an update to the file, it'll be easy to realize where you need to make changes as it's not a mile long. This creates a whole lot more files, but they'll be less overwhelming. We could also add a bit to see if two enabled tasks conflict with each other (not quite on my point here).

Next bit I'm open on, sleep timers for different tasks (possibly speeds too?) all in a different file separate from our task configuration. We change sleep ranges less often than anything else. Plus many of them are repeats, currently. For example, repeat same wait for a similar action in another task.

Last, we could add some bits to limit our need for a hundred ways to filter pokemon and combine release, ignore, snipe, walk_to, transfer, upgrade and so on. Simplest change is just move all pokemon related settings into one file, merging release, transfer, and so forth are all under the same "pokemon" index. This would make for a very long file, but this file would hardly change unless we have some major refactoring. I have more ramblings out this, but I'm drifting...

Ex: "Rattata": { "release_below_iv": 0.9, "release_below_cp": 200, "catch_above_cp": 0.5, "catch_above_iv": 0.0, "keep_best_cp": 1, "keep_best_iv": 1, "always_catch" : false, "always_release" : false, "evolve_above_cp": 500, "evolve_above_iv": 0.8, },

That's just a sample of what could be, I'm sure that would need tweaking and there are a billion other ways to go about this. Related to this, it would be nice if we could also set globals for these values. Say we didn't want to specify per pokemon keep_best values, but instead always keep the top cp/iv of all and also, keep the values listed for the pokemon. If that makes sense...

I'll stop.

Contributor guide