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 


help with vb 2008 code for mouse control (+rep for help)

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
rayz321
Grandmaster Cheater
Reputation: 0

Joined: 17 Aug 2008
Posts: 579

PostPosted: Wed Apr 08, 2009 11:48 pm    Post subject: help with vb 2008 code for mouse control (+rep for help) Reply with quote

ok i need a code to make the mouse click xy coordinates but how do i do it and i did google it already so dont say that ok +rep if you help
_________________
Views and counting since 9/14/09

Make Money for surfing ads!
Back to top
View user's profile Send private message
hcavolsdsadgadsg
I'm a spammer
Reputation: 26

Joined: 11 Jun 2007
Posts: 5801

PostPosted: Thu Apr 09, 2009 1:44 am    Post subject: Reply with quote

Get/SetCursorPos + SendInput
Back to top
View user's profile Send private message
rayz321
Grandmaster Cheater
Reputation: 0

Joined: 17 Aug 2008
Posts: 579

PostPosted: Thu Apr 09, 2009 9:41 am    Post subject: Reply with quote

could you explain better Embarassed
_________________
Views and counting since 9/14/09

Make Money for surfing ads!
Back to top
View user's profile Send private message
TraxMate
Master Cheater
Reputation: 0

Joined: 01 Mar 2008
Posts: 363

PostPosted: Thu Apr 09, 2009 9:46 am    Post subject: Reply with quote

You use SetCursorPos() to move the cursor then you use GetCursorPos() to get the mouse current position and use SendInput to click.
Back to top
View user's profile Send private message
Slugsnack
Grandmaster Cheater Supreme
Reputation: 71

Joined: 24 Jan 2007
Posts: 1857

PostPosted: Thu Apr 09, 2009 9:55 am    Post subject: Reply with quote

or simply mouse_event()
Back to top
View user's profile Send private message
Jorg hi
I post too much
Reputation: 7

Joined: 24 Dec 2007
Posts: 2276
Location: Minnesota

PostPosted: Fri Apr 10, 2009 10:57 am    Post subject: Reply with quote

Lol its my rep Razz

To set X & Y for forum. Unless you want an API... use SetCursorPosition
Code:
ntrol.Cursor.Position= New Point(X,Y)

_________________
CEF will always stay alive.
Back to top
View user's profile Send private message
rayz321
Grandmaster Cheater
Reputation: 0

Joined: 17 Aug 2008
Posts: 579

PostPosted: Fri Apr 10, 2009 5:23 pm    Post subject: Reply with quote

GGoogle wrote:
Lol its my rep Razz

To set X & Y for forum. Unless you want an API... use SetCursorPosition
Code:
ntrol.Cursor.Position= New Point(X,Y)
wil that make it click there too or just go there?
_________________
Views and counting since 9/14/09

Make Money for surfing ads!
Back to top
View user's profile Send private message
Deve
Expert Cheater
Reputation: 0

Joined: 20 Jan 2007
Posts: 245
Location: Stockholm, Sweden

PostPosted: Fri Apr 10, 2009 6:38 pm    Post subject: Reply with quote

It will only move it.
_________________


Leecher.
Back to top
View user's profile Send private message MSN Messenger
rayz321
Grandmaster Cheater
Reputation: 0

Joined: 17 Aug 2008
Posts: 579

PostPosted: Fri Apr 10, 2009 6:45 pm    Post subject: Reply with quote

develito wrote:
It will only move it.
is there a way i can make it click ?
_________________
Views and counting since 9/14/09

Make Money for surfing ads!
Back to top
View user's profile Send private message
hcavolsdsadgadsg
I'm a spammer
Reputation: 26

Joined: 11 Jun 2007
Posts: 5801

PostPosted: Fri Apr 10, 2009 6:54 pm    Post subject: Reply with quote

rayz321 wrote:
develito wrote:
It will only move it.
is there a way i can make it click ?


How about you read your own thread?
Back to top
View user's profile Send private message
talkerzero
Grandmaster Cheater
Reputation: 1

Joined: 24 Jul 2008
Posts: 560
Location: California

PostPosted: Fri Apr 10, 2009 8:29 pm    Post subject: Reply with quote

Code:
Private Declare Sub SetCursorPos Lib "user32" (ByVal x as Integer, y as Integer)
Private Declare Sub mouse_event Lib "user32" (ByVal a as Long, b as Long, c as Long, d as Long, e as Long)
Private Const MOUSEEVENTF_LEFTDOWN = 2
Private Const MOUSEEVENTF_LEFTUP = 4

Code:
SetCursorPos( 100, 200 ) 'change 100 and 200 to x/y values
mouse_event( MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0 )
mouse_event( MOUSEEVENTF_LEFTUP, 0, 0, 0, 0 )

Shocked
Back to top
View user's profile Send private message Visit poster's website
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