 |
Cheat Engine The Official Site of Cheat Engine
|
| View previous topic :: View next topic |
| Author |
Message |
Anden100 Grandmaster Cheater
Reputation: 0
Joined: 20 Apr 2007 Posts: 668
|
Posted: Fri Feb 01, 2008 5:30 pm Post subject: opening .dll forms when a .dll is injected, Delphi? |
|
|
hi all,
i have made a .dll containing a form, and i can open that form using another application that i made, but now i was wondering if it is possible to execute that form as soon as my .dll is injected to an .exe file? as the title says, i am using delphi, and i made a bot that i will use for maplestory, and what i want, is to make a .dll that i can rename to "pcomdebug.dll" and then place it in my maplestory folder, and when i execute maplestory, my bot will execute aswell
is this possible? |
|
| Back to top |
|
 |
samuri25404 Grandmaster Cheater
Reputation: 7
Joined: 04 May 2007 Posts: 955 Location: Why do you care?
|
Posted: Fri Feb 01, 2008 5:43 pm Post subject: |
|
|
I'm confused as to what you want... _________________
|
|
| Back to top |
|
 |
Noz3001 I'm a spammer
Reputation: 26
Joined: 29 May 2006 Posts: 6220 Location: /dev/null
|
Posted: Fri Feb 01, 2008 5:45 pm Post subject: |
|
|
| He wants his form to sho up when his DLL is loaded. |
|
| Back to top |
|
 |
Anden100 Grandmaster Cheater
Reputation: 0
Joined: 20 Apr 2007 Posts: 668
|
|
| Back to top |
|
 |
samuri25404 Grandmaster Cheater
Reputation: 7
Joined: 04 May 2007 Posts: 955 Location: Why do you care?
|
Posted: Fri Feb 01, 2008 5:50 pm Post subject: |
|
|
The link isn't loading for me.
~~
Maybe you should just load the form after you inject it?
o_o _________________
|
|
| Back to top |
|
 |
Anden100 Grandmaster Cheater
Reputation: 0
Joined: 20 Apr 2007 Posts: 668
|
Posted: Fri Feb 01, 2008 5:55 pm Post subject: |
|
|
i was asking how to do it... like:
how do i run a form in my .dll, when the .dll is executed??? |
|
| Back to top |
|
 |
XxOsirisxX Grandmaster Cheater Supreme
Reputation: 0
Joined: 30 Oct 2006 Posts: 1597
|
Posted: Fri Feb 01, 2008 6:53 pm Post subject: |
|
|
He got a form saved at .dll, and he wants to know, if when he inject that .dll on any .exe, the form at the .dll will show up?
And also, he wants something like maplestoryacro, so, you put it on MapleStory folder with the name of "PCOMDebugger.dll" and it will auto-run.
As for the last thing, about it will run.. the answer is, yes. MapleStory runs the dll named "PCOMDebugger" when run. So, rename. _________________
|
|
| Back to top |
|
 |
lurc Grandmaster Cheater Supreme
Reputation: 2
Joined: 13 Nov 2006 Posts: 1900
|
Posted: Fri Feb 01, 2008 6:54 pm Post subject: |
|
|
its LBot, meh, w/e
btw its "PCOMDebug.dll".. dont know if PCOMDebugger also works or if it was just ur typo
anyways. on DLL_PROCESS_ATTACH create a thread that loads up your form and msg loop.
ill make you an example. hold on
Edit:
You Can try and convert it to delphi
Example (C++):
| Code: | #include <windows.h>
#define WIN32_LEAN_AND_MEAN
#pragma comment(linker, "/ENTRY:DllMain")
HINSTANCE hInstance;
HWND hWnd;
LPWSTR szClassName = L"DllNameClass";
LRESULT CALLBACK WndProc( HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam )
{
switch( Msg )
{
case WM_DESTROY:
PostQuitMessage(0);
break;
case WM_CLOSE:
PostQuitMessage(0);
break;
default:
DefWindowProc( hWnd, Msg, wParam, lParam );
}
return 0;
}
DWORD InitForm()
{
hInstance = GetModuleHandle( NULL );
MSG Msg;
WNDCLASSEX wc;
wc.cbClsExtra = 0;
wc.cbSize = sizeof(WNDCLASSEX);
wc.cbWndExtra = 0;
wc.hbrBackground = (HBRUSH)(COLOR_WINDOW+1);
wc.hCursor = LoadCursor( NULL, IDC_ARROW );
wc.hIcon = LoadIcon( NULL, IDI_APPLICATION );
wc.hIconSm = LoadIcon( NULL, IDI_APPLICATION );
wc.hInstance = hInstance;
wc.lpfnWndProc = WndProc;
wc.lpszClassName = szClassName;
wc.lpszMenuName = 0;
wc.style = 0;
if ( !RegisterClassEx( &wc ) )
{
MessageBox( NULL, L"Unable to Create Class", szError, MB_OK + MB_ICONERROR );
HMODULE hDll = GetModuleHandle( L"DllNameHere.dll" );
FreeLibraryAndExitThread( hDll, 0 );
return 0;
}
hWnd = CreateWindowEx( 0, szClassName, L"FormName", WS_OVERLAPPEDWINDOW,
CW_USEDEFAULT, CW_USEDEFAULT, 150, 150, HWND_DESKTOP, NULL, hInstance, NULL );
ShowWindow( hWnd, SW_SHOW );
UpdateWindow( hWnd );
while( GetMessage( &Msg, NULL, 0, 0 ) > 0 )
{
TranslateMessage( &Msg );
DispatchMessage( &Msg );
}
return Msg.wParam;
}
BOOL APIENTRY DllMain( HMODULE hModule, DWORD dwReason, LPVOID lpReserved )
{
switch( dwReason )
{
case DLL_PROCESS_ATTACH:
DisableThreadLibraryCalls( hModule );
CreateThread( 0, 0, (LPTHREAD_START_ROUTINE)&InitForm, 0, 0, 0 );
return TRUE;
case DLL_PROCESS_DETACH:
return TRUE;
}
return TRUE;
} |
_________________
|
|
| Back to top |
|
 |
Anden100 Grandmaster Cheater
Reputation: 0
Joined: 20 Apr 2007 Posts: 668
|
Posted: Sat Feb 02, 2008 4:14 am Post subject: |
|
|
| im gonna try converte that one, but i aint good at converting... |
|
| Back to top |
|
 |
HolyBlah Master Cheater
Reputation: 2
Joined: 24 Aug 2007 Posts: 446
|
Posted: Sat Feb 02, 2008 6:22 am Post subject: |
|
|
| Lunche the form from the DLLMain procedure. |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
|
|