So my question is as follows: I have a program Main.exe(wich starts the game), i have a dll attached to it so i can load some functions. I have another program called StartGame.exe(launcher+autoupdater), now the question is, how can i make a function to make sure that Main.exe is runned only from StartGame.exe when the client pressed START? I cannot modify either Main.exe, nor StartGame.exe... I have made some simple check as follows:
if(FindWindow(NULL,"LiveMU") == NULL) //LiveMU is the name of window StartGame.exe
{
MessageBoxA(0,"English: Please use the Launcher! \nRomanian: Va rugam sa folositi Launcher-ul!", TitleMsgBox,MB_ICONERROR);
ExitProcess(0);
}
The problem is, that if they open startgame.exe, and leave it in the tray, they can load Main.exe without a problem. The MAIN problem is, if i cannot protect somehow Main.exe from launching without the launcher, clients/players use a cheat program loading Main.exe(injecting it or something, i don't really know as it just disappears and i can't find it)
LE: I cannot add command line arguments to StartGame.exe because it`s heavy protected...