#Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_outfile=c:\Combo 2.exe #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI **** #include <GUIConstants.au3> #Include <Misc.au3> Opt("MouseClickDownDelay",9) Opt("SendKeyDownDelay",9) Global $hOffOnCheckbox, $sKey Global $iKeyPressed = 0 $sKey = 's' ;~ set combo to key "S" HotKeySet ($sKey, '_KeyPressed') $Form1 = GUICreate("Combo 2", 210, 139+24-100, 197, 127+139+25) $Label1 = GUICtrlCreateLabel("Press S To combo", 16, 8, 87, 17) $hOffOnCheckbox = GUICtrlCreateCheckbox("ON", 16+117, 4) GUICtrlSetState(-1, $GUI_CHECKED) $Progress4 = GUICtrlCreateProgress(16, 32, 150, 17) GUICtrlSetData(-1, RegRead("HKEY_CURRENT_USER\MuTools\Combo\","Skill4")/20) $Label6 = GUICtrlCreateLabel("ALabel6", 184, 32, 43, 17) GUICtrlSetData(-1, RegRead("HKEY_CURRENT_USER\MuTools\Combo\","Skill4")) $skill4 = Guictrlread($label6) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $hOffOnCheckbox If GUICtrlRead($hOffOnCheckbox) == $GUI_CHECKED Then HotKeySet ($sKey, '_KeyPressed') Else $iKeyPressed = 0 HotKeySet ($sKey) EndIf EndSwitch $guiarray = GUIGetCursorInfo($Form1) IF $guiarray[4] = 5 and $guiarray[2] = 1 Then GUICtrlSetData($Progress4,($guiarray[0] -16)/1.5) $skill4 = Round(($guiarray[0]-16)/1.5,0) Guictrlsetdata($Label6,$skill4) RegWrite("HKEY_CURRENT_USER\MuTools\Combo\","Skill4","REG_Sz",$skill4) EndIf If GUICtrlRead($hOffOnCheckbox) <> $GUI_CHECKED Then ContinueLoop If $iKeyPressed == 1 Then Send("w") Sleep($skill4) Send("q") EndIf WEnd Func _KeyPressed() If $iKeyPressed == 0 Then $iKeyPressed = 1 Else $iKeyPressed = 0 EndIf EndFunc |