Advertisement
Guest User

FEH GHB adb guide

a guest
Jul 21st, 2018
808
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.95 KB | None | 0 0
  1. ==== INSTALLATION ====
  2. Download platform-tools from https://developer.android.com/studio/releases/platform-tools and extract it somewhere
  3. Go to phone settings > about phone > build number
  4. Tap build number repeatedly until developer options are enabled
  5. Go to phone settings > developer options (turn on) > USB debugging (turn on)
  6. Connect phone to computer through USB
  7. Install phone drivers on computer if necessary - some do it automatically, others need you to find it yourself. Try searching for your phone's manufacturer.
  8.  
  9. ==== VERIFY ====
  10. Open a cmd prompt
  11. Navigate to your platform-tools folder by using the 'cd' command (ex. cd desktop/platform-tools)
  12. Run 'adb devices' (type it into the cmd prompt and press enter) to confirm that your phone is recognized (some ID should show up under the list of devices)
  13. If your device is not recognized, make sure you have appropriate drivers installed. If you do, try turning developer options and/or USB debugging off and on. Another thing to try is to change your "Use USB for" settings (swap around between Charging, File and Photo transfers, and MIDI).
  14.  
  15. ==== IN GAME SETTINGS ====
  16. "Auto-Battle Button" - "All Locations" or "In Button Bar"
  17. "Auto: No Animation" - "On"
  18. "Starting a Map" - "Go into Battle" - If you really want to keep "Swap Spaces", then add in an extra tap/wait command before the tap for the auto battle button (after line 16 in the template). This will slow down your macro.
  19.  
  20. ==== BAT SCRIPT ====
  21. On your phone, in developer options, you can enable "Pointer location" to find exact x/y coordinates you want to tap.
  22. Create a text file inside the platform-tools folder and open it with a text editor
  23. Follow the template from https://pastebin.com/Y9V6xsFC to create your own script (ie. just copy/paste it into your text file)
  24. Rename your text file's file extension to .bat - you can still edit it afterwards, but you'll need to right click and "open with" a text editor
  25.  
  26. rem // This is a comment
  27. "adb shell input tap x y" will tap at position x y
  28. "timeout /t x" will delay the next command for x seconds
  29. ":loop
  30. ...commands...
  31. goto :loop" will make an infinite loop
  32.  
  33. ==== RUNNING IT ====
  34. Double click the .bat in your platform-tools folder while keeping your phone connected to your computer with USB debugging enabled. You may need to re-enable USB debugging each time you reconnect your phone. The cmd prompt that shows up must be left open to keep the script running. Close it to stop the macro.
  35.  
  36. ==== APPENDIX ====
  37. If the macro breaks out of the loop and goes to the shop screen when you leave it on overnight, it is most likely due to you having inconsistent load times. There are two load times in total - one after tapping the Fight! button (to load into the battle) and one after tapping anywhere for the Stage Clear! screen (to load the GHB menu). To be specific in terms of the template, they are the two delays of 5 seconds each (timeout /t 5 /nobreak) on lines 10 and 25. To make the macro more consistent, increase these delay times.
  38.  
  39. In the provided template, I have tried to position the tap coordinates for the macro to be as "safe" as possible, even when the loop breaks.
  40. When tapping the auto battle button, the coordinates must align with the shop button (if you are not in a battle). This is absolutely unavoidable, and your macro may take you to the shop screen if the loop breaks.
  41. Therefore, all other tap coordinates in the entire loop were set to tap in "safe" spots on the shop screen - ones that will avoid buying or spending orbs.
  42. However, I have not found a way to avoid tapping the restore dueling swords button. It is impossible to tap in between two buttons on the shop screen (between restore dueling swords and expand barracks), so the macro may waste a single dueling crest if your swords are empty. A simple solution to this is to only do only two arena battles per day, since you only need two for the daily quest anyways. If your swords are not completely empty, it will not let you spend any crests.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement