Skip to content

Instantly share code, notes, and snippets.

@lvrma
Last active September 9, 2022 08:29
Show Gist options
  • Save lvrma/36e809a60157939c506de24967b07a33 to your computer and use it in GitHub Desktop.
Save lvrma/36e809a60157939c506de24967b07a33 to your computer and use it in GitHub Desktop.
Perfect circle to beat the game at https://vole.wtf/perfect-circle/ for absolutely no reason
import win32api, win32con, math
win32api.Sleep(10000)
start_x, start_y = win32api.GetCursorPos()
win32api.SetCursorPos((start_x,start_y))
for i in range(0, 320 * 2, 10):
x = start_x + int(300 * math.cos(float(i)/100.0))
y = start_y + int(300 * math.sin(float(i)/100.0))
win32api.SetCursorPos((x,y))
if i == 0:
win32api.mouse_event(win32con.MOUSEEVENTF_LEFTDOWN,x,y,0,0)
win32api.Sleep(20)
win32api.mouse_event(win32con.MOUSEEVENTF_LEFTUP,x,y,0,0)
@chaz17819
Copy link

how do i use this?

@riot01
Copy link

riot01 commented Feb 25, 2022

how to use?

@RunoQS
Copy link

RunoQS commented Aug 25, 2022

how do i use

@lvrma
Copy link
Author

lvrma commented Aug 26, 2022

(warning: Windows-only): Install Python if you don't have it installed already (and choose the add to Path option). Then, open the terminal (or cmd) with Windows Key + R -> type cmd. In that window, type pip install pypiwin32 to install the Windows Python library. Then, type cd DIR where you replace DIR with the path of the folder where this script circle.py has been downloaded (if you downloaded a ZIP, extract the Py file first and copy the address of that folder). Next, you type python circle.py in the terminal window and, within 10 seconds, move your mouse to the center of the circle in the browser window open at https://vole.wtf/perfect-circle and click it to start the game, resting your cursor at the center of the circle. After 10 seconds, your mouse will click down and draw a perfect circle on its own. The best score you will get is about 99.5%, but that's up to the website.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment