[HELP] Source Code Help
here is my source code... None of my hacks even work so, can someone enlighten me?
Can anyone help?
And if ANYONE takes an idea from me, please credit
Code:
#include <Windows.h>
void __cdecl PushToConsole( const char* szCommand )
{
DWORD *LTClient = ( DWORD* )( 0x3778CFB0 );
void* CONoff = ( void* )*( DWORD* )( *LTClient + 0x208 );
__asm
{
push szCommand;
call CONoff;
add esp, 4;
}
}
bool IsGameReadyForHook()
{
if( GetModuleHandleA( "d3d9.dll" ) != NULL
&& GetModuleHandleA( "ClientFX.fxd" ) != NULL
&& GetModuleHandleA( "CShell.dll" ) != NULL )
return true;
return false;
}
void main()
{
while (!IsGameReadyForHook()){
Sleep(200);
}
bool spread = false;
bool NxChams = false;
bool Fps = false;
bool speed = false;
bool hover = false;
bool tracers = false;
bool flyer = false;
bool distact = false;
bool suicide = false;
bool VUp = false;
bool VDown = false;
bool VFor = false;
bool VBack = false;
bool VDir1 = false;
bool VDir2 = false;
bool ghost = false;
bool glitcher = false;
bool nogun = false;
bool weaponsway = false;
while (true)
PushToConsole("PerturbRotationEffect 0.000000" );
PushToConsole("PerturbIncreaseSpeed 0.000000" );
PushToConsole("PerturbWalkPercent 0.000000" );
PushToConsole("PerturbFiringIncreaseSpeed 0.000000" );
PushToConsole("PerturbRecoil 0.000000" );
PushToConsole("FireMovePerturb 0.000000" );
PushToConsole("ZoomedFireMoveDuckPerturb 0.000000" );
PushToConsole("ZoomedFireMovePerturb 0.000000" );
PushToConsole("ZoomedFireDuckPerturb 0.000000" );
if(GetAsyncKeyState(VK_NUMPAD1)&1)
{
if(NxChams = !NxChams)
{
PushToConsole ("SkelModelStencil 1");
NxChams = 1;
}
else
{
PushToConsole ("SkelModelStencil 0");
NxChams = 0;
Sleep(200);
}
if(GetAsyncKeyState(VK_NUMPAD2)&1)
{
if(speed = !speed)
{
PushToConsole ("BaseMoveAccel 3000.000000");
PushToConsole ("StartAccel 3000.000000");
PushToConsole ("MaxAccel 3000.000000");
PushToConsole ("AccelInc 3000.000000");
PushToConsole ("FRunVel 3000.000000");
PushToConsole ("BRunVel 3000.000000");
PushToConsole ("SRunVel 30000.000000");
PushToConsole ("DuckVel 3000.000000");
speed = 1;
}
else
{
PushToConsole ("BaseMoveAccel 3000.000000");
PushToConsole ("StartAccel 500.000000");
PushToConsole ("MaxAccel 3000.000000");
PushToConsole ("AccelInc 6000.000000");
PushToConsole ("WalkVel 70.000000") ;
PushToConsole ("FRunVel 285.000000");
PushToConsole ("BRunVel 285.000000");
PushToConsole ("SRunVel 285.000000");
PushToConsole ("DuckVel 50.000000");
speed = 0;
Sleep (200);
}
if(GetAsyncKeyState(VK_NUMPAD3)&1)
{
if(hover = !hover)
{
PushToConsole ("PlayerGravity 0");
PushToConsole ("PlayerVelocity 0");
hover = 1;
}
else
{
PushToConsole ("PlayerGravity 1");
PushToConsole ("PlayerVelocity 1");
hover = 0;
Sleep(200);
}
if(GetAsyncKeyState(VK_NUMPAD4)&1)
{
if(tracers = !tracers)
{
PushToConsole("ShowFirePath 1" );
tracers = 1;
Sleep(200);
}
else
{
PushToConsole("ShowFirePath 0" );
tracers = 0;
Sleep(200);
}
if(GetAsyncKeyState(VK_NUMPAD7)<0)
{
if(flyer = !flyer)
{
PushToConsole("PlayerGravity -800");
flyer = 1;
Sleep(200);
}
else
{
PushToConsole("PlayerGravity 800");
flyer = 0;
Sleep(200);
}
if(GetAsyncKeyState(VK_NUMPAD5)&1)
{
if(distact = !distact)
{
PushToConsole("ActivationDistance 999999");
distact = 1;
Sleep(200);
}
else
{
PushToConsole("ActivationDistance 100000");
distact = 0;
Sleep(200);
}
if(GetAsyncKeyState(VK_NUMPAD6)<0)
{
if(suicide = !suicide)
{
PushToConsole("FragSelf 1");
suicide = 1;
Sleep(200);
}
else
{
PushToConsole("FragSelf 0");
suicide = 0;
Sleep(200);
}
}
if(GetAsyncKeyState(VK_NUMPAD8)&1)
{
if(glitcher = !glitcher)
{
PushToConsole ("BaseMoveAccel 9000.000000");
PushToConsole ("StartAccel 9000.000000");
PushToConsole ("MaxAccel 9000.000000");
PushToConsole ("AccelInc 9000.000000");
PushToConsole ("FRunVel 9000.000000");
PushToConsole ("BRunVel 9000.000000");
PushToConsole ("SRunVel 90000.000000");
PushToConsole ("DuckVel 9000.000000");
glitcher = 1;
}
else
{
PushToConsole ("BaseMoveAccel 3000.000000");
PushToConsole ("StartAccel 500.000000");
PushToConsole ("MaxAccel 3000.000000");
PushToConsole ("AccelInc 6000.000000");
PushToConsole ("WalkVel 70.000000") ;
PushToConsole ("FRunVel 285.000000");
PushToConsole ("BRunVel 285.000000");
PushToConsole ("SRunVel 285.000000");
PushToConsole ("DuckVel 50.000000");
glitcher = 0;
Sleep (200);
}
if(GetAsyncKeyState(VK_F12)&1)
{
int progressor = 10;
int control = 10;
if(GetAsyncKeyState(VK_OEM_PLUS)&1)
{
if(VUp = !VUp)
{
PushToConsole("CamMaxPosYOffset 50.000000 "+ progressor);
VUp = 1;
Sleep(200);
}
else
{
PushToConsole("CamPosYOffset 000.000000");
VUp = 0;
Sleep(200);
}
}
if(GetAsyncKeyState(VK_OEM_MINUS)&1)
{
if(VDown = !VDown)
{
PushToConsole("CamMaxYOffSet -50.000000 " + progressor);
VDown = 1;
Sleep(200);
}
else
{
PushToConsole("CamMaxYOffSet 000.000000 ");
VDown = 0;
Sleep(200);
}
}
if(GetAsyncKeyState(0x49)&1)
{
if(VFor = ! VFor)
{
while(true)
PushToConsole("CamMaxZOffSet 50.000000 " + progressor);
VFor = 1;
Sleep(200);
}
else
{
PushToConsole("CamMaxOffSet 000.000000");
VFor = 0;
Sleep(200);
}
if(GetAsyncKeyState(0x4B)&1)
{
while(true)
PushToConsole("CamMaxZOffSet -50.000000 " - progressor);
VBack = 1;
Sleep(200);
}
else
{
PushToConsole("CamMaxZOffSet 000.000000");
VBack = 0;
Sleep(200);
}
if(GetAsyncKeyState(0x4A)&1)
{
while(true)
PushToConsole("CamMaxXOffSet 50.000000 " - progressor);
VDir1 = 1;
Sleep(200);
}
else
{
PushToConsole("CamMaxXOffSet 000.000000");
VDir1 = 0;
Sleep(200);
}
if(GetAsyncKeyState(0x4C)&1)
{
while(true)
PushToConsole("CamMaxXOffSet -50.000000 " - progressor);
VDir2 = 1;
Sleep(200);
}
else
{
PushToConsole("CamMaxXOffSet 000.000000");
VDir2 = 0;
Sleep(200);
}
ghost = 1;
}
else
{
PushToConsole("CamMaxXOffSet 000.000000");
PushToConsole("CamMaxYOffSet 000.000000");
PushToConsole("CamMaxZOffSet 000.000000");
}
if(GetAsyncKeyState(VK_NUMPAD8)&1)
{
if(nogun = !nogun)
{
PushToConsole("drawguns 1");
nogun = true;
Sleep(200);
}
else
{
PushToConsole("drawguns 0");
nogun = false;
Sleep(200);
}
}
}
}
}
}
}
}
}
}
}
BOOL WINAPI DllMain ( HMODULE hDll, DWORD dwReason, LPVOID lpReserved )
{
DisableThreadLibraryCalls(hDll);
if ( dwReason == DLL_PROCESS_ATTACH )
//system("http://www.mpgh.net/");
{
if( MessageBox(0, TEXT("This is my hack in alpha version, credits go to void, Finish, Ac1d Burn... No Spread is auto activated, and the hotkeys are from 1-3 Enjoy\n\n Wanna inject the hack?"), TEXT("Bonsai_Tree Hacks"), MB_YESNO)==IDYES){
#ifdef LOG
DeleteFile(LogPath);
#endif
}else{
//Hack Do not Attach
MessageBox(0, TEXT("Bonsa_Tree Hacks"), TEXT("Bonsai_Tree Hacks"), MB_ICONINFORMATION);
}
}
return TRUE;
}
And if ANYONE takes an idea from me, please credit
I need help working this because it doesn't give ANYTHING for any of the hotkeys for windows xp, and 7


