{"repo":"h8d13/hayday","free":true,"listed":false,"github":"https://github.com/h8d13/hayday","clone":"git clone https://github.com/h8d13/hayday.git","description":"HayDay Bot in Python / CV2 - Automatic wheat farm","language":"Python","stars":34,"topics":["hayday","haydaybot","automation","game-automation-using-python","opencv"],"license":null,"category":"workflow-automation","readme_excerpt":"HayDay Farm HayDay Bot Python ⚠ The two (or more) other python packages on GitHub for HayDay are viruses (bad ones at that). Please reset your computer if you've ran these programs at all. I have reported it to github... There might be a lot more of them. ⚠ Github rendering vuln used by hackers It's a game that preys on your patience, so it's fun to automate. Finally, I will not provide the full automation script as it's against terms of service. I will however, show the full work to get there. Also thanks to @claritycoders for inspiration with the fishing bot. --- Accessing a iOS or Android device For android you can use use scrcpy --fullscreen Scrcpy GitHub Unsure about iOS specifics. This would be your first hurdle, but you can also use bluestacks or any emulator that let's you run the game in full-screen with input. As per any automation problem we should break down the exercise: InfiniFarm - Automatically detect the soil - Plant Wheat (most profitable) - Sell during growth (downtime) - Harvest - Repeat Soil detection As we determined above, the most important will be to detect the area the bot can use to grow crops. To do this we can do a couple of things: 1. Color How to do it: 2. Thresholding/Masking/Countours 3. Shape matching Then we can use cv2 built-in This is a complex algorithm but essentially will adapt the rectangle to fit the perspective of the game. Centroid Having a uneven amount of tiles is essential (see screenshot above, 21 tiles works because the center ","default_branch":null,"files":null,"tree":[],"storefront":"/r/h8d13","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/h8d13/hayday/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}