Are you tired of searching for hours and hours after a good ProbablyEngine (PE) profile for your class, and wishing you could make your own? Don't worry, it's not as hard as you believe. After reading this post, you will be hopefully be able to start making your own rotation/profile!
First of all, this is a BASIC tutorial, and I can not teach you to make profiles that will bring you at the top of the damage meter in every single BG/Raid/LFR.
Let's jump straight into action and take a look at an example profile:
Code:
ProbablyEngine.rotation.register_custom(SPEC ID, "TEST PROFILE", {
--COOLDOWNS
{ "Avenging Wrath", "modifier.cooldowns" },
{ "Guardian of Ancient Kings", "modifier.cooldowns" },
--INQUISITION
{ "Inquisition", {
"!player.buff(Inquisition)",
"player.holypower <= 3" }},
{ "Inquisition", {
"player.buff(Inquisition).duration <= 3",
"player.holypower <= 3" }},
--DEFENSIVE
{ "Flash of Light", {
"player.health < 60" ,
"player.buff(Selfless Healer).count = 3" }},
{ "Sacred Shield", {
"!player.buff(Sacred Shield).duration <=3",
"player.health < 60" }},
--DPS
{ "Templar's Verdict", {
"player.holypower = 5",
"!modifier.multitarget" }},
{ "Divine Storm", {
"player.holypower >= 3",
"modifier.multitarget" }},
{ "Crusader Strike", "!modifier.multitarget" },
{ "Hammer of the Righteous", "modifier.multitarget" },
{ "Judgment" },
)
Don't panic yet! Let's go through one and one of those sections and take a closer look.
Code:
--COOLDOWNS
{ "Avenging Wrath", "modifier.cooldowns" },
{ "Guardian of Ancient Kings", "modifier.cooldowns" },
This is the cooldowns section, which is usually placed on top, because PE starts scanning from the top and if the ability in line 1 is available, that spell will be cast. After a spell is cast, it will bump back to top and try again. The first line that says «—COOLDOWN» is a comment. All lines that start with - - will be ignored by PE
All «lines» start and end with { and } everything between those is the conditions. In here we set the «rules» for when the spell will be cast or not. The general syntax is like this { «spell», «condition», «target» }, to tell PE that the condition is finished we use a comma. If you specify no target in the «target» condition, the spell will be cast on yourself.
In this short example, the first thing PE will check is if the cooldowns modifier in PE ingame interface is checked (condition: "modifier:cooldowns") If yes; it will cast Avenging Wrath (AW). After AW is cast, it will go back to search for the next spell. Also this time, PE will first check if cooldowns is toggled in the interface, and check if AW is available. Since AV was cast in the previous sequence, it will now be on cooldown, so PE will ignore it go to the next line in the script. Same checks go for Guardian of Ancient Kings (GoAK).
I hope you start to understand the very basics now, so lets move on to the next section in the script: The defensive abilities. If you are dead, you do 0 dps, so this is usually prioritized over DPS spells as well.
Code:
—DEFENSIVE
{ "Flash of Light", {
"player.health < 60" ,
"player.buff(Selfless Healer).count = 3" }},
{ "Sacred Shield", {
"!player.buff(Sacred Shield)",
"player.health < 60" }},
The first check we do for this demo is if flash of light (FoL) should be cast. Note that here, we got 2x conditions that must be fulfilled before FoL will be cast. First we start with the { and then we specify the spell: «Flash of Light» and since we have 2 conditions this will be called a multiple rule so we must tell PE that both of those must be true before FoL is ready to be launched. First PE will check player health (player.health) and if this is less than 60%, it will try the next condition. Do we have 3 stacks (.count = 3) of Selfless Healer? If yes here as well, both conditions return true, and FoL will be cast. Since no target is specified, you will cast FoL on yourself.
Next check is if Sacred Shield (SS, talented skill) should be cast. Note that in this case, we will start by checking if we already have SS up, and the way we tell PE that we only want to cast this if we don’t already have SS up is by putting a ! before the condition ("!player.buff(Sacred Shield),
. This means the spell will only be cast if the check return «false» If we translate that to «normal language» it will be something like «! = if not player buff sacred shield is up», go to next nested condition. Is player health less than 60% yes/no? If the first condition return «false» and the second condition return «true), SS will be cast.
Now lets start on the fun part. Adding the DEEPS!
Code:
{ "Templar's Verdict", {
"player.holypower = 5",
"!modifier.multitarget" }},
{ "Divine Storm", {
"player.holypower >= 3",
"modifier.multitarget" }},
{ "Crusader Strike", "!modifier.multitarget" },
{ "Hammer of the Righteous", "modifier.multitarget" },
{ "Judgment" },
)
Translated this means:
1: Cast Templar’s Verdict if multitarget modifier is NOT toggled «!modifier.multitarget", AND we got 5 holy power available «player.holypower = 5»
2: Cast Divine Storm if multitarget modifier is toggled AND we got 3 or more holy power available
3: Cast Crusader Strike if multitarget modifier is NOT toggled
4: Cast Hammer of the Righteous if multitarget modifier is toggled
5: If none of the above is available, cast Judgement.
Sample codes:
Code:
--Target boss for this script.
--Cast Penance on tank if he does not have Grace buff (increased healing), else cast penance on target.
--Cast greater heal on tank (Who the boss is targeting) if HP is less than 50%
--Nuke boss for attonement heals if 1-3 is not available.
{ "Penance", "!targettarget.buff(Grace)", "targettarget" },
{ "Penance" },
{ "Greater Heal", "targettarget.health < 50", "targettarget" },
{ "Holy Fire" },
{ "Smite" },
More attunement stuff:
Code:
--PW: Shield and renew on yourself if HP goes lower than 70%
--Prayer of Mending cast on boss target whenever it goes off cooldown.
--Pain Suppression on boss target if lower than 30% HP
--Inner focus cast on cooldown and prayer of healing on boss target if multitarget modifier is toggled. Greater heal on boss target if not multitarget toggle.
--Flash Heal on self if HP drop lower than 25%
--Divine Star cast on cooldown if multitarget toggle is enabled.
{ "Power Word: Shield", {
"player.health < 70 "
,"!player.debuff(Weakened Soul)"}},
{ "Renew", {
"!player.buff(Renew)"
,"player.health < 70" }},
{ "Prayer of Mending", "targettarget.debuff(Weakened Soul)", "targettarget"},
{ "Pain Suppression", "targettarget.health < 30", "targettarget" },
{ "Inner Focus" },
{ "Greater Heal", "player.health < 60" },
{ "Greater Heal", { "player.buff(Inner Focus)", "!modifier.multitarget" }, "targettarget"},
{ "Prayer of Healing", { "player.buff(Inner Focus)", "modifier.multitarget" }, "targettarget"},
{ "Flash Heal", "player.health < 20"},
{ "Divine Star", "modifier.multitarget" },
Retribution Paladin T16 bonus
Code:
{ "Divine Storm", "player.buff(Divine Crusader)"},
Light's Hammer (paladin talent, ground effect) cast on cursor position when left control is pressed
Code:
{ "Light's Hammer", "modifier.lcontrol", "ground" },
Further reading:
Official PE Tutorial
Thanks to PhelpsBen, creator of PE and the rest of guys at PE forum for helping me when I’m stuck on my profiles.
If you're wondering about something, or would like an example code for a rule, don't hesitate to ask in this thread!