Kiwi Clicker

Kiwi Clicker

View Stats:
antiphon Aug 25, 2022 @ 10:32pm
AHK script for autoclicker
In case you didn't have one:

#MaxThreadsPerHotkey 3 ;SendMode Input ; Recommended for new scripts due to its superior speed and reliability. ;CoordMode, Mouse, Screen CoordMode, Mouse, Window SendMode Input #SingleInstance Force SetTitleMatchMode 2 #WinActivateForce SetControlDelay 1 SetWinDelay 0 SetKeyDelay -1 SetMouseDelay -1 SetBatchLines -1 ^x:: Toggle := !Toggle WindowTitle = Kiwi Clicker Loop { If (!Toggle) Break SetControlDelay -1 PostClick(1280, 800, ahk_class UnityWndClass, WindowTitle) Sleep, 1 } PostClick(x, y, class, title) { lParam := x & 0xFFFF | (y & 0xFFFF) << 16 PostMessage, 0x201, 1, %lParam%, %class%, %title% ;WM_LBUTTONDOWN PostMessage, 0x202, 0, %lParam%, %class%, %title% ;WM_LBUTTONUP }

CTRL+X toggles it on and off. You can change the "^x::" line to whatever suits your desired hotkey (^q:: would make it ctrl+q for example).

This unfortunately won't click on any specific spots unless the game is your active window and you hover the spot, but it does at least send a click "input" to the game when it's inactive (just not to any specific spot, which means if you take the archery branch, you can basically get all the "clickable" things going constantly). If you have the gun upgrade, and you alt tab while hovering the archery target, it'll keep that multiplier going up and down as the gun reloads. This has only a 1 millisecond delay between clicks, so if your system for some reason lags with this, you can adjust it up higher if needed.

I attempted using ControlSend and sending Spacebar with that upgrade that lets you use spacebar to click, but that didn't seem to work for me either. Feel free to post improvements if you know of any.
Last edited by antiphon; Aug 25, 2022 @ 10:35pm