Errors about a process in C++ Project
hey i have a code for a dll hack but if i whant to compile it i get 8 errors 0 warnings - errors:
Code:
--------------------Configuration: HM - Win32 Debug--------------------
Compiling...
main.cpp
C:\Documents and Settings\Luc\Bureaublad\OP7 Teleport\HM\main.cpp(44) : error C2143: syntax error : missing ';' before '}'
C:\Documents and Settings\Luc\Bureaublad\OP7 Teleport\HM\main.cpp(44) : error C2143: syntax error : missing ';' before '}'
C:\Documents and Settings\Luc\Bureaublad\OP7 Teleport\HM\main.cpp(44) : error C2143: syntax error : missing ';' before '}'
C:\Documents and Settings\Luc\Bureaublad\OP7 Teleport\HM\main.cpp(46) : error C2143: syntax error : missing ';' before '}'
C:\Documents and Settings\Luc\Bureaublad\OP7 Teleport\HM\main.cpp(46) : error C2143: syntax error : missing ';' before '}'
C:\Documents and Settings\Luc\Bureaublad\OP7 Teleport\HM\main.cpp(46) : error C2143: syntax error : missing ';' before '}'
C:\Documents and Settings\Luc\Bureaublad\OP7 Teleport\HM\main.cpp(50) : error C2143: syntax error : missing ';' before '{'
C:\Documents and Settings\Luc\Bureaublad\OP7 Teleport\HM\main.cpp(50) : error C2447: missing function header (old-style formal list?)
Error executing cl.exe.
main.obj - 8 error(s), 0 warning(s)
The Project Code
Code:
#include <windows.h>
#include <stdio.h>
#include <iostream>
#include <conio.h>
#include <string>
#include <fstream>
#include <float.h>
using namespace std;
DWORD WINAPI LoopFunction( LPVOID lpParam )
{
BYTE StandingON[] = {0x8B, 0x02, 0x90};
BYTE CrouchingON[] = {0x8B, 0x11, 0x90};
BYTE StandingOFF[] = {0x8B, 0x42, 0x4C};
BYTE CrouchingOFF[] = {0x8B, 0x51, 0x50};
bool Crosshair = false;
HANDLE operation7 = GetCurrentProcess();
while(1) {
if (GetAsyncKeyState(VK_F3)&0x80000) {
if (Crosshair == true) {
WriteProcessMemory(operation7, (void*)(0x05E2C88), &StandingOFF, 3, 0);
WriteProcessMemory(operation7, (void*)(0x05E2C93), &CrouchingOFF, 3, 0);
Crosshair = false;
}
else if( Crosshair == false) {
WriteProcessMemory(operation7, (void*)(0x05E2C88), &StandingON, 3, 0);
WriteProcessMemory(operation7, (void*)(0x05E2C93), &CrouchingON, 3, 0);
Crosshair = true;
}
}
}
//some CPU relief
Sleep(200);
return 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;
}
What is wrong?
PS:Using Microsoft visual c++ 6.0 no eclipse

Its from a tutorial (the code)
TY luckie12
Typical noob. Putting your sleep function outside an infinite loop >_>.... check your brackets. You've got to many. Also your GetAsyncKeyState() will never work because its should be 0x8000. and go learn C++, cuz damn.
I would like to talk to the ****** who made this code, but not you, goddamn leecher. This is what happens when leechers teach other leechers how to code. Try injecting some shit like this and you'll be calling WPM a 100 times a second. which will cause huge amounts of lag. Not only that, but you will have to hold the key down. and even when ur not holding it your liable to crash the system. And if you don't wait for the right modules to load this will probably just crash on injection.
idk, maybe some coder was just screwing with you nubs. In that case. good for him.