Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

Power Cards Help

The basic macro works but I am trying to add a bit that applies the damage bonus from Genie's Wrath. (Bottom two lines) What am I doing wrong? !power {{   --name|Eldritch Blast   --leftsub|Evocation Cantrip   --rightsub|120ft Range   --Attack:|[[ [$Atk] ?{Attack|Standard,1d20|Advantage,2d20kh1|Disadvantage,2d20kl1} + @{spell_attack_bonus} ]]     --soundfx|_audio,play,nomenu|Thunder Strike   --?? $Atk < @{target|NPC_AC} AND $Atk.base <> 1 ?? !Miss:|YOU MISSED!   --?? $Atk >= @{target|NPC_AC} AND $Atk.base <= 19 AND $Atk.base <> 1 ?? Damage:|[[ [$Dmg] 1d10 + @{charisma_mod} ]] Force   --?? $Atk >= @{target|NPC_AC} AND $Atk.base == 20 ?? You got a Critical Hit!|[[ [$CritDmg] 3d8 + @{strength_mod} + 1 ]]   --?? $Atk.base == 1 ?? !Fumble:|/roll 1t[Crit-Fumble-Table]   --?? $Atk >= @{target|NPC_AC} AND $Atk.base <> 20 ?? alterbar1|_target|@{target|token_id} _bar|1 _amount|-[^Dmg] _show|all   --?? $Atk.base == 20 ?? alterbar2|_target|@{target|token_id} _bar|1 _amount|-[^CritDmg] _show|all   --Bonus Damage:|[[ [$GR] ?{Genie’s Wrath|Yes,2|No,0} ]]   --?? $Atk >= @{target|NPC_AC} AND $GR == 2 ?? alterbar3|_target|@{target|token_id} _bar|1 _amount|-2 _show|all }} Normal 0 false false false EN-GB X-NONE X-NONE /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-parent:""; mso-padding-alt:0cm 5.4pt 0cm 5.4pt; mso-para-margin:0cm; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri",sans-serif; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin; mso-bidi-font-family:"Times New Roman"; mso-bidi-theme-font:minor-bidi; mso-fareast-language:EN-US;}
1614306618

Edited 1614306633
Do they select yes or no for genre's wrath every time this is used? If so just put the ?{genies wrath} in the standard damage lines.
I could just put in a +2 to the other damage lines but I want to work out how to include it optionally each time as then I could apply the same principle to hexes, hunters mark, zephyr strike, sneak attacks etc.
Try a hroll line before the attack line Ex. --hroll| [#[ [$GR] ?{Genie’s Wrath|Yes,2|No,0} ]#]   --?? $Atk >= @{target|NPC_AC} AND ^GR == 2 ?? alterbar3|_target|@{target|token_id} _bar|1 _amount|-2 _show|all }}
Are you using a custom character sheet?
No, just the standard one.
Didn't work sadly, Kyle M. I'm sure it's possible but I just don't know how! :)
Ill work on it and let you know later :)
This is an example of how to use an API from within Powercards, I think you need to add the "api_alterbars|" or "api_alter_bars|" before alterbar 3.
--api_token-mod|_id
If you look up advanced api usage in the powercards wiki, that should be able to help you more.
The alterbars bit works fine in the rest of the macro and applies damage correctly. That doesn't seem to be the problem. If I run the above code without the two lines in red it works exactly as intended. The problem apparently arises from my attempt to assign a value to the variable $GR.
Try making the GR into a roll instead of just a flat number.    --Bonus Damage:|[[ [$GR] 0d0 + ?{Genie’s Wrath|Yes,2|No,0} ]]
I was literally thinking that as $Atk is defined by a dice roll and that one works.
Perfect Erik! I had forgotten about that format.
That did it. I need to tweak it a bit but definite progress. Thank you guys.