WoodenFloorBoard
New Member
- Messages
- 16
- Reaction score
- 9
- Points
- 3
Hi guys! I decided since I released an external hack for this game, I might aswell test my skills and try and make it into internal. So far I've only got the fly hack made which works but can be buggy. I'll also update the source when I work on adding more options, etc...
NOTE: I've updated the source with some minor changes. Added a player struct for neatness. I also do realize the Unlimited Ammo is only working for one gun and I'm too lazy to find the ammo addresses of all the weapons.
I'll also accept suggestions to help aid/improve my hacks/mods! Hope y'all enjoy!
Code:
#include <Windows.h>
#include <iostream>
using namespace std;
bool ammoStatus = false;
struct MyPlayer_t
{
DWORD myX = 0x13255C8;
DWORD myY = 0x13255CC;
DWORD myZ = 0x13255C4;
DWORD myFOV = 0xCBAF114;
DWORD primaryAmmo = 0x1325940;
DWORD secondaryAmmo = 0x13259BC;
}Self;
DWORD ayylmao()
{
*(float*)Self.myFOV = 90.0f; //Promod. CoD 4 only allowed upto 80 for max F.O.V :(
while (true)
{
*(DWORD*)Self.primaryAmmo = 6969; //Unlimited Primary
*(DWORD*)Self.secondaryAmmo = 6969; //Unlimited Secondary
if (GetAsyncKeyState(VK_SPACE))
{
float newY = *(float*)Self.myY += 0.001;
*(float*)Self.myY = newY;
}
}
}
BOOL WINAPI DllMain(HINSTANCE hModule, DWORD dwReason, LPVOID lpReserved)
{
switch (dwReason)
{
case DLL_PROCESS_ATTACH:
CreateThread(0, 0, (LPTHREAD_START_ROUTINE)ayylmao, 0, 0, 0);
MessageBoxA(NULL, "Hold [SPACE] to Fly.", "AYYLMAO", MB_OK);
}
return TRUE;
}
NOTE: I've updated the source with some minor changes. Added a player struct for neatness. I also do realize the Unlimited Ammo is only working for one gun and I'm too lazy to find the ammo addresses of all the weapons.
I'll also accept suggestions to help aid/improve my hacks/mods! Hope y'all enjoy!
Last edited: