Cleaned Up... To a certain Standpoint...
Code:
#include <Windows.h>
#define Num_Max 2
void t()
{
DWORD Cshell;
while (!(Cshell = (DWORD)GetModuleHandle("Cshell.dll")))
{
Sleep(100);
}
PDWORD p = (PDWORD)(Cshell+0x311A48); //Base Address aka Start Address of Cshell // Oops
while (!(*p)) Sleep(100);
if (GetAsyncKeyState(VK_F9)) //Get Sync Key State, With a Virtual Key Representing the Key. You can Also use Hexidecimal VK's
{
for (int i=0;i<440;i++)
{
PDWORD pp = (PDWORD)(*p+0x4*i);
if (*pp)
{
PFLOAT pf = (PFLOAT)(*pp+0x2420); // Offset
if (*pf) *pf = Num_Max;
}
}
}
MessageBeep(MB_ICONEXCLAMATION);
}
void s()
{
HWND hWnd;
while (!(hWnd = FindWindow("CrossFire", 0))) { Sleep(100); }
SetTimer(hWnd, 99, 80, (TIMERPROC)t);
}
BOOL APIENTRY DllMain(HMODULE HMODULE_, DWORD REASON_, LPVOID UseLess_)
{
if (REASON_ == DLL_PROCESS_ATTACH)
{
CreateThread(0, 0, (LPTHREAD_START_ROUTINE)s, 0, 0, 0);
}
if (REASON_ == DLL_PROCESS_DETACH)
{
MessageBoxA(0, "Cleaned up by Pops, SpoonFed PWN", "Successfully Injected", 0);
}
CreateThread(0, 0, (LPTHREAD_START_ROUTINE)s, 0, 0, 0);
return TRUE;
}