Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


PostMessageX
Goto page 1, 2  Next
 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
ups2000ups
I post too much
Reputation: 0

Joined: 31 Jul 2006
Posts: 2471

PostPosted: Wed Dec 12, 2007 9:23 am    Post subject: PostMessageX Reply with quote

EDIT
First why i dont use "PostMessageX" is that it will be detected by gameguard if you compile in in delphi -.-
or the dll name so i changed it

now to the question
when i run this (timer1) it wont send the key to maple it just send it out to all other applications (expect maple)
i wondering how i fix that?

Code:

function Post1MessageX(hWnd:HWND;MSG:UINT;WPARAM:wParam;LPARAM:lParam):BOOL;
external 'PMXA.dll' name 'PostMessageX';

procedure TForm1.Timer1Timer(Sender: TObject);
var
mamma:HWND;
begin
mamma:=FindWindowA(nil,'MapleStory');
Post1MessageX(mamma, WM_KEYDOWN, ord(VK_SPACE),0);
Post1MessageX(mamma, WM_KEYUP, ord(VK_SPACE),0);

_________________
dont complain about my english...
1*1 = 2?


Last edited by ups2000ups on Thu Dec 13, 2007 3:12 pm; edited 1 time in total
Back to top
View user's profile Send private message
r34lZ
How do I cheat?
Reputation: 0

Joined: 12 Dec 2007
Posts: 4

PostPosted: Wed Dec 12, 2007 9:40 am    Post subject: Reply with quote

'MapleStory'
Is that the class name of the windows win API window?
Or is it the caption/title?

FindWindow(CLASSNAME, WINDOWTITLE);

(Delphi sucks)
Back to top
View user's profile Send private message
DeletedUser14087
I post too much
Reputation: 2

Joined: 21 Jun 2006
Posts: 3069

PostPosted: Wed Dec 12, 2007 10:02 am    Post subject: Reply with quote

delphi do sucks when it comes to wpm/hacking and stuff.

and btw use HookHop.dll, it'll work better for you, pmx.dll was just an example.
Back to top
View user's profile Send private message
ups2000ups
I post too much
Reputation: 0

Joined: 31 Jul 2006
Posts: 2471

PostPosted: Wed Dec 12, 2007 10:59 am    Post subject: Reply with quote

well still why dosent it work ......

i would be happy if i could get an exampel how to send the key into maple .. or atleast how to send they key lolz


Code:

function PostMessageX(
hWnd:HWND;
MSG:UINT;
WPARAM:wParam;
LPARAM:lParam):BOOL;stdcall;
external 'hookHop.dll' name 'hhPostMessageA';


procedure TForm1.Timer1Timer(Sender: TObject);
begin
FindWindowA('MapleStory',nil);
PostMessageX(handle, WM_KEYDOWN, VK_SPACE, 0);
end;

_________________
dont complain about my english...
1*1 = 2?
Back to top
View user's profile Send private message
HolyBlah
Master Cheater
Reputation: 2

Joined: 24 Aug 2007
Posts: 446

PostPosted: Wed Dec 12, 2007 12:10 pm    Post subject: Reply with quote

Code:
FindWindowA('MapleStory',nil);
This code is wrong, it should be like that:
Code:
FindWindow('MapleStoryClass',nil);//Find by class

or:
Code:
FindWindow(nil,'MapleStory');//Find by caption
Back to top
View user's profile Send private message
HomerSexual
Grandmaster Cheater Supreme
Reputation: 5

Joined: 03 Feb 2007
Posts: 1657

PostPosted: Wed Dec 12, 2007 3:09 pm    Post subject: Reply with quote

Also the lParam is wrong in PostMessage

Use scancodes

_________________
Back to top
View user's profile Send private message
ups2000ups
I post too much
Reputation: 0

Joined: 31 Jul 2006
Posts: 2471

PostPosted: Wed Dec 12, 2007 3:32 pm    Post subject: Reply with quote

thanks ppl but kaspersky told me to use c++ instead so i did and it was easier to understand -.-
_________________
dont complain about my english...
1*1 = 2?
Back to top
View user's profile Send private message
cicak
Expert Cheater
Reputation: 0

Joined: 02 Apr 2007
Posts: 159
Location: Cheat Engine

PostPosted: Wed Dec 12, 2007 3:57 pm    Post subject: Reply with quote

Hey guys how do i do this > e.g keydown , F4 , keyup ?

I did
Code:
keybd_event (VK_F4,0,0,0 );

But it does presses non stop

And

Code:
PostMessage(wnd, WM_KEYDOWN, VK_F4,0);
PostMessage(wnd, WM_KEYUP, VK_F4,0);

But it doesnt work

I want do something like > keydown , F4 , keyup.

I need help . Urgent ><

_________________


Last edited by cicak on Wed Dec 12, 2007 4:31 pm; edited 1 time in total
Back to top
View user's profile Send private message
ups2000ups
I post too much
Reputation: 0

Joined: 31 Jul 2006
Posts: 2471

PostPosted: Wed Dec 12, 2007 4:13 pm    Post subject: Reply with quote

cicak wrote:
Hey guys how do i do this > e.g F4 , keydown , keyup ?

I did
Code:
keybd_event (VK_F4,0,0,0 );

But it does presses non stop

And

Code:
PostMessage(wnd, WM_KEYDOWN, VK_F4,0);
PostMessage(wnd, WM_KEYUP, VK_F4,0);

But it doesnt work

I want do something like > F4 , keydown , keyup.

I need help . Urgent ><


idk but thanks =D i needed

PostMessage(wnd, WM_KEYDOWN, VK_F4,0);
PostMessage(wnd, WM_KEYUP, VK_F4,0);

not that i dident know it exist just that i dident thing about it Rolling Eyes

_________________
dont complain about my english...
1*1 = 2?
Back to top
View user's profile Send private message
cicak
Expert Cheater
Reputation: 0

Joined: 02 Apr 2007
Posts: 159
Location: Cheat Engine

PostPosted: Wed Dec 12, 2007 4:33 pm    Post subject: Reply with quote

opss i meant "keydown , F4 , keyup"

And i needed code that FindWindow by typing Edit1.

@ups2000ups : your welcome.

_________________
Back to top
View user's profile Send private message
smartz993
I post too much
Reputation: 2

Joined: 20 Jun 2006
Posts: 2013
Location: USA

PostPosted: Wed Dec 12, 2007 4:51 pm    Post subject: Reply with quote

Code:
function PostMessageX(
hWnd:HWND;
MSG:UINT;
WPARAM:wParam;
LPARAM:lParam):BOOL;stdcall;
external 'hookHop.dll' name 'hhPostMessageA';


procedure TForm1.Timer1Timer(Sender: TObject);
begin
handle:=FindWindowA('MapleStoryClass','MapleStory');
PostMessageX(handle, WM_KEYDOWN, use keycodes? (virtual keycode), need this keycode for maple (hardware keycode));
end;


That'll clear up a couple of things. That won't work tho. Talk to me later on if you need more help. MSN/AIM. I don't come to the forums too much anymore..
Back to top
View user's profile Send private message
HomerSexual
Grandmaster Cheater Supreme
Reputation: 5

Joined: 03 Feb 2007
Posts: 1657

PostPosted: Wed Dec 12, 2007 4:55 pm    Post subject: Reply with quote

Also in maplestory you DONT need WM_KEYUP only WM_KEYDOWN
_________________
Back to top
View user's profile Send private message
appalsap
Moderator
Reputation: 0

Joined: 27 Apr 2006
Posts: 6753
Location: Pakistan

PostPosted: Wed Dec 12, 2007 5:24 pm    Post subject: Reply with quote

It's bad practice not to send keyup messages, because, among other things it will screw up key combinations, certain scenarios have the program waiting for a keyup...
_________________
Back to top
View user's profile Send private message
cicak
Expert Cheater
Reputation: 0

Joined: 02 Apr 2007
Posts: 159
Location: Cheat Engine

PostPosted: Wed Dec 12, 2007 8:53 pm    Post subject: Reply with quote

help me..anyone...? Sad
_________________
Back to top
View user's profile Send private message
ups2000ups
I post too much
Reputation: 0

Joined: 31 Jul 2006
Posts: 2471

PostPosted: Wed Dec 12, 2007 9:44 pm    Post subject: Reply with quote

smartz993 wrote:
Code:
function PostMessageX(
hWnd:HWND;
MSG:UINT;
WPARAM:wParam;
LPARAM:lParam):BOOL;stdcall;
external 'hookHop.dll' name 'hhPostMessageA';


procedure TForm1.Timer1Timer(Sender: TObject);
begin
handle:=FindWindowA('MapleStoryClass','MapleStory');
PostMessageX(handle, WM_KEYDOWN, use keycodes? (virtual keycode), need this keycode for maple (hardware keycode));
end;


That'll clear up a couple of things. That won't work tho. Talk to me later on if you need more help. MSN/AIM. I don't come to the forums too much anymore..



well i just maked 1 in c++ .. but it is just bugging and stuff so i would be happy if you helped me a bit (so i could do it in delphi ...)

i dont get how i should fix this .. sorry for noobish

Code:

PostMessageX(handle, WM_KEYDOWN, use keycodes? (virtual keycode), need this keycode for maple (hardware keycode));


and this
handle:=FindWindowA('MapleStoryClass','MapleStory');

should work like this down here ?

Code:

var
handle1:HWND;
begin
handle1:=FindWindow(nil,'MapleStory');

_________________
dont complain about my english...
1*1 = 2?
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
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


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites