bosshunts Posted April 5, 2014 Share Posted April 5, 2014 Hello. I was wondering if there was anyway to make this program click the screen somewhere then go back to the position it was in before the click? I know I explain that weird so I'll give an example. I have this program set up to click on the screen when I move. I am wondering if there is a way to keep the mouse in the same position and still click the designated spot on the screen. Quote Link to comment Share on other sites More sharing options...
Wanted Posted April 5, 2014 Share Posted April 5, 2014 GetMousePos(P.X, P.Y); ClickMouse(100, 100... SetMousePos(P.X, P.Y); Quote Link to comment Share on other sites More sharing options...
bosshunts Posted April 5, 2014 Author Share Posted April 5, 2014 GetMousePos(P.X, P.Y); ClickMouse(100, 100... SetMousePos(P.X, P.Y); I don't understand what this is going to do? - - - Updated - - - This is the code I am using at the moment. begin Int :=0; repeat if GetHPPercent() < 80 then ClickMouse(591, 52, mbLeft); if GetManaPercent() < 80 then ClickMouse(982, 422, mbRight); Wait(900); inc(Int); until Int = 9999; end. Everytime I click, my mouse goes to the positions. I am wondering how I can make the mouse stay in the same spot but still Click on the positions. Is this possible? Quote Link to comment Share on other sites More sharing options...
Wanted Posted April 7, 2014 Share Posted April 7, 2014 No you could however move it back to the original position.. instantaneously if you wanted to however that's not a good idea for RS (ban detection) Quote Link to comment Share on other sites More sharing options...
bosshunts Posted April 7, 2014 Author Share Posted April 7, 2014 No you could however move it back to the original position.. instantaneously if you wanted to however that's not a good idea for RS (ban detection) This is exactly the kind of thing I want. Do you have a script for it? Quote Link to comment Share on other sites More sharing options...
slacky Posted April 7, 2014 Share Posted April 7, 2014 (edited) This is exactly the kind of thing I want. Do you have a script for it? The only option is to do what Wanted mentioned, but that won't work without a call to "Wait"-function due to the latency between you and the game, and the softwares response-time. procedure MouseClickReturn(X,Y: Integer; Btn:TMouseButton; WaitMS:Integer); var P:TPoint; begin GetMousePos(P.X, P.Y); ClickMouse(x,y, Btn); Wait(WaitMS); SetMousePos(P.X, P.Y); end; begin MouseClickReturn(100,100, mbRight, 150); end. The last number "150" is the wait-time (in millisec) before it moves back to it's original position. If the game has low response-time you can decrease the value, in worst case you will have to increase the value. This will not be as ghosty as you may want. and it will interrupt what ever else you are doing. Edited April 7, 2014 by slacky Quote Link to comment Share on other sites More sharing options...
bosshunts Posted April 7, 2014 Author Share Posted April 7, 2014 The only option is to do what Wanted mentioned, but that won't work without a call to "Wait"-function due to the latency between you and the game, and the softwares response-time. procedure MouseClickReturn(X,Y: Integer; Btn:TMouseButton; WaitMS:Integer); var P:TPoint; begin GetMousePos(P.X, P.Y); ClickMouse(x,y, Btn); Wait(WaitMS); SetMousePos(P.X, P.Y); end; begin MouseClickReturn(100,100, mbRight, 150); end. The last number "150" is the wait-time (in millisec) before it moves back to it's original position. If the game has low response-time you can decrease the value, in worst case you will have to increase the value. This will not be as ghosty as you may want. and it will interrupt what ever else you are doing. Although a TOTAL ghost mouse would be Fantastic. This method worked great. You really seem like you know what you are doing Ty Quote Link to comment Share on other sites More sharing options...