Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > AutoIt
You last visited: Today at 19:22

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Minimized Bot Help!!

Discussion on Minimized Bot Help!! within the AutoIt forum part of the Coders Den category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Apr 2011
Posts: 363
Received Thanks: 167
Question Minimized Bot Help!!

Hi elitepvpers i want to make a bot that will work with the game window minimized so that i can do anything else while the bot is running but i have some troubles D:

The script only click Start button, its a begining




When the button is clicked the game start:


The game : S4League


Here is my script:

Code:
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <WinAPI.au3>
#include <Misc.au3>

$i = 0
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Minimize Bot", 239, 131, 196, 124)

$Button1=GUICtrlCreateButton("Click Ready",56,40,123,49)


GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###




global $startx,$starty

AdlibRegister("_Winsize",1000)
Func _Winsize()
	if WinExists("S4 Client") Then
	 $size = WinGetClientSize("S4 Client");Returns size of the window
	$_sizex = $size[0]
	$_sizey=$size[1]
	$_TotalSize=$_sizex & "," & $_sizey

	Switch  $_TotalSize
		Case "1024,752" ;two posible resolution one in window mode and other in fullscreen

			$startx=944
			$starty=519

		Case "1024,768"

			$startx=947
			$starty=504

			EndSwitch
	EndIf
EndFunc

Func _Attack()
	While (not _IsPressed("60"));NUMPAD0

	_WinAPI_Mouse_Event(0x0002)
				Sleep(100)
	_WinAPI_Mouse_Event(0x0004)
	Sleep(500)
WEnd
Exit 0
	EndFunc

While 1
	$nMsg = GUIGetMsg()
	Switch $nMsg
		Case $GUI_EVENT_CLOSE
			Exit
		case $Button1

		WinSetState("S4 Client","",@SW_MINIMIZE)
		Sleep(100)
		ControlClick("S4 Client","","","left",2,$startx,$starty);click Ready button
		Sleep(500)
		_Attack()
EndSwitch
WEnd
The problems are...
Anti Hacking Program Block keystrokes so i'm suposed to use _isPressed, to set hotkeys, and _WinAPI_Mouse_Event() to make the bot work when the character is ready.
but...
_WinAPI_Mouse_Event doesn't work when the window is minimized
ControlClick would be good but i think is blocked too... because it doesn't do anything...


Don't Tested: _SendMessage/PostMessage cause i don't know how to make them work with these...

Until Now the only thing which is working is clicking Start button when window is minimized it just click elsewhere

Question:
Is there any way to combine ControlClick function with _WinAPI_Mouse_Event ??

What the bot should do?:
it should click start , then send mouseclicks to make the character autoattack all of these with the window minimized


Its a beta version so i don't make an effort to continue loop when finish,
until i solve this problem...
elmarcia is offline  
Old 03/21/2013, 11:18   #2
 
Croco™'s Avatar
 
elite*gold: 235
Join Date: Jan 2012
Posts: 920
Received Thanks: 377
In the S4 section was an AutoIT bypass a few mounth ago.
Maybe you can use ControlSend with this bypass.
Croco™ is offline  
Thanks
1 User
Old 03/21/2013, 12:40   #3
 
Achat's Avatar
 
elite*gold: 528
Join Date: Jan 2012
Posts: 2,127
Received Thanks: 2,403
Code:
WinActivate ; - S4 in foreground
;Your actions
WinActivate  ; - last window in foreground again
Kind Regards
Achat is offline  
Thanks
1 User
Old 03/21/2013, 14:49   #4
 
elite*gold: 0
Join Date: Apr 2011
Posts: 363
Received Thanks: 167
Quote:
Originally Posted by Achat View Post
Code:
WinActivate ; - S4 in foreground
;Your actions
WinActivate  ; - last window in foreground again
Kind Regards
The thing is that i don't want the window to bother me all the time also the mouseclick event is all the time so the focus event will make me crazy

i want to make it work with the window minimized with no need to maximize again

Quote:
Originally Posted by Croco™ View Post
In the S4 section was an AutoIT bypass a few mounth ago.
Maybe you can use ControlSend with this bypass.
i think its patched by i will check if there is one more recent

Can anyone make me an example of _SendMessage/PostMessage cause i have no idea how to make that work with mouse events
elmarcia is offline  
Old 03/21/2013, 18:39   #5
 
Achat's Avatar
 
elite*gold: 528
Join Date: Jan 2012
Posts: 2,127
Received Thanks: 2,403
Quote:
Originally Posted by elmarcia View Post
i think its patched by i will check if there is one more recent

Can anyone make me an example of _SendMessage/PostMessage cause i have no idea how to make that work with mouse events
Send/Postmessage doesn't work either.
S4 Client only accepts keystrokes if it is in foreground.

Kind Regards
Achat is offline  
Thanks
1 User
Reply


Similar Threads Similar Threads
Key Presser for SRO while minimized
05/20/2009 - Silkroad Online - 3 Replies
I'm looking for a program that works as a key presser for SRO while minimized so I can do other things, something like auto pot buff resser, and not a bot but supports the new client, 1.175.
which bot can be minimized?
09/01/2008 - Archlord - 4 Replies
see topic
Minimized autoleveler
05/31/2008 - Conquer Online 2 - 6 Replies
I made an AutoLeveler which works in background too (it pick up items only if it is the top window:( ) I found almost everything... Monster coords,player coords,HP value,etc... But i didn't find the MP value. Im searching for it for 2 weeks. Anyone have any idea how could we find it? MP doesn't works like the HP... I would need a method to find it. Please post if you know something about it. After we will find the MP value (with pointers and offsets) i will post the bot too.
[Tool]AutoRes (Minimized)
04/26/2008 - SRO Hacks, Bots, Cheats & Exploits - 3 Replies
edited
Lineage 2 closes when minimized
05/16/2006 - Lineage 2 - 0 Replies
I have a problem (i didn't had it before) when i minimize(alt+tab) Lineage 2 c3 (i play on a private server) and click with mouse to reopen it terminates itself(alt+tab doesn't work when l2 minimized it did before). It wasn't before, i tried reinstaling the game didn't helped :rolleyes: . My PC (notebook compaq nx9030) Intel pentium M 1.4ghz Dothian 512 SDR RAM integrated 64mb video (intel extreme graphics 2, more exactly Intel 82852/82855 GM/GME) WinXP home SP2.



All times are GMT +1. The time now is 19:23.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.