#include <NomadMemory.au3>
#include <WoWConstants3.3.5a.au3>
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#Region Globale Werte / Pause Funktion
Global $Paused
;----------ADDRESSWERTE Aktuelle Position-------------
Global $xaddresse = "0x00ADF4E4"
Global $yaddresse = "0x00ADF4E8"
Global $zaddresse = "0x00ADF4EC"
Global $raddresse = "0x00BEBA70"
Global $infightaddresse = "0x122B767C"
;-----------------------------------------------------
;----------WOW Process öffnen-------------------------
Global $ProcessId = ProcessExists("wow.exe")
Global $Handle = _MemoryOpen($ProcessId)
Global $Base = _MemoryGetBaseAddress($ProcessId, 1)
;-----------------------------------------------------
;------------WAYPOINT DATEI---------------------------
Global $speicherort = @

ir
Global $filename = "\Waypoints.ini"
Global $SectionX = "X"
Global $SectionY = "Y"
Global $Total = "Total"
Global $value = ""
$count = 1
$runcount = 1
;-----------------------------------------------------
HotKeySet("{F9}", "_addwaypoint")
HotKeySet("{F8}", "Botpause")
Func Botpause()
$Paused = Not $Paused
While $Paused
Sleep(100)
ToolTip('Bot pausiert"', 0, 0)
WEnd
ToolTip("")
EndFunc
;----------------Erstellt die Waypointer Datei------------------------------------
if FileExists ($speicherort & $filename) then FileDelete ($speicherort & $filename)
IniWrite ($speicherort & $filename,$SectionX,"",$value)
IniWrite ($speicherort & $filename,$SectionY,"",$value)
IniWrite ($speicherort & $filename,$Total,"",$value)
;---------------------------------------------------------------------------------
#EndRegion
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("WOW Waypointer", 347, 147, 192, 124)
$addw = GUICtrlCreateButton("Add Waypoint", 104, 56, 121, 33)
$run = GUICtrlCreateButton("Run", 104, 16, 121, 25)
$Label1 = GUICtrlCreateLabel("Waypoints:", 16, 112, 57, 17)
$wanzahl = GUICtrlCreateLabel("0", 80, 112, 80, 17)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $run
_run()
Case $addw
_addwaypoint ()
EndSwitch
WEnd
Func _run () ;===> Läuft alle gesetzten Wegpunkte ab
$fullwaypoints = IniRead ($speicherort & $filename, $Total, "total", "")
for $i = $fullwaypoints to 1 step -1
sleep (200)
$nextX = IniRead ($speicherort & $filename, $SectionX, $runcount, "")
$nextY = IniRead ($speicherort & $filename, $SectionY, $runcount, "")
_MoveTo($nextX, $nextY)
$runcount = $runcount +1
Next
$runcount = 1
_run ()
EndFunc
Func _addwaypoint () ;===> Fügt einen Waypoint hinzu
ToolTip ("AddWaypoint" ,0,0)
$posx = _GetX()
$posy = _GetY()
IniWrite ($speicherort & $filename,$SectionX,$count,$posx)
IniWrite ($speicherort & $filename,$SectionY,$count,$posy)
IniWrite ($speicherort & $filename, $Total, "total", $count)
GUICtrlSetData ($wanzahl,$count)
$count = $count + 1
EndFunc
Func _MoveTo($X, $Y) ;===> Diese Funktion bewegt den Charakter zu den Waypoints
_MemoryWrite($CTM_Base + $CTM_X, $Handle, $X, 'float')
_MemoryWrite($CTM_Base + $CTM_Y, $Handle, $Y, 'float')
_MemoryWrite($CTM_Base + $CTM_Action, $Handle, "4", 'int')
While 1
ToolTip ("While",0,0)
$posx = _GetX()
If $posx +1 = $X or $posx -1 = $X Then
ExitLoop
EndIf
WEnd
EndFunc
Func _GetX() ;===> Gibt Charakter Pos X zurück
Return Floor (_MemoryRead($Base + $xaddresse, $Handle, "float"))
EndFunc
Func _GetY() ;===> Gibt Charakter Pos Y zurück
Return Floor (_MemoryRead($Base + $yaddresse, $Handle, "float"))
EndFunc