Last active
January 23, 2024 01:10
-
-
Save CloudGang/989eb1bc4a32254ea6d3c1ad27b67c65 to your computer and use it in GitHub Desktop.
CloudGang Gunz BF Macro
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
#!/usr/bin/env python | |
####################################################################### | |
#' Gunz ButterFly Macro '# | |
#' [email protected] '# | |
#' Copyright © 2018 Twiender™ '# | |
#' Copyright © 2018 CloudBots® '# | |
#' All Rights Reserved. '# | |
####################################################################### | |
import keyboard #https://github.com/boppreh/keyboard.git | |
import mouse #https://github.com/boppreh/mouse.git | |
import psutil #https://github.com/giampaolo/psutil | |
import win32gui | |
import time as time | |
def windowEnumerationHandler(hwnd, top_windows): | |
top_windows.append((hwnd, win32gui.GetWindowText(hwnd))) | |
if __name__ == "__main__": | |
results = [] | |
top_windows = [] | |
win32gui.EnumWindows(windowEnumerationHandler, top_windows) | |
for i in top_windows: | |
if "gunz" in i[1].lower(): | |
print (i) | |
win32gui.ShowWindow(i[0],5) | |
win32gui.SetForegroundWindow(i[0]) | |
break | |
class _State(object): pass | |
import platform as _platform | |
counter = 0 | |
while 1: | |
keyboard.add_hotkey('1', lambda: keyboard.send('space')) | |
time.sleep(0.100) | |
keyboard.add_hotkey('1', lambda: mouse.double_click(button='left')) | |
time.sleep(0.100) | |
keyboard.add_hotkey('1', lambda: keyboard.press_and_release('SHIFT')) | |
time.sleep(0.200) | |
keyboard.add_hotkey('1', lambda: mouse.double_click(button='left')) | |
time.sleep(0.200) | |
keyboard.add_hotkey('1', lambda: keyboard.press_and_release('SHIFT')) | |
time.sleep(0.500) | |
keyboard.wait('1') | |
counter += 1 | |
print('You have done', counter, 'Butterflys...') | |
for proc in psutil.process_iter(): | |
if proc.name() == "Gunz.exe": | |
taskid = proc.pid | |
(taskid) | |
print("Found Gunz.exe, script will start...") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
☁️ If someone can test this on their end, i'd appreciate it. 🙏 😄