bin grade dabei mir einen kleinen Bot zu basteln, der mich alarmiert (pn Bot) wenn ich angeschrieben werde und mich bei einer bestimmten Prozentzahl meines Lebens und Mana automatisch Healt.
Hier der Bot:
Code:
#include <Sound.au3>
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
HotKeySet("{insert}", "_start")
HotKeySet("{delete}", "_stop")
HotKeySet("{end}", "_ende")
HotKeySet("{F8}", "_OL")
HotKeySet("{F9}", "_UR")
HotKeySet("{F10}", "_settings")
Global $OL
Global $UR
Global $OL[2]
Global $UR[2]
Global $Sound, $sound01, $sound2, $sound21
Global $HPp[2]
Global $MPp[2]
$HPp[0] = IniRead("Settings.ini", "HP-Regeneration", "HP(0)", "")
$HPp[1] = IniRead("Settings.ini", "HP-Regeneration", "HP(1)", "")
$MPp[0] = IniRead("Settings.ini", "MP-Regeneration", "MP(0)", "")
$MPp[1] = IniRead("Settings.ini", "MP-Regeneration", "MP(1)", "")
$OL[0] = IniRead("Firefoxcramblerc.ini", "Mousegetpos", "OL_0", "")
$OL[1] = IniRead("Firefoxcramblerc.ini", "Mousegetpos", "OL_1", "")
$UR[0] = IniRead("Firefoxcramblerc.ini", "Mousegetpos", "UR_0", "")
$UR[1] = IniRead("Firefoxcramblerc.ini", "Mousegetpos", "UR_1", "")
While 1
Sleep(1000)
WEnd
Func _settings()
#Region ### START Koda GUI section ### Form=c:\dokumente und einstellungen\alex\desktop\autoit\newfirefoxcramblerc\settform.kxf
$SettForm = GUICreate("Settings", 176, 228, 301, 159)
$SettLabel = GUICtrlCreateLabel("Settings", 8, 8, 152, 38)
GUICtrlSetFont(-1, 18, 800, 4, "Ravie")
GUICtrlSetColor(-1, 0xFF0000)
$HP25 = GUICtrlCreateRadio("25%", 16, 80, 41, 17)
$HP50 = GUICtrlCreateRadio("50%", 64, 80, 41, 17)
$HP75 = GUICtrlCreateRadio("75%", 112, 80, 41, 17)
$HPlabel = GUICtrlCreateGroup("HP-Potts bei:", 8, 56, 161, 49)
GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif")
GUICtrlCreateGroup("", -99, -99, 1, 1)
$MP25 = GUICtrlCreateRadio("25%", 16, 152, 41, 17)
$MP50 = GUICtrlCreateRadio("50%", 64, 152, 41, 17)
$MP75 = GUICtrlCreateRadio("75%", 112, 152, 41, 17)
$MPlabel = GUICtrlCreateGroup("MP-Potts bei:", 8, 128, 161, 49)
GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif")
GUICtrlCreateGroup("", -99, -99, 1, 1)
$ButtonOK = GUICtrlCreateButton("OK", 8, 184, 73, 41, $WS_GROUP)
$ButtonCancel = GUICtrlCreateButton("Abbrechen", 96, 184, 73, 41, $WS_GROUP)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $HP25
$HPp[0] = 272
$HPp[1] = 59
IniWrite("Settings.ini", "HP-Regeneration", "HP(0)", $HPp[0])
IniWrite("Settings.ini", "HP-Regeneration", "HP(1)", $HPp[1])
Case $HP50
$HPp[0] = 303
$HPp[1] = 59
IniWrite("Settings.ini", "HP-Regeneration", "HP(0)", $HPp[0])
IniWrite("Settings.ini", "HP-Regeneration", "HP(1)", $HPp[1])
Case $HP75
$HPp[0] = 336
$HPp[1] = 59
IniWrite("Settings.ini", "HP-Regeneration", "HP(0)", $HPp[0])
IniWrite("Settings.ini", "HP-Regeneration", "HP(1)", $HPp[1])
Case $MP25
$MPp[0] = 272
$MPp[1] = 79
IniWrite("Settings.ini", "MP-Regeneration", "MP(0)", $MPp[0])
IniWrite("Settings.ini", "MP-Regeneration", "MP(1)", $MPp[1])
Case $MP50
$MPp[0] = 300
$MPp[1] = 79
IniWrite("Settings.ini", "MP-Regeneration", "MP(0)", $MPp[0])
IniWrite("Settings.ini", "MP-Regeneration", "MP(1)", $MPp[1])
Case $MP75
$MPp[0] = 336
$MPp[1] = 79
IniWrite("Settings.ini", "MP-Regeneration", "MP(0)", $MPp[0])
IniWrite("Settings.ini", "MP-Regeneration", "MP(1)", $MPp[1])
Case $ButtonOK
GuiDelete()
Case $ButtonCancel
GUIDelete()
EndSwitch
WEnd
EndFunc
Func _OL()
$OL = MouseGetPos()
IniWrite("Firefoxcramblerc.ini", "Mousegetpos", "OL_0", $OL[0])
IniWrite("Firefoxcramblerc.ini","Mousegetpos", "OL_1", $OL[1])
EndFunc ;==>OL
Func _UR()
$UR = MouseGetPos()
IniWrite("Firefoxcramblerc.ini", "Mousegetpos", "UR_0", $UR[0])
IniWrite("Firefoxcramblerc.ini","Mousegetpos", "UR_1", $UR[1])
EndFunc ;==>UR
Func _start()
While 1
Send("{Space}")
Sleep(250)
Send("x")
$pic = PixelSearch($OL[0], $OL[1], $UR[0], $UR[1], 0xFFFFFF)
$pic2 = PixelSearch($OL[0], $OL[1], $UR[0], $UR[1], 0xF77C04)
$hpreg = PixelGetColor($HPp[0], $HPp[1])
$mpreg = PixelGetColor($MPp[0], $MPp[1])
If IsArray($pic) Then
$sound = _SoundOpen(@WindowsDir & "\media\sound.wav", $sound01)
_SoundPlay($sound, 1)
_SoundClose($sound)
$picpic = PixelSearch($OL[0], $OL[1], $UR[0], $UR[1], 0xFFFFFF)
If IsArray($picpic) Then
$sound2 = _SoundOpen(@WindowsDir & "\media\tada.wav", $sound21)
_SoundPlay($sound2, 1)
_SoundClose($sound2)
ExitLoop
_stop()
Else
EndIf
ElseIf IsArray($pic2) Then
$sound = _SoundOpen(@WindowsDir & "\media\sound.wav", $sound01)
_SoundPlay($sound, 1)
_SoundClose($sound)
$picpic2 = PixelSearch($OL[0], $OL[1], $UR[0], $UR[1], 0xF77C04)
If IsArray($picpic2) Then
$sound2 = _SoundOpen(@WindowsDir & "\media\tada.wav", $sound21)
_SoundPlay($sound2, 1)
_SoundClose($sound2)
ExitLoop
_stop()
Else
EndIf
[COLOR="Red"] ElseIf $mpreg = 4539973 Then
Sleep(1000)
Send("6")
Send(2000)[/COLOR]
ElseIf $hpreg = 1447190 Then
Sleep(1000)
Send("4")
Sleep(2000)
Else
EndIf
WEnd
EndFunc ;==>_start
Func _stop()
While 1
Sleep(1000)
WEnd
EndFunc ;==>_stop
Func _ende()
Exit
EndFunc ;==>_ende
Bin schon ne Weile bei der Lösung des Problems, kam aber bis jetzt nicht weiter.
Mfg, HipTheHop
P.S: Für allgemeine Verbesserungen des Progs bin ich immer offen






nämlich nicht weiter^^
