Conversation
Add: templates for Mi8(dipper) with 400dpi screen Add: function to collect own forest energy Fix: swipe will no more trigger back gesture on MIUI Optimize: code structure TODO: more reasonable time gap strip adb operations from @Class Ant
|
The changes are most focused on coding style and "os.system" to subprocess, right? Anything else I missed? And any bugfix in this PR? |
| rc = self.getIconPos('farm_thief_flag_template', 0.8) | ||
| if not rc: | ||
| self.swipe(self.width // 2, self.height - 10, self.width // 2, self.height // 1.5, 600 ) | ||
| self.swipe(self.width // 2, self.height - 250, self.width // 2, self.height // 2, 600 ) |
There was a problem hiding this comment.
swipe-up from very bottom may trigger "back to home" gesture on ROMs with full screen gestures.
so i shift up this swipe-up here.
| def findMoreFriends(self): | ||
| for i in range(5): | ||
| self.swipe(self.width // 2, self.height - 10, self.width // 2, self.height // 2, 400 ) | ||
| self.swipe(self.width // 2, self.height - 250, self.width // 2, self.height // 2, 400 ) |
| time.sleep(4) | ||
| break | ||
|
|
||
| def getOwnEnergy(self): |
There was a problem hiding this comment.
cannot go back to one's own forest from friend list.
so add a function to collect own energy at entering the forest interface.
|
|
||
| def playForest(self): | ||
| self.checkForest() | ||
| self.getOwnEnergy() |
There was a problem hiding this comment.
run getOwnEnergy() immediately after launching the forest interface
|
Some bugfix changes are:
|
Hello!
I added the English templates for Mi8(dipper) with 400dpi screen, and optimized (at least) main function. if you wanna cherry-pick some of the code changes, please do it. ^_^
and... sorry that i forgot to edit README