|
You last visited: Today at 16:31
Advertisement
I could use some help
Discussion on I could use some help within the AutoIt forum part of the Coders Den category.
06/22/2013, 01:30
|
#1
|
elite*gold: 0
Join Date: Feb 2011
Posts: 278
Received Thanks: 67
|
I could use some help
i am working on pixel bot with autoit
is there way to make draggable area where bot starts looking for pixels and how?
i would like it to be like the one in this vid
|
|
|
06/22/2013, 10:25
|
#2
|
elite*gold: 235
Join Date: Jan 2012
Posts: 920
Received Thanks: 377
|
As i have a good day here is the code for moving the rect.
You need a very small bg.gif ( )
And the code (I hate copy paste ):
If you have any questions then ask !
|
|
|
06/22/2013, 13:26
|
#3
|
elite*gold: 0
Join Date: Feb 2011
Posts: 278
Received Thanks: 67
|
what should this script do and can u check if my code has any mistakes because gui is not showing up.
Code:
#include <GDIPlus.au3>
#include <WinApi.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
HotKeySet( "{F10}","_Toggle")
$Size = 300
$Color = 0xFFFFAA00
$Thick = 3
$Toggle = False
Global $X=0,$Y=0
#region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Aimbot", $Size, -1, -1, $WS_POPUP,Bitor($WS_EX_LAYERED,$WS_EX_TOPMOST))
$Pic1 = GUICtrlCreatePic("bg.gif", 0, 0, $Size, $Size)
_WinAPI_SetLayeredWindowAttributes($Form1, 0x00FF00)
GUISetState(@SW_SHOW)
#endregion ### END Koda GUI section ###
_GDIPlus_Startup()
$Handle = _GDIPlus_GraphicsCreateFromHWND($Form1)
$Pencil =_GDIPlus_PenCreate($Color,$Thick)
_GDIPlus_GraphicsDrawRect($Handle,5,5,$Size-10,$Size-10,$Pencil)
While 1
If $Toggle Then
ToolTip("Mover your mouse (f10 to end)")
$pos = MouseGetPos()
WinMove("aimbot","",$Pos[0],$Pos[1])
$X = $Pos[0]
$Y = $Pos[1]
Else
ToolTip("")
Sleep(200)
EndIf
WEnd
_GDIPlus_Shutdown()
Func _Toggle()
$Toggle = Not $Toggle
EndFunc
|
|
|
06/22/2013, 13:52
|
#4
|
elite*gold: 235
Join Date: Jan 2012
Posts: 920
Received Thanks: 377
|
The script creats a hotkey (F10).
When you press this key the "edit mode" is enable and you can move the rect.
When you press F10 again the "edit mode" is disabled and the rect is on a fixed position.
In $x and $y are the new coordinations of the rect.
Now you can use PixelSearch with these variables to search for your pixel.
|
|
|
06/22/2013, 13:56
|
#5
|
elite*gold: 0
Join Date: Feb 2011
Posts: 278
Received Thanks: 67
|
problem is that script starts working with no errors but rect is not showing up
|
|
|
06/22/2013, 14:01
|
#6
|
elite*gold: 235
Join Date: Jan 2012
Posts: 920
Received Thanks: 377
|
Do you have the bg.gif at the same folder as the script ?
|
|
|
06/22/2013, 14:03
|
#7
|
elite*gold: 0
Join Date: Feb 2011
Posts: 278
Received Thanks: 67
|
i sent u pm with skype
and yes the image was not in same folder lol
EDIT:after placing picture to same folder with .exe and .au3 still not showing
|
|
|
06/22/2013, 14:39
|
#8
|
elite*gold: 0
Join Date: Mar 2009
Posts: 2,317
Received Thanks: 1,254
|
GUICreate("Aimbot", $Size, $Size, -1, -1,
dennoch versteh ich den sinn hinter einer .gif nicht, und was dein hotkey bringen soll.
|
|
|
06/22/2013, 14:43
|
#9
|
elite*gold: 235
Join Date: Jan 2012
Posts: 920
Received Thanks: 377
|
Gif, damit das Rechteck keinen Hintergrund hat und der HotKey um das Einbinden einer UDF zu vermeiden die das klicken der Maus erkennt.
|
|
|
06/22/2013, 14:48
|
#10
|
elite*gold: 0
Join Date: Feb 2011
Posts: 278
Received Thanks: 67
|
ty omer box is showing and thanks to crocko for script.
but there is one more mistake somewhere box is not movable when pressing F10
it shows tool tip but nofthing hapens when moving mouse and when f10 gets pressed agen.
i speak english and estonian
|
|
|
06/22/2013, 14:51
|
#11
|
elite*gold: 235
Join Date: Jan 2012
Posts: 920
Received Thanks: 377
|
You have to change the Title in WinMove from"aimbot" to "Aimbot".
Win move is case sensitive.
|
|
|
06/22/2013, 15:36
|
#12
|
elite*gold: 0
Join Date: Feb 2011
Posts: 278
Received Thanks: 67
|
ty. but is there a way to make rect resizeable by pulling right bottom corner.
|
|
|
06/22/2013, 15:41
|
#13
|
elite*gold: 235
Join Date: Jan 2012
Posts: 920
Received Thanks: 377
|
Yes and no. It is possible but not easy.
It would be easier if you use + and - for resize the rect. (_IsPressed)
|
|
|
06/22/2013, 15:44
|
#14
|
elite*gold: 0
Join Date: Feb 2011
Posts: 278
Received Thanks: 67
|
because every user i may want to give this bot has different sized game window so it would be good that they can resize the rect to the size most fits to they-r window
|
|
|
06/22/2013, 18:40
|
#15
|
elite*gold: 235
Join Date: Jan 2012
Posts: 920
Received Thanks: 377
|
But for that case you can use WinGetPos to get the windows size.
|
|
|
All times are GMT +2. The time now is 16:31.
|
|