
So Ive been working on this macro for Pathfinder 2e for a while now, and I can't seem to crack the final step. I am relatively new to coding in general, and really have just brute forced my way through most macros Ive written in my games, and unfortunately this one has me beat. My player is the party healer, and has a a multitude of feats that can modify the way the Heal spell will function for them on the fly. I figured rather than them having to keep track of everything, Id whip up a handy flow-chart style drop down menu option, so each time they cast it they can choose which version it is, rather than having a different spell button for each version (and then consequently for each level) The varieties of the spell are as follows: Healing or Damage, then under those headings we have Healing (touch range), Healing (single target 30ft range), Healing (60ft Cone Aoe), Healing (30ft Aoe) Damage (touch range), Damage (single target 30ft range), Damage (60ft Cone Aoe), Damage (30ft Aoe) The problem lies in the fact that when any of the Aoe options are chosen, the spell does do BOTH Healing and Damage (depending on the type of the target in the area). Normally this is not a problem as the amount is equal by default (healing and damage are the same number), but due to another feat they have, when dealing damage they add the level of the spell to the amount they deal (and also sets them on fire for ongoing damage equal to that same additional amount) So for example, an AoE usage would Heal allies for 1d10, and Damage enemies for 1d10+1 (plus set them on fire for 1 ongoing) Below is the macro text I've managed so far. It works GREAT for every other aspect, but I can't figure out how to modify it so that the Damage amount is the SAME ROLL as the Heal amount +1 (or in the case of the Damage version, the Heal amount is Damage roll -1) Any help would be greatly appreciated (bonus points if you know how to get the bonus ongoing fire damage to auto match the bonus regular damage so I dont have to change the number multiple times per level of the spell). As I mentioned, Im new to coding so Im sure there is a far easier and cleaner way to have written the code below, but if it aint broke and all that.... ?{Purpose of Spell| Healing, ?{Range of Healing| Touch (1 Action), Touch Heal Heals [[1d10]]| 30ft Single Target (2 Actions), 30ft Single Target Heal Heals [[1d10+8]]| 60ft Cone AOE (2 Actions), 60ft Cone AOE Heals living creatures in cone for [[1d10]] %NEWLINE% %NEWLINE% ALSO damages Undead and Fiends in cone (basic Fort save DC @{spell_dc}) for $[[0]] positive damage PLUS setting them on fire for [[1]] persistent Fire damage| 30ft AOE (2 Actions), 30ft AOE Emanation Heals living creatures in emanation for [[1d10]] %NEWLINE% %NEWLINE% ALSO damages Undead and Fiends in emanation (basic Fort save DC @{spell_dc}) for $[[0]] positive damage PLUS setting them on fire for [[1]] persistent Fire damage } | Damage, ?{Range of Damage| Touch (1 Action), Touch Damage Basic Fortitude DC:[[@{spell_dc}]] Damage:[[1d10]] positive PLUS setting them on fire for [[1]] persistent Fire damage| 30ft Single Target (2 Actions), 30ft Single Target Damage Basic Fortitude DC:[[@{spell_dc}]] Damage:[[1d10]] positive PLUS setting them on fire for [[1]] persistent Fire damage| 60ft Cone AOE (2 Actions), 60ft Cone AOE Basic Fortitude DC:[[@{spell_dc}]] Damage:[[1d10]] positive %NEWLINE% PLUS setting them on fire for [[1]] persistent Fire damage %NEWLINE% %NEWLINE% ALSO Heals all living creatures in the cone for $[[1]]| 30ft AOE (2 Actions), 30ft AOE Basic Fortitude DC:[[@{spell_dc}]] Damage:[[1d10]] %NEWLINE% PLUS setting them on fire for [[1]] persistent Fire damage %NEWLINE% %NEWLINE% ALSO Heals all living creatures in the cone for $[[1]]} }