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 


Virtual Keys Questions... yes another delphi question O_o

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
Symbol
I'm a spammer
Reputation: 0

Joined: 18 Apr 2007
Posts: 5094
Location: Israel.

PostPosted: Sun Jul 22, 2007 3:10 am    Post subject: Virtual Keys Questions... yes another delphi question O_o Reply with quote

there is the key check:
Odd(GetAsyncKeyState(vKey));

So, how can i make an event that press that key?
second question is what is the Odd for? is this makes the check?
like if ill change it to something else will it make a button press event?
or is the GetAsyncKeyState checks if the key was pressed?
so change it to...? so it'll make a key press event..?

thx Rolling Eyes
Back to top
View user's profile Send private message
UnLmtD
Grandmaster Cheater
Reputation: 0

Joined: 13 Mar 2007
Posts: 894
Location: Canada

PostPosted: Sun Jul 22, 2007 3:33 am    Post subject: Re: Virtual Keys Questions... yes another delphi question O_ Reply with quote

Symbol wrote:

So, how can i make an event that press that key?


I recommend SendInput/SendMessage (Depends on what you want to do)

Quote:
Second question is what is the Odd for? is this makes the check?

The Odd function returns true if the given Number is odd. So basically it checks if it's pressed or not. Never used since it's not needed in C all we do is (GetAsyncKeyState(VK_F5) and (!GetAsyncKeyState(VK_F5) Razz

_________________
Back to top
View user's profile Send private message
Symbol
I'm a spammer
Reputation: 0

Joined: 18 Apr 2007
Posts: 5094
Location: Israel.

PostPosted: Sun Jul 22, 2007 4:38 am    Post subject: Reply with quote

like if the given number is 5 its false its if its z0mgArandomNumer its very odd O_o
thx
whats (!GetAsyncKeyState?) its the same like normal?
Back to top
View user's profile Send private message
UnLmtD
Grandmaster Cheater
Reputation: 0

Joined: 13 Mar 2007
Posts: 894
Location: Canada

PostPosted: Sun Jul 22, 2007 4:47 am    Post subject: Reply with quote

Symbol wrote:

whats (!GetAsyncKeyState(VK_F6)) its the same like normal?


Means that F6 has not been pressed. But that's in C, I don't know if you can do that in Delphi.

Offtopic: Damn it corner store is closed and opens only at 8:30. And I need a energy drink, didn't sleep all night =\

_________________
Back to top
View user's profile Send private message
Kevin
Grandmaster Cheater Supreme
Reputation: 0

Joined: 07 Mar 2007
Posts: 1139
Location: Spiderman-World

PostPosted: Sun Jul 22, 2007 5:09 am    Post subject: Reply with quote

Example: A Autoclicker with GetAsyncKeyState

odd means if its pressed once. So if you press once, the autoclicker goes once. Therefor you need 2 timers, 1 for the procedure of it, and one for the GetAsyncKeyState which disables/enables the timer, with the procedure óf the autoclicker on it so it goes all the time, until the button is pressed again.
understand it? i had few troubles understanding it...
Back to top
View user's profile Send private message MSN Messenger
Symbol
I'm a spammer
Reputation: 0

Joined: 18 Apr 2007
Posts: 5094
Location: Israel.

PostPosted: Sun Jul 22, 2007 8:33 am    Post subject: Reply with quote

i knew that... but thx =)
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
Page 1 of 1

 
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