Solved Error with random reason

Hexui Undetected CSGO Cheats PUBG Accounts

meneadeszz

Newbie
Full Member
Jun 1, 2012
6
232
0
Heuy

I'm watching fleeps tutorials and im finishd making the dll injector script thing which finishis in episod 12 i think here it is.
#include <iostream>
#include <Windows.h>
#include <TlHelp32.h>

using namespace std;
bool InjectDll(DWORD ProcessID);

char FileToInject[] ="AcubeDll.dll";
char ProcessName[] = "ac_client.exe";
typedef HINSTANCE (*fpLoadLibrary)(char*);

int main()
{

DWORD processID = NULL;
PROCESSENTRY32 pe32 = {sizeof(PROCESSENTRY32)};
HANDLE hProcSnap;

while(!processID)
{
system("CLS");

std::cout << "Searching for " << ProcessName << "..." << std::endl;
std::cout << "Make sure your game is running" << std::endl;
std::cout << "Hello" << std::endl;
hProcSnap = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0);

if(Process32First(hProcSnap, &pe32))
{
do
{
if(!strcmp(pe32.szExeFile, ProcessName))
{
processID = pe32.th32ProcessID;
break;
}
}
while(Process32Next(hProcSnap, &pe32));
}

Sleep(1000);

}
while(!InjectDll(processID))

system("CLS");
std::cout << "DLL failed to inject" << endl;
Sleep(1000);
std::cout << "Dll succsesfully injected" << endl;
std::cout << "Closing injector in 5 seconds" << endl;


CloseHandle(hProcSnap);
Sleep(5000);

return 0;

}

bool InjectDLL(DWORD ProcessId)
{
HANDLE hProc;
LPVOID paraAddr;

HINSTANCE hDLL = LoadLibrary("KERNEL32");

fpLoadLibrary LoadLibraryAddr = (fpLoadLibrary)GetProcAddress(hDLL, "LoadLibraryA");

hProc = OpenProcess (PROCESS_ALL_ACCESS, false, ProcessId);

char dllPath[250] = "C:\\hacks\\";

strcat_s(dllPath, FileToInject);

paraAddr = VirtualAllocEx(hProc, 0, strlen(dllPath)+1, MEM_COMMIT, PAGE_READWRITE);

bool memoryWritten = WriteProcessMemory(hProc, paraAddr, dllPath, strlen(dllPath)+1, 0);

CreateRemoteThread(hProc, 0, 0,(LPTHREAD_START_ROUTINE)LoadLibraryAddr, paraAddr,0, 0);

CloseHandle(hProc);

return memoryWritten ;

}

But this is the error


1>------ Build started: Project: Dll Injection, Configuration: Debug Win32 ------
1>Main.obj : error LNK2019: unresolved external symbol "bool __cdecl InjectDll(unsigned long)" (?InjectDll@@YA_NK@Z) referenced in function _main
1>C:\Users\Manuel\Desktop\AImbotC++\Dll Injection\Debug\Dll Injection.exe : fatal error LNK1120: 1 unresolved externals
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
 

Rake

I'm not your friend
Administrator
Jan 21, 2014
13,047
79,068
2,471
in your hack properties -> character set :- put Use Multi-Byte Character Set

You must define InjectDLL above your other functions.
 
Last edited:

meneadeszz

Newbie
Full Member
Jun 1, 2012
6
232
0
But i did everythin like fleeps tutorial but he didint get the error and you know how i need to fix this
 
S

Sleinzel

meneadeszz said:
But i did everythin like fleeps tutorial but he didint get the error and you know how i need to fix this
Did you download a project provided by fleep? Or did you start on your own from scratch?
 

meneadeszz

Newbie
Full Member
Jun 1, 2012
6
232
0
What doe you mean exaclt but thats tutorial is for an injecter thats not realy needed for me so you can close this thread
 
Community Mods