 |
Cheat Engine The Official Site of Cheat Engine
|
| View previous topic :: View next topic |
| Author |
Message |
Flabbergasted Expert Cheater
Reputation: 0
Joined: 11 Oct 2007 Posts: 231 Location: I have alzheimer's.
|
Posted: Sun May 04, 2008 5:22 pm Post subject: [Delphi] Questions |
|
|
Hi, it'd be great if someone could answer these questions for me.
1. How do you see the key that the user pressed. So far I got this (thanks to Snootae) and I have to do it for every key there is:
| Code: | if odd(GetAsyncKeyState($41)) then
begin
AutoAttackKey := $41//you key variable
//Turn off timer
end; |
2. Could someone tell me how to double click?
3. Could someone help me import
| Code: | ShellExecute(0,
'OPEN',
LPCSTR('http://login.ijji.com/login.nhn?m=login&memberid='+Edit1.Text+'&password='+Edit2.Text+'&nextURL=http://sfront.ijji.com/common/prelaunch.nhn?gameId=u_sf&subId='),
nil,
nil,
SW_NORMAL); |
into Webbrowser1.Navigate('');? Thanks a lot .
|
|
| Back to top |
|
 |
lurc Grandmaster Cheater Supreme
Reputation: 2
Joined: 13 Nov 2006 Posts: 1900
|
Posted: Sun May 04, 2008 6:02 pm Post subject: |
|
|
1. If you want to see if the user actually pressed it you need to notify yourself somehow, be it OutputDebugString, MessageBox, or a TextBox
2. I don't think you can do double click... but you can do normal click which is just odd(GetAsyncKeyState(VK_LBUTTON))
3. eh... make a string/PChar/PAnsiChar (whatever it is, im not a delphi coder) to store
| Code: | | LPCSTR('http://login.ijji.com/login.nhn?m=login&memberid='+Edit1.Text+'&password='+Edit2.Text+'&nextURL=http://sfront.ijji.com/common/prelaunch.nhn?gameId=u_sf&subId=') |
and then call Webbrowser1.Navigate(StringYouStoredItTo);
_________________
|
|
| Back to top |
|
 |
Snootae Grandmaster Cheater
Reputation: 0
Joined: 16 Dec 2006 Posts: 969 Location: --->
|
Posted: Mon May 05, 2008 3:24 am Post subject: |
|
|
1. Full list of VK values and hex versions, add your own notification http://delphi.about.com/od/objectpascalide/l/blvkc.htm
2. If you mean checking a double click, check for a click, then wait for another one
If you mean clicking on a window or something then
| Code: | mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0);
mouse_event(MOUSEEVENTF_LEFTUP, 0, 0, 0, 0);
GetDoubleClickTime;
mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0);
mouse_event(MOUSEEVENTF_LEFTUP, 0, 0, 0, 0); |
3. AS lurc said or just | Code: | | Webbrowser1.Navigate(LPCSTR('http://login.ijji.com/login.nhn?m=login&memberid='+Edit1.Text+'&password='+Edit2.Text+'&nextURL=http://sfront.ijji.com/common/prelaunch.nhn?gameId=u_sf&subId=')); |
_________________
|
|
| Back to top |
|
 |
Flabbergasted Expert Cheater
Reputation: 0
Joined: 11 Oct 2007 Posts: 231 Location: I have alzheimer's.
|
Posted: Mon May 05, 2008 1:35 pm Post subject: |
|
|
Thanks Lurc and Snootae . Yeah, for the first question I want to see what the user pressed and notify myself using a label, but I don't want to do it for every key. Isn't there a shorter way like - VKKeyscan?
|
|
| Back to top |
|
 |
Snootae Grandmaster Cheater
Reputation: 0
Joined: 16 Dec 2006 Posts: 969 Location: --->
|
Posted: Mon May 05, 2008 5:17 pm Post subject: |
|
|
i dont think there is, i just did it manually
_________________
|
|
| Back to top |
|
 |
Anden100 Grandmaster Cheater
Reputation: 0
Joined: 20 Apr 2007 Posts: 668
|
Posted: Mon May 05, 2008 11:29 pm Post subject: |
|
|
| Snootae wrote: | | i dont think there is, i just did it manually |
aww!, well, is there any chance, that i can have the piece of your code that checks if the key is pressed?, cas' that way seems pretty booring...
|
|
| Back to top |
|
 |
NothingToShow Grandmaster Cheater Supreme
Reputation: 0
Joined: 11 Jul 2007 Posts: 1579
|
Posted: Mon May 05, 2008 11:41 pm Post subject: |
|
|
| Anden100 wrote: | | Snootae wrote: | | i dont think there is, i just did it manually |
aww!, well, is there any chance, that i can have the piece of your code that checks if the key is pressed?, cas' that way seems pretty booring... |
If you want to check for a single key, there's this easy way:
Make a timer.
Interval on 10, Enabled to True
And in the timer code, put this:
| Code: | if odd(getasynckeystate(vk_f1)) then
begin
Showmessage('You pressed F1');
end; |
Here's the key codes
http://delphi.about.com/od/objectpascalide/l/blvkc.htm
|
|
| Back to top |
|
 |
DeletedUser14087 I post too much
Reputation: 2
Joined: 21 Jun 2006 Posts: 3069
|
Posted: Tue May 06, 2008 4:26 am Post subject: |
|
|
| Snootae wrote: | 1. Full list of VK values and hex versions, add your own notification http://delphi.about.com/od/objectpascalide/l/blvkc.htm
2. If you mean checking a double click, check for a click, then wait for another one
If you mean clicking on a window or something then
| Code: | mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0);
mouse_event(MOUSEEVENTF_LEFTUP, 0, 0, 0, 0);
GetDoubleClickTime;
mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0);
mouse_event(MOUSEEVENTF_LEFTUP, 0, 0, 0, 0); |
3. AS lurc said or just | Code: | | Webbrowser1.Navigate(LPCSTR('http://login.ijji.com/login.nhn?m=login&memberid='+Edit1.Text+'&password='+Edit2.Text+'&nextURL=http://sfront.ijji.com/common/prelaunch.nhn?gameId=u_sf&subId=')); |
|
Webbrowser component Navigate() VCL is a WideChar, not a PWChar, so it can be used as a string, the LPCSTR isn't necessary (might cause warnings).
|
|
| 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
|
|