Skip to content

Instantly share code, notes, and snippets.

@alpsayin
Last active March 25, 2016 17:30
Show Gist options
  • Save alpsayin/6ace9bbf711d1c9ec321 to your computer and use it in GitHub Desktop.
Save alpsayin/6ace9bbf711d1c9ec321 to your computer and use it in GitHub Desktop.
A small windows batch script to autoaim Facebook Messenger's hidden basketball game. Requires adb bridge. Open Messenger, start a game and run this script.Touch the ball and it will automatically make the perfect swipe to shoot the ball into the hoop. Tested on Oneplus One, Cyanogenmod 13.
set index=1
:While
if %index% gtr 10000 goto EndWHile
echo Iteration number %index%
set /A index+=1
Rem set /p xIndex=Enter X Index:
adb shell "getevent -lc 16 /dev/input/event0 | grep ABS_MT_POSITION_X | awk '{print $3}' | (read string; echo $((16#$string)))" > touch_location.txt
set /p xIndex=<touch_location.txt
echo %xIndex%
adb shell "input swipe %xIndex% 1706 540 720 50"
goto While
:EndWhile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment