1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
|
#include <windows.h>
#include <stdio.h>
#include <iostream>
#include <conio.h>
#include <string>
#include <fstream>
#include <float.h>
using namespace std;
void shoot()
{
mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0);
Sleep(1);
mouse_event(MOUSEEVENTF_LEFTUP, 0, 0, 0, 0);
}
DWORD WINAPI LoopFunction( LPVOID lpParam )
{
HANDLE phandle = GetCurrentProcess();
DWORD BaseAddr = (DWORD)GetModuleHandleA("Aether.exe");
DWORD painted = 0x00AE43A8;
DWORD pointer = BaseAddr+painted;
DWORD pointed;
pointed = *(DWORD*)pointer;
while(1) {
if (GetAsyncKeyState(VK_HOME)&1)
if (pointed == 1)
{
(shoot());
}
}
//some CPU relief
Sleep(0);
return 0;
}
BOOL WINAPI DllMain (HINSTANCE hModule, DWORD dwAttached, LPVOID lpvReserved)
{
if (dwAttached == DLL_PROCESS_ATTACH) {
CreateThread(NULL,0,&LoopFunction,NULL,0,NULL);
}
return 1;
}
|