Hekili Priority Helper

Hekili Priority Helper

44M Downloads

[FEATURE][WOTLK] Import APL rotation from wowsims

Entex opened this issue ยท 3 comments

commented

Before You Begin

  • I confirm that I have downloaded the latest version of the addon.
  • I am not playing on a private server.
  • I checked for an existing, open ticket for this request and was not able to find one.
  • I edited the title of this feature request (above) so that it describes the issue I am reporting.

Feature Request

I'd like the ability to import rotations from wowsims new APL rotation type since i'm usually simulating different rotations depending on my gear and talents. Right now I have to manually convert this to Hekili's addon.

I've checked the export feature from wowsims and the rotation is included.

Here's an example of JSON output from wowsims:

{
   ...
   "rotation": {
      "type": "TypeAPL",
      "prepullActions": [
        {"action":{"castSpell":{"spellId":{"spellId":66842}}},"doAtValue":{"const":{"val":"-3s"}}},
        {"action":{"castSpell":{"spellId":{"otherId":"OtherActionPotion"}}},"doAtValue":{"const":{"val":"-1s"}}}
      ],
      "priorityList": [
        {"action":{"autocastOtherCooldowns":{}}},
        {"action":{"condition":{"and":{"vals":[{"cmp":{"op":"OpLe","lhs":{"dotRemainingTime":{"spellId":{"spellId":49233}}},"rhs":{"const":{"val":"0s"}}}},{"cmp":{"op":"OpGe","lhs":{"remainingTime":{}},"rhs":{"const":{"val":"8s"}}}}]}},"castSpell":{"spellId":{"spellId":49233}}}},
        {"action":{"condition":{"cmp":{"op":"OpEq","lhs":{"auraNumStacks":{"auraId":{"spellId":53817}}},"rhs":{"const":{"val":"5"}}}},"castSpell":{"spellId":{"spellId":49238}}}},
        {"action":{"condition":{"not":{"val":{"auraIsActive":{"sourceUnit":{"type":"CurrentTarget"},"auraId":{"spellId":17364}}}}},"castSpell":{"spellId":{"spellId":17364}}}},
        {"action":{"castSpell":{"spellId":{"spellId":49231}}}},
        {"action":{"condition":{"cmp":{"op":"OpLt","lhs":{"totemRemainingTime":{"totemType":"Water"}},"rhs":{"const":{"val":"20s"}}}},"castSpell":{"spellId":{"spellId":66842}}}},
        {"action":{"castSpell":{"spellId":{"spellId":17364}}}},
        {"action":{"condition":{"and":{"vals":[{"cmp":{"op":"OpLe","lhs":{"dotRemainingTime":{"spellId":{"spellId":58734}}},"rhs":{"const":{"val":"100ms"}}}},{"not":{"val":{"auraIsActive":{"auraId":{"spellId":2894}}}}}]}},"castSpell":{"spellId":{"spellId":58734}}}},
        {"action":{"castSpell":{"spellId":{"spellId":61657}}}},
        {"action":{"condition":{"not":{"val":{"auraIsActive":{"auraId":{"spellId":49281}}}}},"castSpell":{"spellId":{"spellId":49281}}}},
        {"action":{"castSpell":{"spellId":{"spellId":60103}}}}
      ]
    }
    ...
}

Additional Information

https://wowsims.github.io/wotlk/

Contact Information

No response

commented

I actually have manually translated all of them as of about a week ago, but they all require some new expression support. I doubt that I'd make an importer/translator in-game for this, but I agree that wowsims seems poised as the simc equivalent for Wrath+.

commented

Ok, is there another way to import priority lists? I might write a converter if so.

commented

If you convert to the simc-like syntax used by the addon, you can import that.

Here's an example I hand-translated that won't work at this point:

# DeathKnightBlood: Unholy 2H SS APL
# https://wowsims.github.io/wotlk/deathknight/#
# September 2023

## Precombat
actions.precombat+=/unholy_presence,precombat_seconds=10,if=change_presence
actions.precombat+=/ghoul_frenzy,precombat_seconds=8
actions.precombat+=/horn_of_winter,precombat_seconds=1.5
actions.precombat+=/potion_of_speed,precombat_seconds=1

## Default
actions+=/mind_freeze
# Cast any other cooldowns (i.e., Racials) if they are not specified in this priority.
actions+=/use_cooldowns
# Use any trinkets that aren't otherwise specified.
actions+=/use_items
actions+=/icy_touch,if=dot.frost_fever.remains<3
actions+=/plague_strike,if=dot.blood_plague.remains<3
actions+=/blood_strike,if=buff.desolation.down
actions+=/berserking,if=buff.summon_gargoyle.up
actions+=/hyperspeed_acceleration,if=buff.summon_gargoyle.up|cooldown.summon_gargoyle.remains>50
actions+=/potion_of_speed,if=buff.summon_gargoyle.up|boss&cooldown.summon_gargoyle.remains>fight_remains
actions+=/army_of_the_dead,if=buff.summon_gargoyle.up
actions+=/blood_tap,if=buff.ghoul_frenzy.down&!blood_runes.left_ready
actions+=/ghoul_frenzy,if=blood_runes.left_death&buff.ghoul_frenzy.down&unholy_runes.all_death
actions+=/scourge_strike
actions+=/blood_strike
actions+=/empower_rune_weapon,if=buff.summon_gargoyle.up
actions+=/summon_gargoyle
actions+=/death_coil,if=cooldown.summon_gargoyle.remains
actions+=/blood_presence,if=change_presence&buff.unholy_presence.up&cooldown.summon_gargoyle.remains>0&buff.summon_gargoyle.down
actions+=/horn_of_winter

There are expressions here that the addon doesn't support at this time, but I did the exercise to see what I would need to support if I were to use their logic. Examples: blood_runes.left_ready, unholy_runes.all_death.