I think you need to put { or } after one Hotkey
I THINK !!!
Im Having troubles with my Hotkey hack can you guy's Help me please?
#include <windows.h>
bool IsGameReadyForHook()
{
if( GetModuleHandleA( "d3d9.dll" ) != NULL
&& GetModuleHandleA( "ClientFX.fxd" ) != NULL
&& GetModuleHandleA( "CShell.dll" ) != NULL )
return true;
return false;
}
void PushToConsole(const char* Command) {
DWORD CNADDIE = 0x007d9200;
void* Send = ( void* )*( DWORD* )(CNADDIE);
__asm
{
push Command;
call Send;
add esp, -3-1+2+6;
}
}
void main()
{
bool hack = false;
while(true)
{
if(GetAsyncKeyState(VK_NUMPAD0) < 0){
hack = !hack;
if(hack){
PushToConsole("SkelModelStencil 1");
hack=true;
} else {
PushToConsole("SkelModelStencil 0");
hack=false;
if(GetAsyncKeyState(VK_NUMPAD1) < 0){
hack = !hack;
if(hack){
PushToConsole("CamMaxPosYOffset 200.000000 1");
hack=true;
} else {
PushToConsole("CamMaxPosYOffset 200.000000 0");
hack=false;
if(GetAsyncKeyState(VK_NUMPAD2) < 0){
hack = !hack;
if(hack){
PushToConsole("FogEnable 1");
hack=true;
} else {
PushToConsole("FogEnable 0");
hack=false;
if(GetAsyncKeyState(VK_NUMPAD3) < 0){
hack = !hack;
if(hack){
PushToConsole("ModelDebug_DrawBoxes 1");
hack=true;
} else {
PushToConsole("ModelDebug_DrawBoxes 0");
hack=false;
if(GetAsyncKeyState(VK_NUMPAD4) < 0){
hack = !hack;
if(hack){
PushToConsole("drawguns 1");
hack=true;
} else {
PushToConsole("drawguns 0");
hack=false;
if(GetAsyncKeyState(VK_NUMPAD5) < 0){
hack = !hack;
if(hack){
PushToConsole("ShowFps 1");
hack=true;
} else {
PushToConsole("ShowFps 0");
hack=false;
if(GetAsyncKeyState(VK_NUMPAD6) < 0){
hack = !hack;
if(hack){
PushToConsole("ActivationDistance 999999 1");
hack=true;
} else {
PushToConsole("ActivationDistance 999999 0");
hack=false;
if(GetAsyncKeyState(VK_NUMPAD7) < 0){
hack = !hack;
if(hack){
PushToConsole("WireframeModels 1");
hack=true;
} else {
PushToConsole("WireframeModels 0");
hack=false;
if(GetAsyncKeyState(VK_NUMPAD8) < 0){
hack = !hack;
if(hack){
PushToConsole("ShowHitSphere 0.000000");
hack=true;
} else {
PushToConsole("ShowHitSphere 1.000000");
hack=false;
}
Sleep(200);
}
}
}
DWORD WINAPI dwHackThread(LPVOID)
;
while( !IsGameReadyForHook() )
Sleep(100);
main();
return 0;
}
BOOL WINAPI DllMain ( HMODULE hDll, DWORD dwReason, LPVOID lpReserved )
{
DisableThreadLibraryCalls(hDll);
if ( dwReason == DLL_PROCESS_ATTACH )
{
CreateThread(NULL, NULL, dwHackThread, NULL, NULL, NULL);
}
return TRUE;
}
Error:
------ Build started: Project: HotBase, Configuration: Release Win32 ------
Base.cpp
Base.cpp(119): error C2562: 'main' : 'void' function returning a value
Base.cpp(20) : see declaration of 'main'
Base.cpp(122): error C2601: 'DllMain' : local function definitions are illegal
Base.cpp(79): this line contains a '{' which has not yet been matched
Base.cpp(130): fatal error C1075: end of file found before the left brace '{' at 'Base.cpp(79)' was matched
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
I think you need to put { or } after one Hotkey
I THINK !!!
check your braces. you forgot to close one or forgot to open one or something. thats what the first error is, and probably the rest.
EDIT: it doesnt look like you closed any of your else functions
You need different bool variables for each hack.
i used to ge tthis problem.. listen to what thse ppl r saying and on the lefthand column.. look for dllmain.cpp. Delete that. It shud work.
did you ever learn c++?
whats your .h file say?
that could be your issue.
Need Help With Coding or Something??? MSN me
zmansquared@hotmail.com
I am the one and only Microsoft Fag!!!
Quote:
Originally Posted by Arhk
All games should be hacked, if we don't do it someone else will. Hackers force the progress, of better programming methods.
~
Take this Pic everyone!
next-
How come no one knows how to use braces?
@OP you have to close all of you if/else statements. Try looking for brackets that you forgot to close.
u use CoderNever base he but errors in the base so no1 will copy & paste learn c++ or google the errors that is how I fix mine errors.
ok here is the Hack Source I been working on but i took out the hot keys they are auto on
and i put easy to fix errors. credit to CoderNever for base and BloodSkin for help: this hack is detected for me.
__________________________________________________ ________________________
#include <windows.h>
bool IsGameReadyForHook()
{
if( GetModuleHandleA( "d3d9.dll" )!= NULL
&& GetModuleHandleA( "ClientFX.fxd" )!= NULL
&& GetModuleHandleA( "CShell.dll" )!= NULL )
return true;
return false;
}
void PushToConsole(const char* Command) {
DWORD CNADDIE =
void* Send = ( void* )*( DWORD* )(CNADDIE);
__asm
{
push Command;
call Send;
add esp,
}
}
void main();
{
while(true);
PushToConsole("SkelModelStencil 1");
PushToConsole("ModelDebug_DrawBoxes 1")
PushToConsole("WeaponSway 0");
PushToConsole("PerturbRotationEffect 0.000000");
PushToConsole("PerturbIncreaseSpeed 0.000000");
PushToConsole("PerturbWalkPercent 0.000000");
PushToConsole("PerturbFiringIncreaseSpeed 0.000000");
memcpy((LPVOID)0x3741A550, "\x90\x90\x90", 3);
memcpy((LPVOID)0x3740AA99, "\x90\x90\x90", 3);
memcpy((LPVOID)0x3741A564, "\x90\x90\x90", 3);
memcpy((LPVOID)0x3741A567, "\x90\x90\x90", 3);
memcpy((LPVOID)0x3741A570, "\x90\x90\x90", 3);
memcpy((LPVOID)0x37466264, "\x90\x90\x90\x90\x90\x90", 6);
}
}
DWORD WINAPI dwHackThread(LPVOID){
while( !IsGameReadyForHook())
Sleep(100);
main();
return 0;
}
BOOL WINAPI DllMain ( HMODULE hDll, DWORD dwReason, LPVOID lpReserved )
{
DisableThreadLibraryCalls(hDll);
if ( dwReason == DLL_PROCESS_ATTACH )
{
CreateThread(NULL, NULL, dwHackThread, NULL, NULL, NULL);
}
return TRUE;
}
Last edited by EDWINSEE; 07-24-2010 at 06:59 PM.