Guides and Triggers
Where it started
With version 0.18.0 I redid the whole trigger engine to a whole new paradigm. Well, newish - we'll get to that. Since most players are coming from ACT, they have their triggers stored in XML format.
<Trigger Active="T" R="You feel a synergy with your group." SD="Synergy Succes" ST="3" CR="F" C="General" T="F" TN="" Ta="F" />
These are then organized by category, that's the C="General" above. The category also serves to limit triggers by zone, if the category matches the current zone, then the trigger fires (if this is enabled with CR="T").
What this means is that the triggers are a big XML file that only have their category to group them and they can only be individually edited using the ACT custom trigger UI.
I found this cumbersome to say the least.
Timers are also stored in XML.
<Spell N="Heartbound" T="1800" OM="F" R="F" A="F" WV="30" RD="T" M="F" Tt="" FC="-16776961" RV="-100" C=" General" RC="F" />
You can see them by clicking the 'Show Timers' button, and then right-clicking on the empty box that appears. Triggers can name a timer, allowing a timer to fire when a trigger goes off.
This I found even more cumbersome. In fact, refusing to understand how ACT timers work is one of the reasons I started making doctorparser. In the process, ironically - I learned quite a bit about how they work, so that I could support their conversion to a new system.
The New System - Triggers
In Doctorparser, triggers (and timers and lot more) are written in a custom timeline language, that lives inside of a markdown file, called a Guide. I know that sounds complicated, bear with me just a moment to explain it.
Here is the same synergy trigger from above, written in the timeline language.
trigger line /You feel a synergy with your group./ tts "Synergy Succes"
That's it, the whole thing. That's not a 'representation' of the trigger - this is what doctorparser reads.
trigger means, this is a trigger. We are going to catch something, and then act on it.
line means, we are going to look at lines in the log.
/You feel a synergy with your group./ Anything inside of the forward slashes is what we are matching. Capture groups (including named capture groups) are fully supported.
tts "Synergy Success" We are going to use text to speech (tts) to say "Synergy Success".
When importing triggers from ACT, all of the triggers are converted to this format, and placed in an imported.md file that live in the /timelines/ folder next to your doctorparser.exe. This will work for most people who just want all of their triggers in a big list. Doctorparser organizes them by category just the same and you can carry on about your business.
However - it is missing the second part of the whole system, and that is Guides.
The New System - Guides
A Guide is a markdown file that includes blocks of timeline code. The imported.md file that all imported ACT triggers are placed in is a Guide, but the format can be much much more. Rather than go through every single bit of how a Guide and the Timeline language are paired together, here is my Guide for the RoC T3 raid zone The Unknown: Steppes of Oblivion
---
zone: The Unknown: Steppes of Oblivion
---
# The Unknown: Steppes of Oblivion
## Triggers [Raid]
```timeline
start always
```
## Y'lus, Servant of the Consumer (off) [Raid]
#off
Mob lies. After initial scout joust, just have everyone but the tanks joust.
A mushroom needs to be killed under the eye, so someone can stand on the mushroom and click the eye.
Tanks get a curse and need to move away from the raid to be cured.
```timeline
start engage "Y'lus, Servant of the Consumer"
stop death boss
stop idle 30
```
### back in
```timeline
trigger line /massive attack/ tts "back in"
```
### scouts back in
```timeline
trigger line /nearby \[Scouts\]/ tts "scouts back in"
```
### $target joust $distance out
```timeline
trigger line /party closer than (?<distance>\S+) targeting \[(?<target>[^\]]+)\]/ tts "$target joust $distance out"
```
### $target joust $distance in
```timeline
trigger line /party further than (?<distance>\S+) targeting \[(?<target>[^\]]+)\]/ tts "$target joust $distance in"
```
## Emnitiun, Quandion, Dovinita [Raid]
Beckons (Call): go to the one that beckoned. Gazes (Gaze) and scowls (Hatred): go where the map says.
```timeline
start engage "Emnitiun"
stop idle 30
map "beckons"
Emnitiun "Emnitiun"
Quandion "Quandion"
Dovinita "Dovinita"
map "gazes"
Emnitiun "Quandion"
Quandion "Dovinita"
Dovinita "Quandion"
map "scowls"
Emnitiun "Dovinita"
Quandion "Emnitiun"
Dovinita "Emnitiun"
# Who goes where: a row per curse, until it's removed. One player can
# have two at once.
show "Trio" per "$player $mob"
begin line /(?<mob>Emnitiun|Quandion|Dovinita)(?::\w+\\\/a)? (?<verb>beckons|gazes|scowls).*? (?<player>\w+)!/
end line /"(?<mob>Emnitiun|Quandion|Dovinita)'s (?:Call|Gaze|Hatred)" has been successfully removed from (?<player>\w+)!/
text "$player ➔ ${$verb:$mob}"
```
### Safe
```timeline
trigger line /"(?:Emnitiun|Quandion|Dovinita)'s (?:Call|Gaze|Hatred)" has been successfully removed from (?<YOU>\w+)!/ tts "Safe"
```
### Go to
```timeline
trigger line /(?<mob>Emnitiun|Quandion|Dovinita)(?::\w+\\\/a)? (?<verb>beckons|gazes|scowls).*? (?<YOU>\w+)!/ tts "Go to ${$verb:$mob}"
```
## Yon-Solhoth the Corrupted [Raid]
Powerful Purge is the knockback.
Channeler is priority, Loyalite summoned after it dies.
Kill the other adds if they aren't being splashed down.
```timeline
start engage "Yon-Solhoth the Corrupted"
stop death boss
stop idle 30
cycle every 66.6
00:14 "Corruption En Masse" sync hit ~4s
00:25 "Punishment Afar" sync hit
00:36 "Curse" sync chat /^[A-Za-z]+(?:_\w+)? CURSE$/
01:10 "Powerful Purge" sync hit
alert before "Powerful Purge" 4 tts "Joust Out"
alert after "Powerful Purge" 2 tts "Back in"
alert before "Curse" 5 tts "Curse Soon"
# Add Cycle
cycle every 3:00
02:41 "Channeler Up" sync emote /Channeler is summoned to protect/ ~10
03:26 "Loyalite Up" seen emote /Loyalite of the Consumer is summoned to protect/ ~5,15
alert before "Channeler Up" 5 tts "Channeler Incoming"
alert seen "Channeler Up" tts "Channeler Up"
alert seen "Loyalite Up" tts "Loyalite Up"
```
This is what it means to move past a long list of triggers with only a category to group them.
One Guide per Zone
This means no more digging for triggers. A zone is one markdown file, and every trigger for that zone is in it. Triggers that go off in the zone are in this section:
## Triggers [Raid]
```timeline
start always
```
The [Raid] tag can be used to distinguish between versions of a zone. [Solo], [Heroic] or even [Untold 31] for Untolds at or above level 31 are all supported.
Triggers per Named Mob
Doctorparser knows when you are fighting a named mob and can scope triggers to only fights against it.
When you fight a new mob Doctorparser will automatically make a Guide for that zone with that mob in it, with a blank timeline block, ready for triggers.
Advanced Triggers
Some features of the timeline language can't be generated with the trigger maker in the app. These must be written out (although there are tools to assist in the app).
In the trio fight, there are three names, and each of them has three curses they cast on players. My raid force dealt with this by making nine different triggers, and then a 10th trigger to let alert you that your curse was cleared.
Doctorparser puts the whole fight into that one block, and it shows everyone who has to go where.
Cact-bot Style Cycles
cycle every 66.6
00:14 "Corruption En Masse" sync hit ~4s
00:25 "Punishment Afar" sync hit
00:36 "Curse" sync chat /^[A-Za-z]+(?:_\w+)? CURSE$/
01:10 "Powerful Purge" sync hit
alert before "Powerful Purge" 4 tts "Joust Out"
alert after "Powerful Purge" 2 tts "Back in"
alert before "Curse" 5 tts "Curse Soon"
This is how you are able to keep track of a mob's casting cycle. In the Yon Solhoth fight, he casts Corruption En Masse 14 seconds into the fight, starting the cycle. At 25 seconds Punishment Afar is cast, then the curse and then the knockback Powerful Purge and the whole thing repeats on a 66.6 second cycle. The keyword sync means that when that ability lands, the cycle is synced, so that the timers can never get out of sync with each other.
Any players familiar with FFXIV addon Cactbot and their timelines can see where the inspiration came from.
The Strat in Plain English
## Yon-Solhoth the Corrupted [Raid]
Powerful Purge is the knockback.
Channeler is priority, Loyalite summoned after it dies.
Kill the other adds if they aren't being splashed down.
This keeps all the information about a fight in one place. The strat, the timers, the triggers and the cycles all in one markdown file. Authored by an expert, shared with the raid force. Everyone on the same page with the same information.
Sharing
These guides are a bit too big to share like an ACT trigger, so in the app is the ability to write a command to a text file and do a do_file_commands dp-share.txt to share it. This needs some testing, but it does zip the file and encode it to be read back into it's original file on the recipient's end. It should work so let me know in the discord if you tried it and had any issues!
Still Shiny
This is a big change to how triggers are kept, in timeline blocks in mardown Guides. I don't know if it will even catch on, and until it gets more widely used there are bound to be some bugs in there somewhere. The language and syntax has been iterated a few times and will not be changing. Additions may come but everything that's there now is pretty set in stone - you can count on it working.
It's a lot to learn, and even I have trouble grasping it all sometimes, so documentation and tutorials are important and what's there now will hopefully be improved.
A few features are still baking in the oven. The prose part of each Guide isn't anywhere in the app at the moment, just in the file, but the plan is to put it on the live page as part of a 'zone companion' feature that is still in the works.
There are currently two ways to use the app to try and figure out the timings of a boss's cycle, in story mode and from the trigger page. Those will be combined and improved at some point, but they only produce a rough draft at the moment.
The last thing is the ability to sync guides from a central repository like a github repo. That's coming soonisn too.
Questions or thoughts? Talk about it on Discord.