Blue Eye Logo

Blue Eye Macro

Automation is freedom
It is currently Sat Sep 21, 2019 7:14 pm

All times are UTC




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: Moving Mouse to Target in 3D Game
Thanked: 0 time(s)  Unread post Posted: Sat Mar 14, 2015 6:30 pm 
New User
New User



Joined: Sat Mar 14, 2015 6:22 pm
Posts: 4
Been thanked: 1 time(s)
Has thanked: 0 time(s)
Contribution Points: 17
Hey Guys quick question,

I am trying to develop a color recognition aimbot.

Is there a method for moving a mouse in a 3D game?

With the lack of a Z coordinate my screen always goes hay-wire whenever I try to implement an aimbot using mouse.move to ....

Goal:
- If color can be found on screen
- Move color to center of the screen (my crosshair)
- Mouse.Click("Left")


Thank you,
Maikelele


Top
 Profile  
Reply with quote  
 Post subject: Re: Moving Mouse to Target in 3D Game
Thanked: 0 time(s)  Unread post Posted: Sat Mar 14, 2015 9:42 pm 
Partner / License admin
Partner / License admin
User avatar



Joined: Sun Oct 10, 2010 5:16 pm
Posts: 1934
Location: USA
Been thanked: 427 time(s)
Has thanked: 33 time(s)
Contribution Points: 16687
It depends on the game; post the name and/or a screenshot from the game.

If you want to center your mouse, I would find the screen size (game window) and calculate the coordinates for the center. Then move mouse to those coordinates when you want to center it.

_________________
----------------------------------------Syrifina---------------------------------------------------
PM me for licenses and/or licensing information: Click Here
[Be sure to include and update your profile with your BE ID]

Forum Rules
Reminder of rules regarding Contribution points
Getting started in 1, 2, 3
Virtual Drivers; Manual Installers


Top
 Profile  
Reply with quote  
 Post subject: Re: Moving Mouse to Target in 3D Game
Thanked: 0 time(s)  Unread post Posted: Sat Mar 14, 2015 11:00 pm 
New User
New User



Joined: Sat Mar 14, 2015 6:22 pm
Posts: 4
Been thanked: 1 time(s)
Has thanked: 0 time(s)
Contribution Points: 17
The game is WARFRAME, and when you are in game there is no mouse to center, just your crosshair.


Top
 Profile  
Reply with quote  
 Post subject: Re: Moving Mouse to Target in 3D Game
Thanked: 0 time(s)  Unread post Posted: Sun Mar 15, 2015 7:26 pm 
Partner / Developer
Partner / Developer
User avatar



Joined: Mon Jan 18, 2010 11:51 am
Posts: 4524
Been thanked: 1215 time(s)
Has thanked: 132 time(s)
Contribution Points: 32899
I would search for the pixels you want to find.

Once found, calculate how many pixels X and Y the mouse needs to move to get that item into the center of the screen.
Then get the mouse current coordinates and store them in variables, calculate where to move the mouse to, in order to have traveled the previously calculated distance.
Finally set the mouse coordinates to that point, and that should be it.

Sorry if that was a bit confusing, hope it makes sense.

_________________
Blue Eye - Developer / Moderator
Code:
Gigus


Please read the rules about contribution points - click here

Do you know everything about BE, the forum, licenses and contribution points?
Please take a minute to read this introduction & guidelines.


Top
 Profile  
Reply with quote  
 Post subject: Re: Moving Mouse to Target in 3D Game
Thanked: 0 time(s)  Unread post Posted: Sun Mar 15, 2015 9:06 pm 
New User
New User



Joined: Sat Mar 14, 2015 6:22 pm
Posts: 4
Been thanked: 1 time(s)
Has thanked: 0 time(s)
Contribution Points: 17
Gigus wrote:
I would search for the pixels you want to find.

Once found, calculate how many pixels X and Y the mouse needs to move to get that item into the center of the screen.
Then get the mouse current coordinates and store them in variables, calculate where to move the mouse to, in order to have traveled the previously calculated distance.
Finally set the mouse coordinates to that point, and that should be it.

Sorry if that was a bit confusing, hope it makes sense.


Hi Gigus, thank you for the response.

Crystal clear. I will write up something for testing. Stay tuned!


Top
 Profile  
Reply with quote  
 Post subject: Re: Moving Mouse to Target in 3D Game
Thanked: 0 time(s)  Unread post Posted: Sun Mar 15, 2015 10:14 pm 
Partner / License admin
Partner / License admin
User avatar



Joined: Sun Oct 10, 2010 5:16 pm
Posts: 1934
Location: USA
Been thanked: 427 time(s)
Has thanked: 33 time(s)
Contribution Points: 16687
I downloaded the game and it's really fast paced. You have your work cut out for you.

Good luck. I look forward to seeing what you come up with.

_________________
----------------------------------------Syrifina---------------------------------------------------
PM me for licenses and/or licensing information: Click Here
[Be sure to include and update your profile with your BE ID]

Forum Rules
Reminder of rules regarding Contribution points
Getting started in 1, 2, 3
Virtual Drivers; Manual Installers


Top
 Profile  
Reply with quote  
 Post subject: Re: Moving Mouse to Target in 3D Game
Thanked: 1 time(s)  Unread post Posted: Sun Mar 15, 2015 10:58 pm 
New User
New User



Joined: Sat Mar 14, 2015 6:22 pm
Posts: 4
Been thanked: 1 time(s)
Has thanked: 0 time(s)
Contribution Points: 17
This is what I have come up with so far:

Code:
// My crosshair will always be 960, 540
 begin
     // Look for this reddish color and find it's coordinates
     while  Color.Can not be located on screen (RGB)("255", "60", "10", "5")
          begin
               Color.Find coordinate of first occurrence (RGB)("255", "60", "10", "5", "xFoundVar", "yFoundVar")
          end
     // Calculate X-pixel amount to move
     // xVar = 960, yVar =540 (My screen center, full screen mode
     Variable.Evaluate (Math)("{xFoundVar}-{xVar}", "xDiff")
     // X-coord align to target
     if  Variable.Is greater than (Math)("xDiff", "0")
          begin
               Mouse.Move in direction("Left", "{xDiff}")
          end
     if  Variable.Is less than (Math)("xDiff", "0")
          begin
               Mouse.Move in direction("Right", "{xDiff}")
          end
     // Calculate Y-pixel amount to move
     Variable.Evaluate (Math)("{yFoundVar}-{yVar}", "yDiff")
     // Y-coord align to target
     if  Variable.Is less than (Math)("yDiff", "0")
          begin
               Mouse.Move in direction("Up", "{yDiff}")
          end
     if  Variable.Is less than (Math)("yDiff", "0")
          begin
               Mouse.Move in direction("Down", "{yDiff}")
          end
 end


Could I get some input? My main concerns are that the function output is not what I am expecting OR the fact I do not have a Z-coordinate to my target will prevent me from accurately aiming at them.


Top
 Profile  
Reply with quote  
 Post subject: Re: Moving Mouse to Target in 3D Game
Thanked: 0 time(s)  Unread post Posted: Fri Aug 30, 2019 11:24 am 
New User
New User



Joined: Tue Jul 30, 2019 5:23 pm
Posts: 19
Been thanked: 0 time(s)
Has thanked: 9 time(s)
Contribution Points: 22
Maikelele wrote:
This is what I have come up with so far:

Code:
// My crosshair will always be 960, 540
 begin
     // Look for this reddish color and find it's coordinates
     while  Color.Can not be located on screen (RGB)("255", "60", "10", "5")
          begin
               Color.Find coordinate of first occurrence (RGB)("255", "60", "10", "5", "xFoundVar", "yFoundVar")
          end
     // Calculate X-pixel amount to move
     // xVar = 960, yVar =540 (My screen center, full screen mode
     Variable.Evaluate (Math)("{xFoundVar}-{xVar}", "xDiff")
     // X-coord align to target
     if  Variable.Is greater than (Math)("xDiff", "0")
          begin
               Mouse.Move in direction("Left", "{xDiff}")
          end
     if  Variable.Is less than (Math)("xDiff", "0")
          begin
               Mouse.Move in direction("Right", "{xDiff}")
          end
     // Calculate Y-pixel amount to move
     Variable.Evaluate (Math)("{yFoundVar}-{yVar}", "yDiff")
     // Y-coord align to target
     if  Variable.Is less than (Math)("yDiff", "0")
          begin
               Mouse.Move in direction("Up", "{yDiff}")
          end
     if  Variable.Is less than (Math)("yDiff", "0")
          begin
               Mouse.Move in direction("Down", "{yDiff}")
          end
 end


Could I get some input? My main concerns are that the function output is not what I am expecting OR the fact I do not have a Z-coordinate to my target will prevent me from accurately aiming at them.



Anyone complete this post? no answer?


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC


You cannot post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  


Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group