Skip to content

Instantly share code, notes, and snippets.

@utternerd
Last active October 17, 2023 17:36
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save utternerd/1aa1e218ac274c62445818a7e0675320 to your computer and use it in GitHub Desktop.
Save utternerd/1aa1e218ac274c62445818a7e0675320 to your computer and use it in GitHub Desktop.
Elder Scrolls Online Macro
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
; Elder Scrolls Online, Healing Templar Rotation Macro
; @utternerd on NA Server, matt@utternerd.org
; This works well, but could be improved.
; == Functionality ==
; Shift+1 Starts main rotation. (All rotations run indefinitely until stopped)
; Shift+2 Starts faster rotation.
; Shift+3 Starts a simple buff rotation, allowing buffs to stay up and spot heal instead.
; Shift+PageUp stops rotation while F11 stops rotation and tells group the healer is down.
; We generate a CSV log for statistical purposes after AHK exits, optional and controlled by debug variable.
; Healing Hotkeys
HealingSprings := 1 ; AoE heal (3s)
BreathofLife := 2 ; Breath of LIfe (instant big heal, spot heals, unused)
ExtendedRitual := 3 ; Wide HoT (24s)
RadiantAura := 4 ; FortIfication (18s)
MagesLight := 5 ; Mage's Light (unused)
; DPS Hotkeys
PuncturingSweep := 1 ; Cone AoE Damage (1.1s)
BlockadeofElements := 2 ; AoE Lightning Attack (6s)
PurifyingLight := 3 ; DoT + Crit Buff (6s)
BreathofLife := 4 ; Breath of Life (instant big heal, spot heals, unused)
MagesLight := 5 ; Mage's Light (unused)
; Misc. variables
ActionCount := 0
Debug := 1
SleepTime := 1000
TotalLoops := 0
TotalActions := 0
If (Debug = 1) {
OnExit("Logging")
}
Logging()
{
Global
FileOpen("TemplarMacroLogging.txt", "a")
FileAppend,
(
%TotalActions%,%TotalLoops% `n
), TemplarMacroLogging.txt
ExitApp
}
; Normal heal rotation.
+1::
Loop
{
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
If (Bail = 2) { ; Stop rotation and scream.
Send /g Healer down. {Enter}
ActionCount := 0
Bail := 0
Return
}
Sleep, %SleepTime%
If (ActionCount = 0 or ActionCount = 17 or ActionCount = 35 or ActionCount = 53) { ; Rebuff Radiant Aura
Send {%RadiantAura% 1}
ActionCount++
TotalActions++
Continue
}
If (ActionCount = 1 or ActionCount = 25 or ActionCount = 49) { ; Rebuff Extended Ritual
Send {%ExtendedRitual% 1}
ActionCount++
TotalActions++
Continue
}
If (ActionCount < 71) { ; Healing Springs
Send {%HealingSprings% 1}
ActionCount++
TotalActions++
Continue
}
If (ActionCount = 71) { ; Healing Springs
Send {%HealingSprings% 1}
ActionCount := 0
TotalActions++
TotalLoops++
Continue
}
}
; Double speed heal rotation; mana exhaustion possible.
+2::
Loop
{
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
If (Bail = 2) { ; Stop rotation and scream.
Send /g Healer down. {Enter}
ActionCount := 0
Bail := 0
Return
}
Sleep, %SleepTime%
If (ActionCount = 0 or ActionCount = 17 or ActionCount = 35 or ActionCount = 53) { ; Rebuff Radiant Aura
Send {%RadiantAura% 1}
ActionCount++
TotalActions++
Continue
}
If (ActionCount = 1 or ActionCount = 25 or ActionCount = 49) { ; Rebuff Extended Ritual
Send %ExtendedRitual%
ActionCount++
TotalActions++
Continue
}
If (ActionCount < 71) { ; Healing Springs
Send {%HealingSprings% 2}
ActionCount++
TotalActions++
Continue
}
If (ActionCount = 71) { ; Healing Springs
Send {%HealingSprings% 2}
ActionCount := 0
TotalActions++
TotalLoops++
Continue
}
}
; Simple buff rotation only.
+3::
Loop
{
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
If (Bail = 2) { ; Stop rotation and scream.
Send /g Healer down. {Enter}
ActionCount := 0
Bail := 0
Return
}
Sleep, %SleepTime%
If (ActionCount = 0 or ActionCount = 17 or ActionCount = 35 or ActionCount = 53) { ; Rebuff Radiant Aura
Send {%RadiantAura% 1}
ActionCount++
TotalActions++
Continue
}
If (ActionCount = 1 or ActionCount = 25 or ActionCount = 49) { ; Rebuff Extended Ritual
Send {%ExtendedRitual% 1}
ActionCount++
TotalActions++
Continue
}
If (ActionCount < 71) { ; Increment and let healer do work
ActionCount++
TotalActions++
Continue
}
If (ActionCount = 71) { ; Restart Loop
ActionCount := 0
TotalActions++
TotalLoops++
Continue
}
}
; DPS rotation
+4::
Loop
{
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
If (Bail = 2) { ; Stop rotation and scream.
Send /g Healer down. {Enter}
ActionCount := 0
Bail := 0
Return
}
; Lazy way
Sleep 500
Send {%PurifyingLight% 1}
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
Sleep 1000
Send {%BlockadeofElements% 1}
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
Sleep 1000
Send {%PuncturingSweep% 1}
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
Sleep 1100
Send {%PuncturingSweep% 1}
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
Sleep 1100
Send {%PuncturingSweep% 1}
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
Sleep 1100
Send {%PuncturingSweep% 1}
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
Sleep 1100
Send {%PuncturingSweep% 1}
Sleep 1100
Send {%PuncturingSweep% 1}
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
Sleep 600
; Sleep, %SleepTime%
; If (ActionCount = 0 or ActionCount = 5 or ActionCount = 10 or ActionCount = 15 or ActionCount = 20 or ActionCount = 25 or ActionCount = 30 or ActionCount = 35 or ActionCount = 40 or ActionCount = 45 or ActionCount = 50 or ActionCount = 55 or ActionCount = 65 or ActionCount = 70 or ActionCount = 75 or ActionCount = 80) { ;
; Send {%ReflectiveLight% 1}
; ActionCount++
; TotalActions++
; Continue
; }
; If (ActionCount = 1 or ActionCount = 7 or ActionCount = 13 or ActionCount = 19 or ActionCount = 25 or ActionCount = 31 or ActionCount = 36) { ; Rebuff Extended Ritual
; Send {%BlazingSpear% 2}
; ActionCount++
; TotalActions++
; Continue
; }
; If (ActionCount < 84) { ; Healing Springs
; Send {%PuncturingSweep% 1}
; ActionCount++
; TotalActions++
; Continue
; }
; If (ActionCount = 84) { ; Healing Springs
; Send {%PuncturingSweep% 1}
; ActionCount := 0
; TotalActions++
; TotalLoops++
; Continue
; }
}
;; Crafting loop.
+5::
Loop
{
If (Bail = 1) { ; Stop rotation.
ActionCount := 0
Bail := 0
Return
}
Send {R 1}
Sleep, %SleepTime%
}
; Flag to exit loop if we're done.
+PgUp::
Bail := 1
Return
; Flag to exit loop and scream if we're killed.
F11::
Bail := 2
Return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment