EnchantmentCracker icon indicating copy to clipboard operation
EnchantmentCracker copied to clipboard

Screenshot input option (Feature request)

Open HaphLife opened this issue 4 years ago • 5 comments
trafficstars

E: And my final suggestion for user-error reduction would to be to take screenshots as inputs. You might have to require the user to take screenshots in a particular order, (perhaps 15 through 9) because it's hard to tell how many bookshelves are used, but it should possible to read the level requirements automatically. This could actually take a lot of work, and might not be worth it. I'd recommend trying to detect the UI size by finding the corners of the UI window (they always appear along certain lines that intersect with the center of the image), and then use that to find where the numbers are.

This would make inputting data to the cracker much much easier, and give the user fewer places to mess up.

HaphLife avatar Jan 24 '21 23:01 HaphLife

Fun fact: I hate machine learning :( So if this were to be implemented, it would have to be via a PR if anyone is willing :)

Earthcomputer avatar Jan 25 '21 00:01 Earthcomputer

Machine learning? It’s a known UI shape and a known font, it’s not impossible to do with classical code, just takes a bit of effort.

You could use machine learning, but I wasn’t suggesting that.

HaphLife avatar Jan 25 '21 01:01 HaphLife

Machine learning is the best solution.

Earthcomputer avatar Jan 26 '21 02:01 Earthcomputer

If you want it to work with texture packs, yes. If you don't doing a smart pixel search is completely possible.

HaphLife avatar Jan 26 '21 02:01 HaphLife

This is certainly doable (see: Robot class) and I've fiddled with it at one point but it would take considerable work and there's the hurdle of having to work out how many shelves were used, which can be narrowed down by knowing valid ranges but is still ambiguous. It would also need to work with varying UI scales, and possibly also texture packs.

On the flip side, if implemented this would also let the tool warn you if you're about to use the wrong number of shelves for an enchantment, which is a mistake I've made at least once. Another bonus is that it would be able to pass in description text as well as shelf numbers, which could drastically improve cracking times.

Hexicube avatar Feb 08 '21 19:02 Hexicube