New melee macro which allows you to chose offense or defense. Borrowed some code (a lot of code) from Ices
Code:
#cs------------------------------------------------------
Simple melee AutoIt script by TeabagGus
Script requires two people with running the same script
There is a 5 second delay for the macro to start
Wand is slot 8
Heal Self is slot 1
Rest is slot 5
Weapon is slot 0
Shield is slot 9 if using a 1h and shield if not leave blank
#ce-------------------------------------------------------
Dim $a, $c, $d, $e, $f, $g, $h, $z, $x
Global $Paused
HotKeySet("`", "TogglePause")
HotKeySet("{ESC}", "Close")
$g = InputBox( "Question", "How many swings?", "20" )
$h = InputBox( "Question", "How long to parry? [milliseconds]" , "30000" )
$f = InputBox( "Question", "Offense or Defense first?", "Offense" )
$c = InputBox( "Question", "How Long to Rest? [milliseconds]", "180000" )
MsgBox( 0, "Alert", "Click OK then Alt + Tab into Darkfall to start the script." )
WinWaitActive ("Darkfall Online")
Sleep (1000)
While 1
CombatMode()
If $f = "Offense" Then
Offense()
Defense()
Else
Defense()
Offense()
EndIf
CombatMode()
Rest()
WEnd
Func Offense()
Sleep (1000)
$o = 0
While $o <= $g
Sleep (1000)
MouseClick ("left")
Sleep (1000)
$o = $o + 1
WEnd
Sleep (1000)
EndFunc
Func Defense()
Sleep (1000)
Send ("{V Down}")
Sleep ( $h )
Send ("{V Up}")
Sleep (1000)
EndFunc
Func Rest()
Send ("5")
Sleep (1000)
MouseClick ("left")
Sleep ( $c )
Send ("W")
Sleep (1000)
EndFunc
Func CombatMode()
Sleep (1000)
Send ("R")
Sleep (1000)
EndFunc
Func TogglePause( )
$Paused = NOT $Paused
While $Paused
sleep(100)
ToolTip('Script is "Paused"',0,0)
WEnd
ToolTip("")
EndFunc
Func EquipWeapon()
Sleep (1000)
Send ( $x ) ; Weapon
Sleep (1000)
Send ( $z ) ; Shield
Sleep (1000)
EndFunc
Func Close()
Exit
EndFunc