Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Smart Clicker v1.1.2
- Written By: Hellbent aka CivReborn
- YouTube Page: https://www.youtube.com/user/CivReborn
- Written For: The CivReborn Youtube Channel. All rights reserved
- Notice: Do not distribute this script without prior written consent by the author (Hellbent aka CivReborn)
- Date Started: June 18th, 2018
- Date Of Last Edit: June 18th, 2018
- Last Paste:
- */
- #SingleInstance,Force
- CoordMode,Mouse,Screen
- SetBatchLines,10ms
- SetTitleMatchMode,2
- ;~ SetMouseDelay,60 ;<----- uncomment this line if this clicks to fast for the app you are trying to click.
- pButton_StartUp()
- global Press_active:=0,Hover_On:=0,Active_Button,pButton:={},pTab1:={},pCheckBox:={},pRadio:={},Use_Target_Window:=1,Stop:=0,Target_X:=null,Target_Y:=null,Target_Window:=null,Box_Width:=80,Box_Height:=80,Click_Delay:=0,Turbo_Mode:=0,Use_Click_Delay
- MainBorder:=[0,0,2,250,0,0,350,2,0,248,350,2,348,0,2,250],MainInnerBorder:=[0,0,1,215,0,0,330,1,0,214,330,1,329,0,1,215],TabBorder:=[0,0,310,1,0,0,1,45,0,44,310,1,309,0,1,45],TBorder:=[0,0,320,1,0,0,1,105,0,104,320,1,319,0,1,105],E1Border:=[9,63,303,1,9,63,1,17,9,80,303,1,311,63,1,17],E2Border:=[189,16,87,1,189,34,87,1,189,16,1,18,276,16,1,19],E3Border:=[104,52,62,1,104,70,62,1,104,52,1,18,165,52,1,19],E4Border:=[104,77,62,1,104,95,62,1,104,77,1,18,165,77,1,19],E5Border:=[119,61,102,1,119,79,102,1,119,61,1,18,221,61,1,19]
- Gui,1:+AlwaysOnTop -DPIScale -Caption
- Gui,1:Color,Black
- i:=1
- Loop 4 {
- Gui,1:Add,Progress,% "x" MainBorder[i] " y"MainBorder[i+1] " w" MainBorder[i+2] " h" MainBorder[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,1:Font,caaaaaa s8 Bold Q5,Segoe UI
- pButton[1]:=New Progress_Button(1,1,"Tag",7,5,20,20,"aa0000","aa0000","151515","661515","111111","HB",3)
- Gui,1:Font,caaaaaa s9 Bold Q5,Segoe UI
- pButton[2]:=New Progress_Button(1,2,"Move_Window",60,5,230,20,"aa0000","aa0000","151515","440000","aa0000","Smart Clicker v1.1.2",3),pButton[3]:=New Progress_Button(1,3,"Min_Window",313,5,12,12,"aa0000","aa0000","151515","661515","aa0000","_",-7),pButton[4]:=New Progress_Button(1,4,"GuiClose",331,5,12,12,"aa0000","aa0000","151515","661515","aa0000","x",-3)
- Gui,2:+Parent1 -Caption -DPIScale
- Gui,2:Color,111111 ;282828
- i:=1
- Loop 4 {
- Gui,2:Add,Progress,% "x" MainInnerBorder[i] " y" MainInnerBorder[i+1] " w" MainInnerBorder[i+2] " h" MainInnerBorder[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,2:Font,caaaaaa s12 Bold Q5,Segoe UI
- pButton[5]:=New Progress_Button(2,5,"Start_Auto_Clicker",10,165,150,45,"Black","aa0000","151515","252525","292929","Start",11),pButton[6]:=New Progress_Button(2,6,"Stop_Auto_Clicker",170,165,150,45,"Black","aa0000","151515","252525","292929","Stop",11)
- Gui,3:+Parent2 -Caption -DPIScale
- Gui,3:Color,191919
- i:=1
- Loop 4 {
- Gui,3:Add,Progress,% "x" TabBorder[i] " y" TabBorder[i+1] " w" TabBorder[i+2] " h" TabBorder[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,3:Font,caaaaaa s10 Bold Q5,Segoe UI
- pTab1[1]:=New Progress_Tab1(3,"Main_Tab","Swap_Tabs",1,"Group1",8,5,70,35,"Black","aa0000","444444","050505","120000","Main",6,1),pTab1[2]:=New Progress_Tab1(3,"Window_Tab","Swap_Tabs",0,"Group1",83,5,70,35,"Black","aa0000","444444","050505","120000","Window",6,1),pTab1[3]:=New Progress_Tab1(3,"Position_Tab","Swap_Tabs",0,"Group1",158,5,70,35,"Black","aa0000","444444","050505","120000","Position",6,1),pTab1[4]:=New Progress_Tab1(3,"Speed_Tab","Swap_Tabs",0,"Group1",233,5,70,35,"Black","aa0000","444444","050505","120000","Speed",6,1)
- Gui,4:+Parent2 -Caption -DPIScale
- Gui,4:Color,191919
- i:=1
- Loop 4 {
- Gui,4:Add,Progress,% "x" TBorder[i] " y" TBorder[i+1] " w" TBorder[i+2] " h" TBorder[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,4:Font,caaaaaa s10 Q5,Segoe UI
- pCheckBox[1]:=New Progress_CheckBox(4,"Always","Always_On_Top",1,10,20,122,7,-120,8,"555555","444444","aa0000","444444"," AlwaysOnTop ",1,0),pCheckBox[2]:=New Progress_CheckBox(4,"Use_Target_Window","Submit_All",1,10,60,122,7,-123,8,"555555","444444","aa0000","444444"," Use Target Window ",1,0)
- GuiControl,4:-Backgroundtrans,pCheckbox[1].Checkbox_ID4
- GuiControl,4:-Backgroundtrans,pCheckbox[2].Checkbox_ID4
- Gui,4:Font,caaaaaa s10 bold Q5,Segoe UI
- pButton[7]:=New Progress_Button(4,7,"FAQ",185,12,100,30,"Black","aa0000","151515","252525","000000","FAQ",5),pButton[8]:=New Progress_Button(4,8,"Get_More_Auto_Clickers",170,50,130,40,"Black","aa0000","151515","252525","000000","More Auto Clickers",10)
- Gui,5:+Parent2 -Caption -DPIScale
- Gui,5:Color,191919,111111
- i:=1
- Loop 4 {
- Gui,5:Add,Progress,% "x" TBorder[i] " y" TBorder[i+1] " w" TBorder[i+2] " h" TBorder[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,5:Font,caaaaaa s10 Bold Q5,Segoe UI
- pButton[9]:=New Progress_Button(5,9,"Set_Window",30,15,115,35,"Black","aa0000","151515","252525","222222","Set Window",8),pButton[10]:=New Progress_Button(5,10,"Update_Window",175,15,115,35,"Black","aa0000","151515","252525","222222","Update",8)
- Gui,5:Font,caaaaaa s8 Q5,Segoe UI
- Gui,5:Add,Edit,x10 y64 w300 h15 -E0x200 Center vTarget_Window
- i:=1
- Loop,4 {
- Gui,5:Add,Progress,% "x" E1Border[i] " y" E1Border[i+1] " w" E1Border[i+2] " h" E1Border[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,6:+Parent2 -Caption -DPIScale
- Gui,6:Color,191919,111111
- i:=1
- Loop 4 {
- Gui,6:Add,Progress,% "x" TBorder[i] " y" TBorder[i+1] " w" TBorder[i+2] " h" TBorder[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,6:Font,caaaaaa s10 Bold Q5,Segoe UI
- pButton[11]:=New Progress_Button(6,11,"Set_Position",50,10,115,30,"Black","aa0000","151515","252525","222222","Set Position",6)
- Gui,6:Font,caaaaaa s8 Q5,Segoe UI
- Gui,6:Add,Edit,x190 y17 w85 h16 -E0x200 Center vPosition,
- i:=1
- Loop,4 {
- Gui,6:Add,Progress,% "x" E2Border[i] " y" E2Border[i+1] " w" E2Border[i+2] " h" E2Border[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,6:Font,caaaaaa s10 Bold Q5,Segoe UI
- Gui,6:Add,Text,x10 y52 ,Box Width:
- Gui,6:Add,Text,x10 y77 ,Box Height:
- Gui,6:Font,caaaaaa s8 Q5,Segoe UI
- Gui,6:Add,Edit,x105 y53 w60 h16 Number -E0x200 Center vBox_Width gSubmit_All,80
- i:=1
- Loop,4 {
- Gui,6:Add,Progress,% "x" E3Border[i] " y" E3Border[i+1] " w" E3Border[i+2] " h" E3Border[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,6:Add,Edit,x105 y78 w60 h16 Number -E0x200 Center vBox_Height gSubmit_All,80
- i:=1
- Loop,4 {
- Gui,6:Add,Progress,% "x" E4Border[i] " y" E4Border[i+1] " w" E4Border[i+2] " h" E4Border[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,6:Font,caaaaaa s10 Bold Q5,Segoe UI
- pButton[12]:=New Progress_Button(6,12,"Preview_Position",185,52,115,45,"Black","aa0000","151515","252525","222222","Preview",12)
- Gui,7:+Parent2 -Caption -DPIScale
- Gui,7:Color,191919,111111
- i:=1
- Loop 4 {
- Gui,7:Add,Progress,% "x" TBorder[i] " y" TBorder[i+1] " w" TBorder[i+2] " h" TBorder[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,7:Font,caaaaaa s10 norm Q5,Segoe UI
- pCheckBox[3]:=New Progress_CheckBox(7,"Use_Click_Delay","Submit_All",1,10,15,122,7,-123,8,"555555","444444","aa0000","444444"," Use Click Delay ",1,0),pCheckBox[4]:=New Progress_CheckBox(7,"Turbo_Mode","Submit_All",0,186,15,122,7,-123,8,"555555","444444","aa0000","444444"," Turbo Mode ",1,0)
- GuiControl,7:-Backgroundtrans,pCheckbox[3].Checkbox_ID4
- GuiControl,7:-Backgroundtrans,pCheckbox[4].Checkbox_ID4
- Gui,7:Font,caaaaaa s10 Bold Q5,Segoe UI
- Gui,7:Add,Text,x30 y60 ,Click Delay:
- Gui,7:Font,caaaaaa s8 Bold Q5,Segoe UI
- Gui,7:Add,Edit,x120 y62 w100 h16 Number -E0x200 Center vClick_Delay gSubmit_All, 0
- i:=1
- Loop,4 {
- Gui,7:Add,Progress,% "x" E5Border[i] " y" E5Border[i+1] " w" E5Border[i+2] " h" E5Border[i+3] " Backgroundaa0000"
- i+=4
- }
- Gui,7:Font,caaaaaa s10 Bold Q5,Segoe UI
- Gui,7:Add,Text,x230 y60 ,( ms )
- Gui,4:Show,x5 y55 w320 h105
- Gui,3:Show,x10 y5 w310 h45
- Gui,2:Show,x10 y30 w330 h215
- Gui,1:Show,w350 h250,Smart Clicker v1.1.2
- gosub,Submit_All
- return
- GuiClose:
- *^!+ESC::
- ExitApp
- Class Progress_Button {
- __New(Window_Name,Button_Name,Label,x,y,w,h,BC,TRC,TC1,TC2,TC3,Button_Text,Text_Offset:=0){
- This.Text_Offset:=Text_Offset,This.Window_Name:=Window_Name,This.Button_Name:=Button_Name,This.Label:=Label,This.Button_ID1:=Button_Name "_1",This.Button_ID2:=Button_Name "_2"
- This.Button_ID3:=Button_Name "_3",This.Button_ID4:=Button_Name "_4",This.Button_Text:=Button_Text,This.X:=x,This.Y:=y,This.W:=w,This.H:=h
- This.Bottom_Color:=BC,This.Trim_Color:=TRC,This.Top_Color_1:=TC1,This.Top_Color_2:=TC2,This.Top_Color_3:=TC3,This.Add_Button()
- }
- Add_Button(){
- global
- Gui,% This.Window_Name ":Add",Text,% "x" This.X " y" This.Y " w" This.W " h" This.H " v" This.Button_Name " g" This.Label
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X " y" This.Y " w" This.W " h" This.H " Background" This.Bottom_Color " v" This.Button_ID1
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X " y" This.Y " w" This.W-1 " h" This.H-1 " Background" This.Trim_Color " v" This.Button_ID2
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X+1 " y" This.Y+1 " w" This.W-2 " h" This.H-2 " Background" This.Top_Color_1 " v" This.Button_ID3
- Gui,% This.Window_Name ":Add",Text,% "x" This.X+1 " y" This.Y+This.Text_Offset " w" This.W-2 " r1 Center BackgroundTrans v" This.Button_ID4,% This.Button_Text
- }
- Button_Press(){
- global
- Press_Active:=1
- GuiControl,% This.Window_Name ":Move",% This.Button_ID4,% "x" This.X+1 " y" This.Y+1+This.Text_Offset
- sleep,-1
- GuiControl,% This.Window_Name ":Hide",This.Button_ID2
- GuiControl,% This.Window_Name ":+Background" This.Top_Color_3,% This.Button_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID1
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID4
- While(GetKeyState("LButton"))
- Sleep, 10
- MouseGetPos,,,,ctrl,2
- GuiControlGet,cName,% win ":Name",% ctrl
- cut:=Strlen(cName)
- StringLeft,bName,cName,cut-2
- if(bname=This.Button_Name){
- GuiControl,% This.Window_Name ":Show",This.Button_ID2
- GuiControl,% This.Window_Name ":+Background" This.Top_Color_1,% This.Button_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID1
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID2
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID3
- GuiControl,% This.Window_Name ":Move",% This.Button_ID4,% "x" This.X " y" This.Y+This.Text_Offset
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID4
- %bName%.Button_Hover_On()
- Hover_On:=0,Active_Button:=bname,Press_Active:=0
- sleep,10
- return true
- }
- GuiControl,% This.Window_Name ":Show",This.Button_ID2
- GuiControl,% This.Window_Name ":Move",% This.Button_ID4,% "x" This.X " y" This.Y+This.Text_Offset
- GuiControl,% This.Window_Name ":+Background" This.Top_Color_1,% This.Button_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID1
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID2
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID4
- Hover_On:=0,Press_Active:=0
- sleep,10
- return False
- }
- Button_Hover_On(){
- global
- GuiControl,% This.Window_Name ":+Background" This.Top_Color_2,% This.Button_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID4
- }
- Button_Hover_Off(){
- global
- GuiControl,% This.Window_Name ":+Background" This.Top_Color_1,% This.Button_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Button_ID4
- }
- }
- Get_Name(Name){
- global
- Loop, % pCheckBox.Length()
- if(Name=pCheckBox[A_Index].Name||Name=pCheckBox[A_Index].Checkbox_ID4){
- pCheckBox[A_Index].UpDate_CheckBox()
- break
- }
- }
- Class Progress_CheckBox {
- __New(Window_Name,Checkbox_Name,Label,Start_State,x,y,w,h,Text_X_Offset,Text_Y_Offset,Outer_Color,Inner_Color,Check_On_Colour,Check_Off_Colour,Check_Box_Text,Outer_Thickness:=1,Inner_Thickness:=1){
- This.X:=x,This.Y:=y,This.W:=w,This.H:=h,This.Text_X_Offset:=Text_X_Offset,This.Text_Y_Offset:=Text_Y_Offset,This.Outer_Thickness:=Outer_Thickness,This.Inner_Thickness:=Inner_Thickness,This.Outer_Trim_Colour:=Outer_Color,This.Inner_Trim_Colour:=Inner_Color
- This.Check_On_Colour:=Check_On_Colour,This.Check_Off_Colour:=Check_Off_Colour,This.Name:=Checkbox_Name,This.Checkbox_ID1:=This.Name "_1",This.Checkbox_ID2:=This.Name "_2",This.Checkbox_ID3:=This.Name "_3",This.Checkbox_ID4:=This.Name "_4",This.Window_Name:=Window_Name,This.Label:=Label
- This.Outer_Trim_Thickness:=Outer_Thickness,This.Inner_Trim_Thickness:=Inner_Thickness,This.Is_On:=Start_State,This.Text:=Check_Box_Text,This.Add_CheckBox()
- }
- Add_CheckBox(){
- global
- Gui,% This.Window_Name ":Add",Text,% "x" This.X " y" This.Y " w" This.W " h" This.H " v" This.Name " g" This.Label
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X " y" This.Y " w" This.W " h" This.H " BackGround" This.Outer_Trim_Colour " v" This.Checkbox_ID1
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X+This.Outer_Thickness " y" This.Y+This.Outer_Thickness " w" This.W-(2*This.Outer_Thickness) " h" This.H-(2*This.Outer_Thickness) " BackGround" This.Inner_Trim_Colour " v" This.Checkbox_ID2
- (This.Is_On=1)?(col:=This.Check_On_Colour):(col:=This.Check_Off_Colour)
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X+This.Outer_Thickness+This.Inner_Thickness " y" This.Y+This.Outer_Thickness+This.Inner_Thickness " w" This.W - ((2*This.Outer_Thickness)+(2*This.Inner_Thickness)) " h" This.H - ((2*This.Outer_Thickness)+(2*This.Inner_Thickness)) " BackGround" col " v" This.Checkbox_ID3
- Gui,% This.Window_Name ":Add",Text,% "x" This.X+This.W+This.Text_X_Offset " y" This.Y+This.Text_Y_Offset " Backgroundtrans v" This.Checkbox_ID4 " g" This.Label,% This.Text
- }
- UpDate_CheckBox(){
- if(This.Is_On:=!This.Is_On){
- GuiControl,% This.Window_Name ":+Background" This.Check_On_Colour,% This.Checkbox_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Checkbox_ID4
- }else {
- GuiControl,% This.Window_Name ":+Background" This.Check_Off_Colour,% This.Checkbox_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Checkbox_ID4
- }
- }
- }
- Swap_Tab1_State(Control)
- {
- Loop, % pTab1.Length()
- if(Control=pTab1[A_Index].Name&&pTab1[A_Index].State!=1){
- pTab1[A_Index].UpDate_Tabs()
- break
- }
- }
- class Progress_Tab1 {
- __New(Window_Name,Name,Label,Starting_State,Group_Name,x,y,w,h,Background_Colour,Trim_Color_1,Trim_Color_2,Top_Color_1,Top_Color_2,Text,Y_Text_Offset:=0,Trim_Size:=2){
- This.X:=x,This.Y:=y,This.W:=w,This.H:=h,This.State:=Starting_State,This.Y_Offset:=Y_Text_Offset,This.Name:=Name,This.Group:=Group_Name,This.Window_Name:=Window_Name
- This.Label:=Label,This.Colour1:=Background_Colour,This.Colour2:=Trim_Color_1,This.Colour3:=Trim_Color_2,This.Colour4:=Top_Color_1,This.Colour5:=Top_Color_2
- This.ID1:=This.Name "_1",This.ID2:=This.Name "_2",This.ID3:=This.Name "_3",This.ID4:=This.Name "_4",This.Text:=Text,This.Trim_Size:=Trim_Size,This.Add_Tabs()
- }
- Add_Tabs(){
- global
- Gui,% This.Window_Name ":Add",Text,% "x" This.X " y" This.Y " w" This.W " h" This.H " v" This.Name " g" This.Label
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X " y" This.Y " w" This.W " h" This.H " Background" This.Colour1 " v" This.ID1
- if(This.State=0){
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X " y" This.Y " w" This.W-This.Trim_Size " h" This.H-This.Trim_Size " Background" This.Colour2 " v" This.ID2
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X+This.Trim_Size " y" This.Y+This.Trim_Size " w" This.W-This.Trim_Size*3 " h" This.H-This.Trim_Size*3 " Background" This.Colour4 " v" This.ID3
- Gui,% This.Window_Name ":Add",Text,% "x" This.X+This.Trim_Size " y" This.Y+This.Trim_Size+This.Y_Offset " w" This.W-This.Trim_Size*3 " r1 Center BackgroundTrans v" This.ID4,% This.Text
- }else {
- GuiControl,% This.Window_Name ":Hide",% This.ID1
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X+This.Trim_Size " y" This.Y+This.Trim_Size " w" This.W-This.Trim_Size " h" This.H-This.Trim_Size " Background" This.Colour3 " v" This.ID2
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X+2*This.Trim_Size " y" This.Y+2*This.Trim_Size " w" This.W-This.Trim_Size*3 " h" This.H-This.Trim_Size*3 " Background" This.Colour5 " v" This.ID3
- Gui,% This.Window_Name ":Add",Text,% "x" This.X+This.Trim_Size*2 " y" This.Y+(This.Trim_Size*2)+This.Y_Offset " w" This.W-This.Trim_Size*3 " r1 Center BackgroundTrans v" This.ID4,% This.Text
- }
- }
- UpDate_Tabs(){
- Loop,% pTab1.Length(){
- if(pTab1[A_Index].State=1&&pTab1[A_Index].Group=This.Group){
- pTab1[A_Index].State:=0
- GuiControl,% pTab1[A_Index].Window_Name ":Move",% pTab1[A_Index].ID2,% "x" pTab1[A_Index].X " y" pTab1[A_Index].Y
- GuiControl,% pTab1[A_Index].Window_Name ":Move",% pTab1[A_Index].ID3,% "x" pTab1[A_Index].X+pTab1[A_Index].Trim_Size " y" pTab1[A_Index].Y+pTab1[A_Index].Trim_Size
- GuiControl,% pTab1[A_Index].Window_Name ":Move",% pTab1[A_Index].ID4,% "x" pTab1[A_Index].X+pTab1[A_Index].Trim_Size " y" pTab1[A_Index].Y+pTab1[A_Index].Trim_Size+pTab1[A_Index].Y_Offset
- GuiControl,% pTab1[A_Index].Window_Name ":Show",% pTab1[A_Index].ID1
- GuiControl,% pTab1[A_Index].Window_Name ":+Background" pTab1[A_Index].Colour2,% pTab1[A_Index].ID2
- GuiControl,% pTab1[A_Index].Window_Name ":+Background" pTab1[A_Index].Colour4,% pTab1[A_Index].ID3
- GuiControl,% pTab1[A_Index].Window_Name ":+Redraw",% pTab1[A_Index].ID4
- }
- }
- GuiControl,% This.Window_Name ":Hide",% This.ID1
- GuiControl,% This.Window_Name ":Move",% This.ID2,% "x" This.X+This.Trim_Size " y" This.Y+This.Trim_Size
- GuiControl,% This.Window_Name ":Move",% This.ID3,% "x" This.X+2*This.Trim_Size " y" This.Y+2*This.Trim_Size
- GuiControl,% This.Window_Name ":Move",% This.ID4,% "x" This.X+This.Trim_Size*2 " y" This.Y+(This.Trim_Size*2)+This.Y_Offset
- GuiControl,% This.Window_Name ":+Background" This.Colour3,% This.ID2
- GuiControl,% This.Window_Name ":+Background" This.Colour5,% This.ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.ID4
- This.State:=1
- }
- }
- Swap_Radio_State(Control){
- Loop, % pRadio.Length()
- if((Control=pRadio[A_Index].Name||Control=pRadio[A_Index].Radio_ID4)&&pRadio[A_Index].State!=1){
- pRadio[A_Index].Update_Radio()
- break
- }
- }
- class Progress_Radio {
- __New(Window_Name,Radio_Name,Label,Start_State,Group_Name,x,y,w,h,Text_X_Offset,Text_Y_Offset,Outer_Color,Inner_Color,Radio_On_Colour,Radio_Off_Colour,Radio_Text,Outer_Thickness:=1,Inner_Thickness:=1){
- This.X:=x,This.Y:=y,This.W:=w,This.H:=h,This.Group:=Group_Name,This.Text_X_Offset:=Text_X_Offset,This.Text_Y_Offset:=Text_Y_Offset
- This.Outer_Thickness:=Outer_Thickness,This.Inner_Thickness:=Inner_Thickness,This.Outer_Trim_Colour:=Outer_Color,This.Inner_Trim_Colour:=Inner_Color
- This.Radio_On_Colour:=Radio_On_Colour,This.Radio_Off_Colour:=Radio_Off_Colour,This.Name:=Radio_Name,This.Radio_ID1:=This.Name "_1",This.Radio_ID2:=This.Name "_2",This.Radio_ID3:=This.Name "_3"
- This.Radio_ID4:=This.Name "_4",This.Window_Name:=Window_Name,This.Label:=Label,This.Outer_Trim_Thickness:=Outer_Thickness,This.Inner_Trim_Thickness:=Inner_Thickness
- This.State:=Start_State,This.Text:=Radio_Text
- This.Add_Radio()
- }
- Add_Radio(){
- global
- Gui,% This.Window_Name ":Add",Text,% "x" This.X " y" This.Y " w" This.W " h" This.H " v" This.Name " g" This.Label
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X " y" This.Y " w" This.W " h" This.H " BackGround" This.Outer_Trim_Colour " v" This.Radio_ID1
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X+This.Outer_Thickness " y" This.Y+This.Outer_Thickness " w" This.W-(2*This.Outer_Thickness) " h" This.H-(2*This.Outer_Thickness) " BackGround" This.Inner_Trim_Colour " v" This.Radio_ID2
- (This.State=1)?(col:=This.Radio_On_Colour):(col:=This.Radio_Off_Colour)
- Gui,% This.Window_Name ":Add",Progress,% "x" This.X+This.Outer_Thickness+This.Inner_Thickness " y" This.Y+This.Outer_Thickness+This.Inner_Thickness " w" This.W - ((2*This.Outer_Thickness)+(2*This.Inner_Thickness)) " h" This.H - ((2*This.Outer_Thickness)+(2*This.Inner_Thickness)) " BackGround" col " v" This.Radio_ID3
- Gui,% This.Window_Name ":Add",Text,% "x" This.X+This.W+This.Text_X_Offset " y" This.Y+This.Text_Y_Offset " Backgroundtrans v" This.Radio_ID4 " g" This.Label,% This.Text
- }
- Update_Radio(){
- Loop,% pRadio.Length() {
- if(pRadio[A_Index].State=1&&pRadio[A_Index].Group=This.Group){
- GuiControl,% pRadio[A_Index].Window_Name ":+Background" pRadio[A_Index].Radio_Off_Colour,% pRadio[A_Index].Radio_ID3
- GuiControl,% pRadio[A_Index].Window_Name ":+Redraw",% pRadio[A_Index].Radio_ID4
- pRadio[A_Index].State:=0
- }
- }
- GuiControl,% This.Window_Name ":+Background" This.Radio_On_Colour,% This.Radio_ID3
- GuiControl,% This.Window_Name ":+Redraw",% This.Radio_ID4
- This.State:=1
- }
- }
- Tag:
- if(!pButton[A_GuiControl].Button_Press())
- return
- Stop:=1
- Try{
- run,https://www.youtube.com/user/CivReborn
- }
- return
- FAQ:
- if(!pButton[A_GuiControl].Button_Press())
- return
- Stop:=1,Show_Message("5")
- return
- Update_Window:
- if(!pButton[A_GuiControl].Button_Press())
- return
- Stop:=1
- Gui,5:Submit,NoHide
- return
- Submit_All:
- Get_Name(A_GuiControl)
- (pCheckbox[2].Is_On=1)?(Use_Target_Window:=1):(Use_Target_Window:=0)
- (pCheckbox[3].Is_On=1)?(Use_Click_Delay:=1):(Use_Click_Delay:=0)
- (pCheckbox[4].Is_On=1)?(Turbo_Mode:=1):(Turbo_Mode:=0)
- Gui,6:Submit,NoHide
- Gui,7:Submit,NoHide
- Stop:=1
- return
- Set_Window:
- if(!pButton[A_GuiControl].Button_Press())
- return
- Stop:=1,Target_Window:=Set_Window()
- return
- Get_More_Auto_Clickers:
- if(!pButton[A_GuiControl].Button_Press())
- return
- Stop:=1
- Try{
- run,https://www.youtube.com/playlist?list=PLPI5C2_hIGGw7poIqgox3rDnyocwTxcY_
- }
- return
- Move_Window:
- PostMessage,0xA1,2
- while(Getkeystate("LButton"))
- SetTimer,Watch_Hover,off
- SetTimer,Watch_Hover,10
- return
- Min_Window:
- Gui,1:Minimize
- return
- Always_On_Top:
- Get_Name(A_GuiControl)
- if(pCheckbox[1].is_on=1)
- Gui,1:+AlwaysOnTop
- else
- Gui,1:-AlwaysOnTop
- return
- Swap_Tabs:
- Swap_Tab1_State(A_GuiControl),Switch_Tabs(A_GuiControl)
- return
- Start_Auto_Clicker:
- if(!pButton[A_GuiControl].Button_Press())
- return
- Run_Auto_Clicker()
- return
- Stop_Auto_Clicker:
- if(!pButton[A_GuiControl].Button_Press())
- return
- Stop:=1
- return
- Set_Position:
- if(!pButton[A_GuiControl].Button_Press())
- return
- Stop:=1,Set_Click_Position()
- return
- Preview_Position:
- if(!pButton[A_GuiControl].Button_Press())
- return
- Stop:=1
- if(Target_X!=null)
- Show_Preview_Box()
- else
- Show_Message("1")
- return
- Show_Preview_Box(){
- x1:=Target_X-(Box_Width//2),y1:=Target_Y-(Box_Height//2)
- Gui,1:Minimize
- Gui,8:Destroy
- Gui,8:+AlwaysOnTop -Caption Border +LastFound
- Gui,8:Color,00FF00
- WinSet,Transparent,100
- Gui,8:Show,x%x1% y%y1% w%Box_Width% h%Box_Height%
- sleep,2000
- Gui,1:Show
- Gui,8:Destroy
- }
- Switch_Tabs(ctrl){
- SetBatchLines,-1
- Loop 4 {
- if(pTab1[A_Index].Name=ctrl)
- Gui,% A_Index + 3 ":Show",x5 y55 w320 h105
- else
- Gui,% A_Index + 3 ":Hide"
- }
- if(!Turbo_Mode)
- SetBatchLines,10ms
- }
- Set_Click_Position(){
- While(!GetKeyState("LButton"))
- ToolTip,Click to set
- Tooltip,
- MouseGetPos,tx,ty
- Target_X:=tx,Target_Y:=ty
- GuiControl,6:,Position,% "x:"tx " y:" ty
- }
- Show_Message(Message_Number) {
- Gui,1:+OwnDialogs
- if(Message_Number=1)
- msgbox,,Dumbass Alert!!!!,You need to set a click location before you can preview where you are going to click!
- else if(Message_Number=2)
- msgbox,48,Missing Info!,You need to select a click position before you can start the auto clicker.
- else if(Message_Number=3)
- msgbox,48,Missing Info!,You need to select a target window.
- else if(Message_Number=4)
- msgbox,48,Missing Info!,Something is wrong with the box size.`nMake sure that the box size is greater than 4x4px
- .`nvalues under 20x20px should not be used.
- else if(Message_Number=5)
- MsgBox, 64, FAQ, Smart Clicker v1.1 By Hellbent aka CivReborn`n`nForget How To Set Up?`nVisit CivReborn On YouTube for setup video
- .`n`nHotkeys:`nThis is a auto pause auto clicker and has no need for most hotkeys
- .`nHowever`, you can exit this program at any time by pressing`nctrl+shift+alt+ESC
- }
- Set_Window(){
- i:=0
- Loop {
- ToolTip,Click on the target window twice to lock it.
- if(!GetkeyState("LButton")&&!isPressed)
- isPressed:=1
- else if(GetkeyState("LButton")&&isPressed=1){
- i++,isPressed:=0
- if(i>=2){
- WinGetTitle,Target,A
- ToolTip,
- break
- }
- }
- }
- GuiControl,5:,Target_Window,% Target
- return Target
- }
- Run_Auto_Clicker(){
- global
- Stop:=0
- if(Target_X=null){
- Show_Message("2")
- return
- }
- if(Target_Window=null&&Use_Target_Window=1){
- Show_Message("3")
- return
- }
- if(Box_Width<=4||Box_Height<=4||Box_Width=null||Box_Height=null){
- Show_Message("4")
- return
- }
- if(Turbo_Mode=1)
- SetBatchLines,-1
- else
- SetBatchLines,10ms
- While(Stop=0){
- if(Use_Target_Window=1){
- If WinActive(Target_Window)
- Click_Function()
- }else if(Use_Target_Window=0)
- Click_Function()
- }
- }
- Click_Function(){
- t8:=Box_Width//2,t9:=Box_Height//2
- MouseGetPos,tx,ty
- if(tx>=(Target_X-t8)&&tx<=(Target_X+t8)&&ty>=(Target_Y-t9)&&ty<=(Target_Y+t9)){
- Click, %Target_X% %Target_Y%
- if(Use_Click_Delay)
- sleep, %Click_Delay%
- }
- }
- pButton_StartUp(){
- SetTimer,Watch_Hover,10
- }
- Watch_Hover(){
- global
- if(Press_active=0){
- if(Hover_On=0){
- MouseGetPos,,,,ctrl,2
- loop,% pButton.Length() {
- GuiControlGet,cName,% pButton[A_Index].Window_Name ":Name",% ctrl
- cut:=Strlen(cName)
- StringLeft,bName,cName,cut-2
- if(bname=pButton[A_Index].Button_Name){
- pButton[A_Index].Button_Hover_On()
- Hover_On:=1,Active_Button:=bname,win:=pButton[A_Index].Window_Name
- return
- }
- }
- }else if(Hover_On=1){
- MouseGetPos,,,,ctrl,2
- GuiControlGet,cName,%win%:Name,% ctrl
- cut:=Strlen(cName)
- StringLeft,nBName,cName,cut-2
- if(NbName!=Active_Button){
- pButton[Active_Button].Button_Hover_Off()
- Hover_On:=0,Active_Button:=""
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement